Skip to content

Instantly share code, notes, and snippets.

@RobBowman
Created March 13, 2017 13:52
Show Gist options
  • Save RobBowman/41f18737a164b178295e467bee87370c to your computer and use it in GitHub Desktop.
Save RobBowman/41f18737a164b178295e467bee87370c to your computer and use it in GitHub Desktop.
This is how the XSD should be specified
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema targetNamespace="http://schemas.asidua.com/CCP/IntegrationServices/2011-11-18/Data" xmlns="http://schemas.asidua.com/CCP/IntegrationServices/2011-11-18/Data" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:q2="http://microsoft.com/wsdl/types/" elementFormDefault="unqualified" attributeFormDefault="unqualified">
<xs:import namespace="http://microsoft.com/wsdl/types/" schemaLocation=".\Types.xsd"/>
<xs:element name="SelectRequest">
<xs:annotation>
<xs:documentation>Comment describing your root element</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:sequence>
<xs:element name="CriteriaItem" type="AdapterItem"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="SelectResponse">
<xs:annotation>
<xs:documentation>Comment describing your root element</xs:documentation>
</xs:annotation>
</xs:element>
<xs:complexType name="AdapterItem">
<xs:sequence>
<xs:element name="Attributes" type="ArrayOfAdapterAttribute" minOccurs="0"/>
<xs:element name="EntityName" type="xs:string" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfAdapterAttribute">
<xs:sequence>
<xs:element name="Attribute" type="AdapterAttribute" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="AdapterAttribute">
<xs:sequence>
<xs:element name="Name" type="xs:string" minOccurs="0"/>
<xs:element name="Value" type="xs:anyType" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfInt">
<xs:sequence>
<xs:element name="int" type="xs:int" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfBoolean">
<xs:sequence>
<xs:element name="boolean" type="xs:boolean" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfDateTime">
<xs:sequence>
<xs:element name="dateTime" type="xs:dateTime" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfGuid">
<xs:sequence>
<xs:element name="guid" type="q2:guid" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfDecimal">
<xs:sequence>
<xs:element name="decimal" type="xs:decimal" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfDouble">
<xs:sequence>
<xs:element name="double" type="xs:double" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfAdapterItem">
<xs:sequence>
<xs:element name="AdapterItem" type="AdapterItem" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ItemReferenceValue">
<xs:sequence>
<xs:element name="EntityName" type="xs:string" minOccurs="0"/>
<xs:element name="ForeignKey" minOccurs="0"/>
<xs:element name="DisplayNameIfKnown" type="xs:string" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfItemReferenceValue">
<xs:sequence>
<xs:element name="ItemReferenceValue" type="ItemReferenceValue" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfString">
<xs:sequence>
<xs:element name="string" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ArrayOfSchemaAttribute">
<xs:sequence>
<xs:element name="SchemaAttribute" type="SchemaAttribute" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="SchemaAttribute">
<xs:sequence>
<xs:element name="Name" type="xs:string" minOccurs="0"/>
<xs:element name="ClrTypeName" type="xs:string" minOccurs="0"/>
<xs:element name="AdapterItemEntityNames" type="ArrayOfString" minOccurs="0"/>
<xs:element name="AdapterItemEntityNamesSerializationOptimised" type="ArrayOfString" minOccurs="0"/>
<xs:element name="Usage" type="AttributeUsage" default="ReadWriteOptional" minOccurs="0"/>
<xs:element name="PostWorkflowUsage" type="AttributeUsage" default="ReadWriteOptional" minOccurs="0"/>
<xs:element name="Sensitivity" type="Sensitivity"/>
<xs:element name="Indexing" type="Indexing"/>
<xs:element name="Description" type="xs:string" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:simpleType name="AttributeUsage">
<xs:list>
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="Default"/>
<xs:enumeration value="SelectCriteriaOptional"/>
<xs:enumeration value="SelectCriteriaMandatory"/>
<xs:enumeration value="SelectResultsOptional"/>
<xs:enumeration value="SelectResultsMandatory"/>
<xs:enumeration value="CreateValueOptional"/>
<xs:enumeration value="CreateValueMandatory"/>
<xs:enumeration value="CreateResultsOptional"/>
<xs:enumeration value="CreateResultsMandatory"/>
<xs:enumeration value="UpdateCriteriaOptional"/>
<xs:enumeration value="UpdateCriteriaMandatory"/>
<xs:enumeration value="UpdateValueOptional"/>
<xs:enumeration value="UpdateValueMandatory"/>
<xs:enumeration value="UpdateResultsOptional"/>
<xs:enumeration value="UpdateResultsMandatory"/>
<xs:enumeration value="DeleteCriteriaOptional"/>
<xs:enumeration value="DeleteCriteriaMandatory"/>
<xs:enumeration value="CreateValueAndResultsOptional"/>
<xs:enumeration value="ReadOnlyOptional"/>
<xs:enumeration value="ReadOnlyResultsMandatory"/>
<xs:enumeration value="ReadWriteOptional"/>
<xs:enumeration value="ReadWriteMandatory"/>
<xs:enumeration value="WriteOnlyOptional"/>
<xs:enumeration value="WriteOnlyMandatory"/>
</xs:restriction>
</xs:simpleType>
</xs:list>
</xs:simpleType>
<xs:simpleType name="Sensitivity">
<xs:restriction base="xs:string">
<xs:enumeration value="None"/>
<xs:enumeration value="HideFromLogs"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="Indexing">
<xs:restriction base="xs:string">
<xs:enumeration value="None"/>
<xs:enumeration value="PrimaryKey"/>
<xs:enumeration value="ForeignKey"/>
</xs:restriction>
</xs:simpleType>
</xs:schema>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment