diff --git a/CDT-commonTypes-v0_8_0.xsd b/CDT-commonTypes-v0_8_0.xsd index 02e24029435989b15905b00f14f23c1fe059f468..1b37904eeddf43d4698b3a181ddf322069f523c9 100644 --- a/CDT-commonTypes-v0_8_0.xsd +++ b/CDT-commonTypes-v0_8_0.xsd @@ -31,10 +31,8 @@ oneM2M EXPRESSLY ADVISES ANY AND ALL USE OF OR RELIANCE UPON THIS INFORMATION PR <!-- oneM2M Simple Types --> <!--********************** --> - - <!-- TODO: Choose appropriate definitions for the id types (xs:token is placeholder for now) --> <xs:simpleType name="ID"> - <xs:restriction base="xs:token"> + <xs:restriction base="xs:anyURI"> </xs:restriction> </xs:simpleType> @@ -43,11 +41,13 @@ oneM2M EXPRESSLY ADVISES ANY AND ALL USE OF OR RELIANCE UPON THIS INFORMATION PR </xs:restriction> </xs:simpleType> - <!-- TODO: should this allow lower case hex ? --> <xs:simpleType name="deviceID"> <xs:restriction base="xs:token"> - <xs:pattern - value="urn:((dev:ops:[\dABCDEF]{6}-[\w_%]+-[\w_%]+)|(dev:os:[\dABCDEF]{6}-[\w_%]+)|(imei:\d{15})|(esn:[\dABCDEF]{8})|(meid:[\dABCDEF]{14}))"></xs:pattern> + <xs:pattern value="urn:dev:ops:[\dABCDEFabcdef]{6}-[\w_%]+-[\w_%]+" /> + <xs:pattern value="urn:dev:os:[\dABCDEFabcdef]{6}-[\w_%]+" /> + <xs:pattern value="urn:imei:\d{15}" /> + <xs:pattern value="urn:esn:[\dABCDEFabcdef]{8}" /> + <xs:pattern value="urn:meid:[\dABCDEFabcdef]{14}" /> </xs:restriction> </xs:simpleType> @@ -66,18 +66,13 @@ oneM2M EXPRESSLY ADVISES ANY AND ALL USE OF OR RELIANCE UPON THIS INFORMATION PR <xs:simpleType name="nhURI"> <xs:restriction base="xs:anyURI" /> </xs:simpleType> - - <!-- TODO: why is it declared as a ref to a global element like this? --> - <xs:complexType name="acpType"> - <xs:sequence> - <xs:element ref="m2m:accessControlPolicyID" minOccurs="0" maxOccurs="unbounded" /> - </xs:sequence> - </xs:complexType> - - <xs:element name="accessControlPolicyID" type="xs:anyURI" /> + + <xs:simpleType name="acpType"> + <list itemType="xs:anyURI" /> + </xs:simpleType> <xs:simpleType name="labels"> - <xs:list itemType="xs:string" /> + <xs:list itemType="xs:token" /> </xs:simpleType> <!-- TODO: this data type is not used in any of the XSD files. It is listed in TS-004 without any given use case --> @@ -106,7 +101,7 @@ oneM2M EXPRESSLY ADVISES ANY AND ALL USE OF OR RELIANCE UPON THIS INFORMATION PR <xs:simpleType name="listOfEventCatWithDef"> <list itemType="m2m:eventCatWithDef" /> </xs:simpleType> - + <!-- auxiliary data type required to define "listOflongMin-1" below --> <xs:simpleType name="longMin-1"> <xs:restriction base="xs:long"> @@ -123,8 +118,7 @@ oneM2M EXPRESSLY ADVISES ANY AND ALL USE OF OR RELIANCE UPON THIS INFORMATION PR type xs:long in the range -1, 0, 1, 2 ... . Unit is milliseconds. Value setting of -1 expresses infinity --> <xs:simpleType name="listOfMinMax"> <xs:restriction base="m2m:listOflongMin-1"> - <xs:minLength value="2" /> - <xs:maxLength value="2" /> + <xs:length value="2" /> </xs:restriction> </xs:simpleType> @@ -141,29 +135,31 @@ oneM2M EXPRESSLY ADVISES ANY AND ALL USE OF OR RELIANCE UPON THIS INFORMATION PR <xs:maxLength value="3" /> </xs:restriction> </xs:simpleType> - - <!-- <xs:simpleType name="ipv4"> - <xs:restriction base="xs:token" /> - </xs:simpleType> - - <xs:simpleType name="ipv6"> - <xs:restriction base="xs:token" /> - </xs:simpleType> --> - + + <!-- m2m:ipv4 and m2m:ipv6 are defined in the CDT-accessControlPolicy file --> + <xs:simpleType name="pOAList"> <xs:list itemType="xs:string" /> </xs:simpleType> + <!--Format is YYYYMMDDThhmmss with no punctuation --> <xs:simpleType name="timestamp"> - <xs:restriction base="xs:dateTime" /> + <xs:restriction base="xs:string"> + <xs:pattern value="\d{4}(0[1-9]|1[0-2])(0[1-9]|[1-2]\d|30|31)T([01]\d|2[0-3])[0-5]\d[0-5]\d"></xs:pattern> + </xs:restriction> </xs:simpleType> <xs:simpleType name="typeOfContent"> - <xs:restriction base="xs:token" /> - </xs:simpleType> + <xs:restriction base="xs:string"> + <xs:pattern value="[\w/!#$^_.+&\-]+" /> + </xs:restriction> + </xs:simpleType> + <xs:simpleType name="contentInfo"> - <xs:restriction base="xs:token" /> + <xs:restriction base="xs:string"> + <xs:pattern value="[\w/!#$^_.+&\-]+(:[0-2])?" /> + </xs:restriction> </xs:simpleType> <xs:simpleType name="scheduleEntry">