Generated C++ Method Format and Calling Parameters

Generated decode and SAX method implementations are written to a .cpp file with a name of the following format:

       <xsdFileName>Dec.cpp

where <xsdFileName> is the base name of the XSD file being parsed. For example, if code is being generated for file x.xsd, decode functions for each global element defined in the specification will be written to xDec.cpp. If the file being processed is a WSDL file, the suffix would be WSDLDec.cpp (for example, x.wsdl would produce xWSDLDec.cpp).

The main method for decoding an XML document that corresponds to an XSD global element is the decode or decodeFrom methods. The decode method exists in the OSXSDGlobalElement base class as decodes a message from the message buffer or stream associated with the class to the XSD type object instance. A decodeFrom method is generated for each global element that is not referenced by any other types. This method takes as an argument a message buffer of stream reference. The method reads the XML message from this buffer or stream and decodes it into the XSD type object instance associated with the control class instance.