--- /dev/null
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r
+<!--\r
+ Copyright 2009 University of California at Berkeley\r
+ Licensed under the Educational Community License (ECL), Version 2.0.\r
+ You may not use this file except in compliance with this License.\r
+ \r
+ You may obtain a copy of the ECL 2.0 License at\r
+ https://source.collectionspace.org/collection-space/LICENSE.txt\r
+\r
+ Document : relation.xsd\r
+ Revision : $LastChangedRevision: $\r
+ Created on : $LastChangedDate: $\r
+ Author : $LastChangedBy: $\r
+ Description:\r
+-->\r
+<xs:schema\r
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"\r
+ xmlns="http://services.collectionspace.org/relation"\r
+ xmlns:rel="http://services.collectionspace.org/relation"\r
+ targetNamespace="http://services.collectionspace.org/relation"\r
+ >\r
+\r
+ <!-- Relation -->\r
+ <xs:element name="relation">\r
+ <xs:complexType>\r
+ <xs:sequence>\r
+ <xs:element name="csid" type="xs:string" /> \r
+ <xs:element name="documentId1" type="xs:string" minOccurs="1" maxOccurs="1"/>\r
+ <xs:element name="documentType1" type="xs:string" minOccurs="1" maxOccurs="1"/>\r
+ <xs:element name="documentId2" type="xs:string" minOccurs="1" maxOccurs="1"/>\r
+ <xs:element name="documentType2" type="xs:string" minOccurs="1" maxOccurs="1"/>\r
+ <!-- type of relatinoship between two entities -->\r
+ <xs:element name="relationshipType" type="rel:RelationshipType" minOccurs="1" maxOccurs="1"/>\r
+ </xs:sequence>\r
+ </xs:complexType>\r
+ </xs:element>\r
+\r
+ <!-- enumeration defining the type of relationship between two entities -->\r
+ <xs:simpleType name="RelationshipType">\r
+ <xs:restriction base="xs:string">\r
+ <!-- document with id as document-id-1 is associated with document with id as document-id-2 -->\r
+ <xs:enumeration value="association"/>\r
+ <!-- document with id as document-id-1 contains one or more document with id as document-id-2 -->\r
+ <xs:enumeration value="contains"/>\r
+ </xs:restriction>\r
+ </xs:simpleType>\r
+\r
+ <!-- collection objects as in nuxeo repository -->\r
+ <xs:element name="relation-list">\r
+ <xs:complexType>\r
+ <xs:sequence>\r
+ <xs:element name="relation-list-item" maxOccurs="unbounded">\r
+ <xs:complexType>\r
+ <xs:sequence>\r
+ <!-- uri to retrive collection object details -->\r
+ <xs:element name="uri" type="xs:anyURI" minOccurs="1"/>\r
+ <xs:element name="csid" type="xs:string" minOccurs="1"/>\r
+ </xs:sequence>\r
+ </xs:complexType>\r
+ </xs:element>\r
+ </xs:sequence>\r
+ </xs:complexType>\r
+ </xs:element>\r
+\r
+</xs:schema>\r
+\r
+\r
+\r
+\r
+\r
+\r