• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to generate web-services.xml file with names for parameters?  RSS feed

 
Sara Fox
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When I used ant tool to build my webservice on Weblogic 8.1 SP4, it generated a web-services.xml file.

The operations section of the web-services.xml file is as below:
<operations>
<operation name="getInfo" method="getInfo(java.lang.String,long)" component="ejbcomp0">
<params>
<param style="in" xmlns:xsd="http://www.w3.org/2001/XMLSchema" type="xsd:string" location="body" name="string" class-name="java.lang.String">
</param>
<param style="in" xmlns:xsd="http://www.w3.org/2001/XMLSchema" type="xsd:long" location="body" name="longVal" class-name="long">
</param>
<return-param xmlns 1="java:language_builtins.lang" type="p1:ArrayOfString" location="body" name="result" class-name="[Ljava.lang.String;">
</return-param>
</params>
</operation>
</operations>

What do I need to do to get the actual names of the parameters in the web-services.xml file instead of generic names "string" and "longVal"?

I edited the web-services.xml file to reflect the actual names (as shown below), but it gets re-generated and overwrites my changes every time I re-build the webservice.

<params>
<param style="in" xmlns:xsd="http://www.w3.org/2001/XMLSchema" type="xsd:string" location="body" name="Cust_Name" class-name="java.lang.String">
</param>
<param style="in" xmlns:xsd="http://www.w3.org/2001/XMLSchema" type="xsd:long" location="body" name="Cust_Num" class-name="long">
</param>

Where does the ant tool get the names from usually? Do I need to create a special file for this?

Please help.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!