Web services - WSDL to Java - Extending only skeleton file?
I have converted a WSDL file to generate Java code (with Axis2)that will be deployed as web service. Do I only need to implement开发者_开发知识库 and extend the skeleton file generated? Or, can I edit and extend other classes too?
I fear modifying other files will result in some mismatch between the WSDL and Java code.
You should remain as far as possible from changing any other files. The issue is marshalling/unmarshalling depends a lot on these files and your changes can cause an issue in this core logic itself.
Ideally if the Java skeletons are genrrated correctly, you would never need to change other java files. Only use them.
Extending other java files is also tricky as marshaller needs to understand how to marshal your sub classes
精彩评论