I am using Delphi, and I am using a wsdl file from another company to configure my proxy class to use my data from their web service. The wsdl file contains the following:
<xsd:simpleType name="departStatus"> <xsd:annotation> <xsd:documentation>Enumerates allowable departure statuses (DEPARTED, NOT-DEPARTED)</xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:enumeration value="DEPARTED"/> <xsd:enumeration value="NOT-DEPARTED"/> </xsd:restriction> </xsd:simpleType>
When I create a proxy class, I get the following:
departStatus = ( DEPARTED, [System.Xml.Serialization.XmlEnumAttribute('NOT-DEPARTED')] NOTDEPARTED);
Which does not compile unless I delete the line starting with [System.xml ... and it will not recognize "NOT-DEPARTED" as a valid value for offStatus. If I change NOT-DEPARTED to NOT_DEPARTED in the wsdl file and any input XML file, it works fine, but the company that installed it insists that NOT-DEPARTED is valid and will not change it. Why not enumerate the offStatus enum correctly? Any ideas how to get around this? Thanks in advance for any help.
Bob sieffert
source share