You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Anil Arora <aa...@interlacesystems.com> on 2005/08/24 21:16:18 UTC
Schemas for customized serializers
I need to return the schema of some of my serialized objects as part of
the soap message. An example of this is below. I am using a custom
serializer to handle the <root> tag. So, is there an easy way for me to
put the schema inside the message. Is there an object I can create, set
up, and return to do this? Or will I have to create my own "schema"
object and custom serializer for that.
Anil
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<http://www.w3.org/2001/XMLSchema%22%3e%20%3csoap:Body%3e%20%3cDiscoverR
esponse>
<soap:Body>
<http://www.w3.org/2001/XMLSchema%22%3e%20%3csoap:Body%3e%20%3cDiscoverR
esponse>
<DiscoverResponse
<http://www.w3.org/2001/XMLSchema%22%3e%20%3csoap:Body%3e%20%3cDiscoverR
esponse> xmlns="urn:schemas-microsoft-com:xml-analysis">
<return>
<root xmlns="urn:schemas-microsoft-com:xml-analysis:rowset">
<xsd:schema xmlns:sql="urn:schemas-microsoft-com:xml-sql"
elementFormDefault="qualified"
targetNamespace="urn:schemas-microsoft-com:xml-analysis:rowset">
<xsd:element name="root">
<xsd:complexType>
<xsd:sequence minOccurs="0"
maxOccurs="unbounded">
<xsd:element name="row" type="row" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
...
</xsd:schema>
<row>
<DataSourceName>Test Server</DataSourceName>
<DataSourceDescription>Test Provider for OLAP
</DataSourceDescription>
</row>
</root>
</return>
</DiscoverResponse>
</soap:Body>
</soap:Envelope>