| 26 September 2007 - 1.7.6 |
The JBossWS plugin contains functionality for easily adding JSR-181 Web Service annotations to existing java code.
Start by enabling the JBossWS nature and by selecting the "JBossWS - Add Web Service Annotations" option from the desired java classes right-button menu:

This will open the following dialog:

The contained options map directly to the service/binding level annotations available in the JSR-181 specification. Once the desired options have been set, select the Generate option which will add the corresponding annotations to the underlying java file, for example:
package ole.test;
import java.util.Arrays;
@javax.jws.soap.SOAPBinding(parameterStyle = javax.jws.soap.SOAPBinding.ParameterStyle.BARE)
@javax.jws.WebService(name="TestImpl", targetNamespace="urn:ole.test", serviceName="TestImplService")
class TestImpl implements Test
{
@javax.jws.WebMethod()
public String toUpperCase(String str)
{
return str.toUpperCase();
}
@javax.jws.WebMethod()
public String toLowerCase(String str)
{
return str.toLowerCase();
}
}Currently, the JBossWS plugin does not support configuring annotations on a method level, standard @WebMethod annotations are added to all methods.
Deploy the annotated class in a standard jar archive using the JBossIDE packaging, standard Eclipse/WTP packaging features, or any other desired procedure (ANT, Maven, etc..).