Schema Name: pstc_spmlv2_core.xsd
Target Namespace: urn:oasis:names:tc:SPML:2:0
Collapse XSD Schema Code:

<!--************************************************************-->
<!--  pstc_spmlv2_core.xsd                                      -->
<!--                                                            -->
<!--  Draft schema for SPML v2.0 core capabilities.             -->
<!--                                                            -->
<!--  Editors:                                                  -->
<!--    Jeff Bohren (Jeff_Bohren@bmc.com)                       -->
<!--                                                            -->
<!--                                                            -->
<!-- Copyright (C) The Organization for the Advancement of      -->
<!-- Structured Information Standards [OASIS] 2005. All Rights  -->
<!-- Reserved.                                                  -->
<!--************************************************************-->
<schema targetNamespace="urn:oasis:names:tc:SPML:2:0" xmlns="http://www.w3.org/2001/XMLSchema" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:spml="urn:oasis:names:tc:SPML:2:0" elementFormDefault="qualified">

	<complexType name="ExtensibleType">
		<sequence>
			<any namespace="##other" minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
		</sequence>
		<anyAttribute namespace="##other" processContents="lax"/>
 	</complexType>


	<simpleType name="ExecutionModeType">
		<restriction base="string">
			<enumeration value="synchronous"/>
			<enumeration value="asynchronous"/>
		</restriction>
	</simpleType>	


	<complexType name="CapabilityDataType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<annotation>
				    <documentation>Contains capability specific elements.</documentation>
				</annotation>  
				<attribute name="mustUnderstand" type="boolean" use="optional"/>
				<attribute name="capabilityURI" type="anyURI" /> 
			</extension>
		</complexContent>				
	</complexType>
		
	<complexType name="RequestType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<attribute name="requestID" type="xsd:ID" use="optional"/>
				<attribute name="executionMode" type="spml:ExecutionModeType" use="optional"/>
			</extension>
		</complexContent>				
	</complexType>
		
	<simpleType name="StatusCodeType">
		<restriction base="string">
			<enumeration value="success"/>
			<enumeration value="failure"/>
			<enumeration value="pending"/>
		</restriction>
	</simpleType>
	
	<simpleType name="ErrorCode">
		<restriction base="string">
			<enumeration value="malformedRequest"/>
			<enumeration value="unsupportedOperation"/>
			<enumeration value="unsupportedIdentifierType"/>
			<enumeration value="noSuchIdentifier"/>
			<enumeration value="customError"/>
			<enumeration value="unsupportedExecutionMode"/>
			<enumeration value="invalidContainment"/>
			<enumeration value="noSuchRequest"/>
			<enumeration value="unsupportedSelectionType"/>
			<enumeration value="resultSetToLarge"/>
			<enumeration value="unsupportedProfile"/>
			<enumeration value="invalidIdentifier"/>
			<enumeration value="alreadyExists"/>
			<enumeration value="containerNotEmpty"/>
		</restriction>
	</simpleType>
	
	<simpleType name="ReturnDataType">
		<restriction base="string">
			<enumeration value="identifier"/>
			<enumeration value="data"/>
			<enumeration value="everything"/>
		</restriction>
	</simpleType>
	
	<complexType name="ResponseType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<sequence>
			                <element name="errorMessage" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
				<attribute name="status" type="spml:StatusCodeType" use="required"/>
				<attribute name="requestID" type="xsd:ID" use="optional"/>
				<attribute name="error" type="spml:ErrorCode" use="optional"/>
			</extension>
		</complexContent>		
	</complexType>
	
	<complexType name="IdentifierType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<attribute name="ID" type="string" use="optional"/>
			</extension>
		</complexContent>				
	</complexType>
	
	<complexType name="PSOIdentifierType">
		<complexContent>
			<extension base="spml:IdentifierType">	
				<sequence>
					<element name="containerID" type="spml:PSOIdentifierType" minOccurs="0" />
				</sequence>
				<attribute name="targetID" type="string" use="optional"/>
			</extension>
		</complexContent>				
	</complexType>	
	
	
	<complexType name="PSOType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<sequence>
					<element name="psoID" type="spml:PSOIdentifierType" />
					<element name="data" type="spml:ExtensibleType" minOccurs="0" />
					<element name="capabilityData" type="spml:CapabilityDataType" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
			</extension>
		</complexContent>				
	</complexType>	
	
	<complexType name="AddRequestType">
		<complexContent>
			<extension base="spml:RequestType">
				<sequence>
					<element name="psoID" type="spml:PSOIdentifierType" minOccurs="0"/>
					<element name="containerID" type="spml:PSOIdentifierType" minOccurs="0"/>
					<element name="data" type="spml:ExtensibleType" />
					<element name="capabilityData" type="spml:CapabilityDataType" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
				<attribute name="targetID" type="string" use="optional"/>
				<attribute name="returnData" type="spml:ReturnDataType" use="optional" default="everything"/>
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="AddResponseType">
		<complexContent>
			<extension base="spml:ResponseType">
				<sequence>
					<element name="pso" type="spml:PSOType" minOccurs="0"/>
				</sequence>
			</extension>
		</complexContent>
	</complexType>
	
	<simpleType name="ModificationModeType">
		<restriction base="string">
			<enumeration value="add"/>
			<enumeration value="replace"/>
			<enumeration value="delete"/>
		</restriction>
	</simpleType>
	
	<complexType name="NamespacePrefixMappingType">
		<complexContent>
			<extension base="spml:ExtensibleType">
				<attribute name="prefix" type="string" use="required"/>
				<attribute name="namespace" type="string" use="required"/>
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="QueryClauseType">
		<complexContent>
			<extension base="spml:ExtensibleType">
			</extension>
		</complexContent>
	</complexType>

	<complexType name="SelectionType">
		<complexContent>
			<extension base="spml:QueryClauseType">
				<sequence>
					<element name="namespacePrefixMap" type="spml:NamespacePrefixMappingType" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
				<attribute name="path" type="string" use="required"/>
				<attribute name="namespaceURI" type="string" use="required"/>
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="ModificationType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<sequence>
					<element name="component" type="spml:SelectionType" minOccurs="0" />
					<element name="data" type="spml:ExtensibleType" minOccurs="0" />
					<element name="capabilityData" type="spml:CapabilityDataType" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
				<attribute name="modificationMode" type="spml:ModificationModeType" use="optional"/>
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="ModifyRequestType">
		<complexContent>
			<extension base="spml:RequestType">
				<sequence>
					<element name="psoID" type="spml:PSOIdentifierType"/>
					<element name="modification" type="spml:ModificationType" maxOccurs="unbounded"/>
				</sequence>
				<attribute name="returnData" type="spml:ReturnDataType" use="optional" default="everything"/>
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="ModifyResponseType">
		<complexContent>
			<extension base="spml:ResponseType">
				<sequence>
					<element name="pso" type="spml:PSOType" minOccurs="0" />
				</sequence>
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="DeleteRequestType">
		<complexContent>
			<extension base="spml:RequestType">
				<sequence>
					<element name="psoID" type="spml:PSOIdentifierType"/>
				</sequence>
				<attribute name="recursive" type="xsd:boolean" use="optional" default="false"/>
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="LookupRequestType">
		<complexContent>
			<extension base="spml:RequestType">
				<sequence>
					<element name="psoID" type="spml:PSOIdentifierType" />
				</sequence>
				<attribute name="returnData" type="spml:ReturnDataType" use="optional" default="everything"/>
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="LookupResponseType">
		<complexContent>
			<extension base="spml:ResponseType">
				<sequence>
					<element name="pso" type="spml:PSOType" minOccurs="0" />
				</sequence>
			</extension>
		</complexContent>
	</complexType>

	<complexType name="SchemaType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<sequence>
					<annotation>
					    <documentation>Profile specific schema elements should be included here</documentation>
					</annotation>  
					<element name="supportedSchemaEntity" type="spml:SchemaEntityRefType" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
				<attribute name="ref" type="anyURI" use="optional" />
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="SchemaEntityRefType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<attribute name="targetID" type="string" use="optional"/>
				<attribute name="entityName" type="string" use="optional" /> 
				<attribute name="isContainer" type="xsd:boolean" use="optional" /> 
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="CapabilityType">
		<complexContent>
			<extension base="spml:ExtensibleType">
				<sequence>
					<element name="appliesTo" type="spml:SchemaEntityRefType" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
				<attribute name="namespaceURI" type="anyURI" /> 
				<attribute name="location" type="anyURI" use="optional" /> 
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="CapabilitiesListType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<sequence>
					<element name="capability" type="spml:CapabilityType" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
			</extension>
		</complexContent>				
	</complexType>
	
	<complexType name="TargetType">
		<complexContent>
			<extension base="spml:ExtensibleType">	
				<sequence>
					<element name="schema" type="spml:SchemaType" maxOccurs="unbounded"/>
					<element name="capabilities" type="spml:CapabilitiesListType" minOccurs="0" />
				</sequence>
				<attribute name="targetID" type="string" use="optional"/>
				<attribute name="profile" type="anyURI" use="optional" />
			</extension>
		</complexContent>				
	</complexType>
	
	<complexType name="ListTargetsRequestType">
		<complexContent>
			<extension base="spml:RequestType">
				<attribute name="profile" type="anyURI" use="optional" />
			</extension>
		</complexContent>
	</complexType>
	
	<complexType name="ListTargetsResponseType">
		<complexContent>
			<extension base="spml:ResponseType">
				<sequence>
					<element name="target" type="spml:TargetType" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
			</extension>
		</complexContent>
	</complexType>
	
	<element name="select" type="spml:SelectionType" />
	<element name="addRequest" type="spml:AddRequestType"/>
	<element name="addResponse" type="spml:AddResponseType"/>
	<element name="modifyRequest" type="spml:ModifyRequestType"/>
	<element name="modifyResponse" type="spml:ModifyResponseType"/>
	<element name="deleteRequest" type="spml:DeleteRequestType"/>
	<element name="deleteResponse" type="spml:ResponseType"/>
	<element name="lookupRequest" type="spml:LookupRequestType"/>
	<element name="lookupResponse" type="spml:LookupResponseType"/>
	<element name="listTargetsRequest" type="spml:ListTargetsRequestType"/>
	<element name="listTargetsResponse" type="spml:ListTargetsResponseType"/>

</schema>

Collapse ComplexTypes:
Collapse Elements:
Collapse SimpleTypes: