common-policy.xsd 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3. Extracted from RFC 4745
  4. http://www.rfc-editor.org/rfc/rfc4745.txt
  5. NOTE: This file has been patched in order to generate a usable object mapping
  6. -->
  7. <xs:schema targetNamespace="urn:ietf:params:xml:ns:common-policy" xmlns:cp="urn:ietf:params:xml:ns:common-policy" xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
  8. <!-- /ruleset -->
  9. <xs:element name="ruleset">
  10. <xs:complexType>
  11. <xs:sequence>
  12. <xs:element name="rule" type="cp:ruleType" minOccurs="0" maxOccurs="unbounded" />
  13. </xs:sequence>
  14. </xs:complexType>
  15. </xs:element>
  16. <!-- /ruleset/rule -->
  17. <xs:complexType name="ruleType">
  18. <xs:sequence>
  19. <xs:element name="conditions" type="cp:conditionsType" minOccurs="0" />
  20. <xs:element name="actions" type="cp:extensibleType" minOccurs="0" />
  21. <xs:element name="transformations" type="cp:extensibleType" minOccurs="0" />
  22. </xs:sequence>
  23. <xs:attribute name="id" type="xs:ID" use="required" />
  24. </xs:complexType>
  25. <!-- //rule/conditions -->
  26. <xs:complexType name="conditionsType">
  27. <xs:choice maxOccurs="unbounded">
  28. <xs:element name="identity" type="cp:identityType" minOccurs="0" />
  29. <xs:element name="sphere" type="cp:sphereType" minOccurs="0" />
  30. <xs:element name="validity" type="cp:validityType" minOccurs="0" />
  31. <xs:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded" />
  32. </xs:choice>
  33. </xs:complexType>
  34. <!-- //conditions/identity -->
  35. <xs:complexType name="identityType">
  36. <xs:choice minOccurs="1" maxOccurs="unbounded">
  37. <xs:element name="one" type="cp:oneType" />
  38. <xs:element name="many" type="cp:manyType" />
  39. <xs:any namespace="##other" processContents="lax" />
  40. </xs:choice>
  41. </xs:complexType>
  42. <!-- //identity/one -->
  43. <xs:complexType name="oneType">
  44. <xs:sequence>
  45. <xs:any namespace="##other" minOccurs="0" processContents="lax" />
  46. </xs:sequence>
  47. <xs:attribute name="id" type="xs:anyURI" use="required" />
  48. </xs:complexType>
  49. <!-- //identity/many -->
  50. <xs:complexType name="manyType">
  51. <xs:choice minOccurs="0" maxOccurs="unbounded">
  52. <xs:element name="except" type="cp:exceptType" />
  53. <xs:any namespace="##other" minOccurs="0" processContents="lax" />
  54. </xs:choice>
  55. <xs:attribute name="domain" use="optional" type="xs:string" />
  56. </xs:complexType>
  57. <!-- //many/except -->
  58. <xs:complexType name="exceptType">
  59. <xs:attribute name="domain" type="xs:string" use="optional" />
  60. <xs:attribute name="id" type="xs:anyURI" use="optional" />
  61. </xs:complexType>
  62. <!-- //conditions/sphere -->
  63. <xs:complexType name="sphereType">
  64. <xs:attribute name="value" type="xs:string" use="required" />
  65. </xs:complexType>
  66. <!-- //conditions/validity -->
  67. <xs:complexType name="validityType">
  68. <xs:sequence minOccurs="1" maxOccurs="unbounded">
  69. <xs:element name="from" type="xs:dateTime" />
  70. <xs:element name="until" type="xs:dateTime" />
  71. </xs:sequence>
  72. </xs:complexType>
  73. <!-- //rule/actions or //rule/transformations -->
  74. <xs:complexType name="extensibleType">
  75. <xs:sequence>
  76. <xs:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded" />
  77. </xs:sequence>
  78. </xs:complexType>
  79. </xs:schema>