When I encountered this problem, my first thought was: Enum? Isn't it enumeration? It is actually a simple value object (such as int, long). The value object WebService certainly supports very well. However, after several days of hard work, I found the problem was not that simple. Today, I put my conclusion here. I hope that my friends who have encountered this problem will not be able to spend any time on research (or if they know how to solve this problem better, share it with me ). The specific reasons are as follows:
1. The most widely used Java platform is the WebService provided by the axis component, which has been officially mentioned that Enum is the object to be avoided in WebService. Please refer to http://wiki.apache.org/ws/FrontPage/Axis/DotNetInterop for explanations
2. for Enum objects, if we view the WSDL of WebService, we can find that only the string description is available, in DOTNET, the default int value starting from 0 is not stored in the WSDL (as if W3C has not specified this object in WebService on the Internet,ProgramDepends onCodeLogic (or logic that depends on the enum member sequence) cannot be correctly executed.