I have developed a C# client to consume a web service on the CF 2.0 platform.
The web service is written in Java and served from Tomcat/Axis with an abstract data-type as the typical return-type. The auto-generated wsdl exposes the various sub-classes that could possibly come from the requested abstract type without a problem. I utilized the functionality of VS 2005 to auto-generate a proxy class from the wsdl that I pointed at.
Some web services request/responses work exactly as expected, wonderfully! The dilemma: the correct number of records are being recognized from the xml/soap response, but the data is not being deserialized correctly (e.g., all members of the class assume null value states). Using various tools (SOAPui, ethereal, logging, etc.) the data is being correctly created/formed/transmitted via SOAP.
Example:
AbstractClass[] getListOfRecords( string id );
Possible returns:
ConcreteClassA
{
String firstName;
String lastName;
}
ConcreteClassB
{
String birthdate;
String employeeId;
}
Request:
ConcreteClassA[] records = webservice.Invoke( "full-time" );
Soap response:
[ 0 ] => firstName=John, lastName=Doe
[ 1 ] => firstName=Jane, lastName=Doe
[ 2 ] => firstName=Max, lastName=Alvarez
C# inspection:
[ 0 ] => firstName=null, lastName=null
[ 1 ] => firstName=null, lastName=null
[ 2 ] => firstName=null, lastName=null
Any ideas why the data is NOT being deserialized correctly?
I have been pulling my hair out for the last 2 days trying different things and grasping straws to no avail; so any reply would be GREATLY appreciated!