WSDL, Enums and C#: It's still murky

后端 未结 1 1840
醉话见心
醉话见心 2021-01-18 05:18

I tried to look this up online, but all the WSDL examples seem to not really explain if I should mark things as basetype string in the WSDL or int...

Basically, I\'m

1条回答
  •  春和景丽
    2021-01-18 05:33

    Enumerations will end up looking like their string representations. So the correct wsdl will present the enums as:

    
        
          
          
          
          
        
      
    

    The above will automatically serialize/deserialize to the MyEnum enumeration type for you. If you present the enums as xsd:int then you will end up having to convert them manually back and forth.

    You can refer to the enumeration definition within your schema like so:

    
        
          
        
      
    

    0 讨论(0)
提交回复
热议问题