@twin.org/standards-w3c-odrl 0.0.1-next.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (75) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +21 -0
  3. package/dist/cjs/index.cjs +911 -0
  4. package/dist/esm/index.mjs +897 -0
  5. package/dist/types/index.d.ts +26 -0
  6. package/dist/types/models/IOdrlAction.d.ts +33 -0
  7. package/dist/types/models/IOdrlAsset.d.ts +27 -0
  8. package/dist/types/models/IOdrlAssetCollection.d.ts +21 -0
  9. package/dist/types/models/IOdrlConstraint.d.ts +49 -0
  10. package/dist/types/models/IOdrlDuty.d.ts +33 -0
  11. package/dist/types/models/IOdrlLogicalConstraint.d.ts +45 -0
  12. package/dist/types/models/IOdrlParty.d.ts +35 -0
  13. package/dist/types/models/IOdrlPartyCollection.d.ts +18 -0
  14. package/dist/types/models/IOdrlPermission.d.ts +14 -0
  15. package/dist/types/models/IOdrlPolicy.d.ts +81 -0
  16. package/dist/types/models/IOdrlPolicyMetadata.d.ts +58 -0
  17. package/dist/types/models/IOdrlProhibition.d.ts +11 -0
  18. package/dist/types/models/IOdrlRule.d.ts +41 -0
  19. package/dist/types/models/odrlContexts.d.ts +29 -0
  20. package/dist/types/models/types/actionTypes.d.ts +214 -0
  21. package/dist/types/models/types/conflictStrategyTypes.d.ts +21 -0
  22. package/dist/types/models/types/dataTypes.d.ts +37 -0
  23. package/dist/types/models/types/leftOperandTypes.d.ts +137 -0
  24. package/dist/types/models/types/logicalConstraintType.d.ts +25 -0
  25. package/dist/types/models/types/odrlTypes.d.ts +69 -0
  26. package/dist/types/models/types/operatorTypes.d.ts +65 -0
  27. package/dist/types/models/types/policyTypes.d.ts +25 -0
  28. package/dist/types/models/types/rightOperandTypes.d.ts +13 -0
  29. package/dist/types/models/types/ruleTypes.d.ts +21 -0
  30. package/dist/types/models/types/statusTypes.d.ts +25 -0
  31. package/dist/types/models/types/uriActionTypes.d.ts +215 -0
  32. package/docs/changelog.md +5 -0
  33. package/docs/examples.md +1 -0
  34. package/docs/reference/index.md +49 -0
  35. package/docs/reference/interfaces/IOdrlAction.md +61 -0
  36. package/docs/reference/interfaces/IOdrlAsset.md +55 -0
  37. package/docs/reference/interfaces/IOdrlAssetCollection.md +85 -0
  38. package/docs/reference/interfaces/IOdrlConstraint.md +76 -0
  39. package/docs/reference/interfaces/IOdrlDuty.md +144 -0
  40. package/docs/reference/interfaces/IOdrlLogicalConstraint.md +70 -0
  41. package/docs/reference/interfaces/IOdrlParty.md +67 -0
  42. package/docs/reference/interfaces/IOdrlPartyCollection.md +98 -0
  43. package/docs/reference/interfaces/IOdrlPermission.md +108 -0
  44. package/docs/reference/interfaces/IOdrlPolicy.md +136 -0
  45. package/docs/reference/interfaces/IOdrlPolicyMetadata.md +86 -0
  46. package/docs/reference/interfaces/IOdrlProhibition.md +105 -0
  47. package/docs/reference/interfaces/IOdrlRule.md +75 -0
  48. package/docs/reference/type-aliases/ActionType.md +5 -0
  49. package/docs/reference/type-aliases/ConflictStrategyType.md +5 -0
  50. package/docs/reference/type-aliases/DataType.md +5 -0
  51. package/docs/reference/type-aliases/LeftOperandType.md +5 -0
  52. package/docs/reference/type-aliases/LogicalConstraintType.md +5 -0
  53. package/docs/reference/type-aliases/OdrlContexts.md +5 -0
  54. package/docs/reference/type-aliases/OdrlTypes.md +5 -0
  55. package/docs/reference/type-aliases/OperatorType.md +5 -0
  56. package/docs/reference/type-aliases/PolicyType.md +5 -0
  57. package/docs/reference/type-aliases/RightOperandType.md +5 -0
  58. package/docs/reference/type-aliases/RuleType.md +5 -0
  59. package/docs/reference/type-aliases/StatusType.md +5 -0
  60. package/docs/reference/type-aliases/UriActionType.md +6 -0
  61. package/docs/reference/variables/ActionTypes.md +314 -0
  62. package/docs/reference/variables/ConflictStrategyTypes.md +25 -0
  63. package/docs/reference/variables/DataType.md +49 -0
  64. package/docs/reference/variables/LeftOperandType.md +199 -0
  65. package/docs/reference/variables/LogicalConstraintType.md +31 -0
  66. package/docs/reference/variables/OdrlContexts.md +37 -0
  67. package/docs/reference/variables/OdrlTypes.md +97 -0
  68. package/docs/reference/variables/OperatorType.md +91 -0
  69. package/docs/reference/variables/PolicyType.md +31 -0
  70. package/docs/reference/variables/RightOperandTypes.md +13 -0
  71. package/docs/reference/variables/RuleType.md +25 -0
  72. package/docs/reference/variables/StatusType.md +31 -0
  73. package/docs/reference/variables/UriActionTypes.md +314 -0
  74. package/locales/en.json +1 -0
  75. package/package.json +40 -0
@@ -0,0 +1,199 @@
1
+ # Variable: LeftOperandType
2
+
3
+ > `const` **LeftOperandType**: `object`
4
+
5
+ The types for ODRL Data Types.
6
+
7
+ ## Type declaration
8
+
9
+ ### AbsolutePosition
10
+
11
+ > `readonly` **AbsolutePosition**: `"absolutePosition"` = `"absolutePosition"`
12
+
13
+ Absolute Position type.
14
+
15
+ ### AbsoluteSpatialPosition
16
+
17
+ > `readonly` **AbsoluteSpatialPosition**: `"absoluteSpatialPosition"` = `"absoluteSpatialPosition"`
18
+
19
+ Absolute Spatial Position type.
20
+
21
+ ### AbsoluteTemporalPosition
22
+
23
+ > `readonly` **AbsoluteTemporalPosition**: `"absoluteTemporalPosition"` = `"absoluteTemporalPosition"`
24
+
25
+ Absolute Temporal Position type.
26
+
27
+ ### AbsoluteSize
28
+
29
+ > `readonly` **AbsoluteSize**: `"absoluteSize"` = `"absoluteSize"`
30
+
31
+ Absolute Size type.
32
+
33
+ ### Count
34
+
35
+ > `readonly` **Count**: `"count"` = `"count"`
36
+
37
+ Count type.
38
+
39
+ ### DateTime
40
+
41
+ > `readonly` **DateTime**: `"dateTime"` = `"dateTime"`
42
+
43
+ DateTime type.
44
+
45
+ ### DelayPeriod
46
+
47
+ > `readonly` **DelayPeriod**: `"delayPeriod"` = `"delayPeriod"`
48
+
49
+ Delay Period type.
50
+
51
+ ### DeliveryChannel
52
+
53
+ > `readonly` **DeliveryChannel**: `"deliveryChannel"` = `"deliveryChannel"`
54
+
55
+ Delivery Channel type.
56
+
57
+ ### ElapsedTime
58
+
59
+ > `readonly` **ElapsedTime**: `"elapsedTime"` = `"elapsedTime"`
60
+
61
+ Elapsed Time type.
62
+
63
+ ### Event
64
+
65
+ > `readonly` **Event**: `"event"` = `"event"`
66
+
67
+ Event type.
68
+
69
+ ### FileFormat
70
+
71
+ > `readonly` **FileFormat**: `"fileFormat"` = `"fileFormat"`
72
+
73
+ File Format type.
74
+
75
+ ### Industry
76
+
77
+ > `readonly` **Industry**: `"industry"` = `"industry"`
78
+
79
+ Industry type.
80
+
81
+ ### Language
82
+
83
+ > `readonly` **Language**: `"language"` = `"language"`
84
+
85
+ Language type.
86
+
87
+ ### Media
88
+
89
+ > `readonly` **Media**: `"media"` = `"media"`
90
+
91
+ Media type.
92
+
93
+ ### MeteredTime
94
+
95
+ > `readonly` **MeteredTime**: `"meteredTime"` = `"meteredTime"`
96
+
97
+ Metered Time type.
98
+
99
+ ### PayAmount
100
+
101
+ > `readonly` **PayAmount**: `"payAmount"` = `"payAmount"`
102
+
103
+ Pay Amount type.
104
+
105
+ ### Percentage
106
+
107
+ > `readonly` **Percentage**: `"percentage"` = `"percentage"`
108
+
109
+ Percentage type.
110
+
111
+ ### Product
112
+
113
+ > `readonly` **Product**: `"product"` = `"product"`
114
+
115
+ Product type.
116
+
117
+ ### Purpose
118
+
119
+ > `readonly` **Purpose**: `"purpose"` = `"purpose"`
120
+
121
+ Purpose type.
122
+
123
+ ### Recipient
124
+
125
+ > `readonly` **Recipient**: `"recipient"` = `"recipient"`
126
+
127
+ Recipient type.
128
+
129
+ ### RelativePosition
130
+
131
+ > `readonly` **RelativePosition**: `"relativePosition"` = `"relativePosition"`
132
+
133
+ Relative Position type.
134
+
135
+ ### RelativeSpatialPosition
136
+
137
+ > `readonly` **RelativeSpatialPosition**: `"relativeSpatialPosition"` = `"relativeSpatialPosition"`
138
+
139
+ Relative Spatial Position type.
140
+
141
+ ### RelativeTemporalPosition
142
+
143
+ > `readonly` **RelativeTemporalPosition**: `"relativeTemporalPosition"` = `"relativeTemporalPosition"`
144
+
145
+ Relative Temporal Position type.
146
+
147
+ ### RelativeSize
148
+
149
+ > `readonly` **RelativeSize**: `"relativeSize"` = `"relativeSize"`
150
+
151
+ Relative Size type.
152
+
153
+ ### Resolution
154
+
155
+ > `readonly` **Resolution**: `"resolution"` = `"resolution"`
156
+
157
+ Resolution type.
158
+
159
+ ### Spatial
160
+
161
+ > `readonly` **Spatial**: `"spatial"` = `"spatial"`
162
+
163
+ Spatial type.
164
+
165
+ ### SpatialCoordinates
166
+
167
+ > `readonly` **SpatialCoordinates**: `"spatialCoordinates"` = `"spatialCoordinates"`
168
+
169
+ Spatial Coordinates type.
170
+
171
+ ### SystemDevice
172
+
173
+ > `readonly` **SystemDevice**: `"systemDevice"` = `"systemDevice"`
174
+
175
+ System Device type.
176
+
177
+ ### TimeInterval
178
+
179
+ > `readonly` **TimeInterval**: `"timeInterval"` = `"timeInterval"`
180
+
181
+ Time Interval type.
182
+
183
+ ### UnitOfCount
184
+
185
+ > `readonly` **UnitOfCount**: `"unitOfCount"` = `"unitOfCount"`
186
+
187
+ Unit of Count type.
188
+
189
+ ### Version
190
+
191
+ > `readonly` **Version**: `"version"` = `"version"`
192
+
193
+ Version type.
194
+
195
+ ### VirtualLocation
196
+
197
+ > `readonly` **VirtualLocation**: `"virtualLocation"` = `"virtualLocation"`
198
+
199
+ Virtual Location type.
@@ -0,0 +1,31 @@
1
+ # Variable: LogicalConstraintType
2
+
3
+ > `const` **LogicalConstraintType**: `object`
4
+
5
+ The types for ODRL Logical Constraints.
6
+
7
+ ## Type declaration
8
+
9
+ ### And
10
+
11
+ > `readonly` **And**: `"and"` = `"and"`
12
+
13
+ And type.
14
+
15
+ ### Or
16
+
17
+ > `readonly` **Or**: `"or"` = `"or"`
18
+
19
+ Or type.
20
+
21
+ ### Xone
22
+
23
+ > `readonly` **Xone**: `"xone"` = `"xone"`
24
+
25
+ Xone type.
26
+
27
+ ### AndSequence
28
+
29
+ > `readonly` **AndSequence**: `"andSequence"` = `"andSequence"`
30
+
31
+ And sequence type.
@@ -0,0 +1,37 @@
1
+ # Variable: OdrlContexts
2
+
3
+ > `const` **OdrlContexts**: `object`
4
+
5
+ The contexts for ODRL.
6
+
7
+ ## Type declaration
8
+
9
+ ### Context
10
+
11
+ > `readonly` **Context**: `"https://www.w3.org/ns/odrl.jsonld"` = `"https://www.w3.org/ns/odrl.jsonld"`
12
+
13
+ The context root for ODRL.
14
+
15
+ ### ContextVocabulary
16
+
17
+ > `readonly` **ContextVocabulary**: `"https://www.w3.org/ns/odrl/2/"` = `"https://www.w3.org/ns/odrl/2/"`
18
+
19
+ The context root for ODRL vocabulary.
20
+
21
+ ### ContextDcTerms
22
+
23
+ > `readonly` **ContextDcTerms**: `"https://purl.org/dc/terms/"` = `"https://purl.org/dc/terms/"`
24
+
25
+ The context root for Dublin Core Terms.
26
+
27
+ ### ContextRdf
28
+
29
+ > `readonly` **ContextRdf**: `"https://www.w3.org/1999/02/22-rdf-syntax-ns#"` = `"https://www.w3.org/1999/02/22-rdf-syntax-ns#"`
30
+
31
+ The context root for RDF.
32
+
33
+ ### ContextXsd
34
+
35
+ > `readonly` **ContextXsd**: `"https://www.w3.org/2001/XMLSchema#"` = `"https://www.w3.org/2001/XMLSchema#"`
36
+
37
+ The context root for XSD.
@@ -0,0 +1,97 @@
1
+ # Variable: OdrlTypes
2
+
3
+ > `const` **OdrlTypes**: `object`
4
+
5
+ The types for ODRL.
6
+
7
+ ## Type declaration
8
+
9
+ ### Policy
10
+
11
+ > `readonly` **Policy**: `"Policy"` = `"Policy"`
12
+
13
+ Policy type.
14
+
15
+ ### Set
16
+
17
+ > `readonly` **Set**: `"Set"` = `"Set"`
18
+
19
+ Set type (subclass of Policy).
20
+
21
+ ### Offer
22
+
23
+ > `readonly` **Offer**: `"Offer"` = `"Offer"`
24
+
25
+ Offer type (subclass of Policy).
26
+
27
+ ### Agreement
28
+
29
+ > `readonly` **Agreement**: `"Agreement"` = `"Agreement"`
30
+
31
+ Agreement type (subclass of Policy).
32
+
33
+ ### Asset
34
+
35
+ > `readonly` **Asset**: `"Asset"` = `"Asset"`
36
+
37
+ Asset type.
38
+
39
+ ### AssetCollection
40
+
41
+ > `readonly` **AssetCollection**: `"AssetCollection"` = `"AssetCollection"`
42
+
43
+ AssetCollection type.
44
+
45
+ ### Party
46
+
47
+ > `readonly` **Party**: `"Party"` = `"Party"`
48
+
49
+ Party type.
50
+
51
+ ### PartyCollection
52
+
53
+ > `readonly` **PartyCollection**: `"PartyCollection"` = `"PartyCollection"`
54
+
55
+ PartyCollection type.
56
+
57
+ ### Action
58
+
59
+ > `readonly` **Action**: `"Action"` = `"Action"`
60
+
61
+ Action type.
62
+
63
+ ### Rule
64
+
65
+ > `readonly` **Rule**: `"Rule"` = `"Rule"`
66
+
67
+ Rule type.
68
+
69
+ ### Permission
70
+
71
+ > `readonly` **Permission**: `"Permission"` = `"Permission"`
72
+
73
+ Permission type (subclass of Rule).
74
+
75
+ ### Prohibition
76
+
77
+ > `readonly` **Prohibition**: `"Prohibition"` = `"Prohibition"`
78
+
79
+ Prohibition type (subclass of Rule).
80
+
81
+ ### Duty
82
+
83
+ > `readonly` **Duty**: `"Duty"` = `"Duty"`
84
+
85
+ Duty type (subclass of Rule).
86
+
87
+ ### Constraint
88
+
89
+ > `readonly` **Constraint**: `"Constraint"` = `"Constraint"`
90
+
91
+ Constraint type.
92
+
93
+ ### LogicalConstraint
94
+
95
+ > `readonly` **LogicalConstraint**: `"LogicalConstraint"` = `"LogicalConstraint"`
96
+
97
+ LogicalConstraint type.
@@ -0,0 +1,91 @@
1
+ # Variable: OperatorType
2
+
3
+ > `const` **OperatorType**: `object`
4
+
5
+ The types for ODRL Operators.
6
+
7
+ ## Type declaration
8
+
9
+ ### Eq
10
+
11
+ > `readonly` **Eq**: `"eq"` = `"eq"`
12
+
13
+ Equal type.
14
+
15
+ ### Gt
16
+
17
+ > `readonly` **Gt**: `"gt"` = `"gt"`
18
+
19
+ Greater than type.
20
+
21
+ ### Gteq
22
+
23
+ > `readonly` **Gteq**: `"gteq"` = `"gteq"`
24
+
25
+ Greater than or equal to type.
26
+
27
+ ### Lt
28
+
29
+ > `readonly` **Lt**: `"lt"` = `"lt"`
30
+
31
+ Less than type.
32
+
33
+ ### Lteq
34
+
35
+ > `readonly` **Lteq**: `"lteq"` = `"lteq"`
36
+
37
+ Less than or equal to type.
38
+
39
+ ### Neq
40
+
41
+ > `readonly` **Neq**: `"neq"` = `"neq"`
42
+
43
+ Not equal to type.
44
+
45
+ ### IsA
46
+
47
+ > `readonly` **IsA**: `"isA"` = `"isA"`
48
+
49
+ Is a type.
50
+
51
+ ### HasPart
52
+
53
+ > `readonly` **HasPart**: `"hasPart"` = `"hasPart"`
54
+
55
+ Has part type.
56
+
57
+ ### IsPartOf
58
+
59
+ > `readonly` **IsPartOf**: `"isPartOf"` = `"isPartOf"`
60
+
61
+ Is part of type.
62
+
63
+ ### IsAllOf
64
+
65
+ > `readonly` **IsAllOf**: `"isAllOf"` = `"isAllOf"`
66
+
67
+ Is all of type.
68
+
69
+ ### IsAnyOf
70
+
71
+ > `readonly` **IsAnyOf**: `"isAnyOf"` = `"isAnyOf"`
72
+
73
+ Is any of type.
74
+
75
+ ### IsNoneOf
76
+
77
+ > `readonly` **IsNoneOf**: `"isNoneOf"` = `"isNoneOf"`
78
+
79
+ Is none of type.
80
+
81
+ ### LocTimeEq
82
+
83
+ > `readonly` **LocTimeEq**: `"locTimeEq"` = `"locTimeEq"`
84
+
85
+ Location time equal to type.
86
+
87
+ ### LocTimeGteq
88
+
89
+ > `readonly` **LocTimeGteq**: `"locTimeGteq"` = `"locTimeGteq"`
90
+
91
+ Location time greater than or equal to type.
@@ -0,0 +1,31 @@
1
+ # Variable: PolicyType
2
+
3
+ > `const` **PolicyType**: `object`
4
+
5
+ The types for ODRL Policies.
6
+
7
+ ## Type declaration
8
+
9
+ ### Policy
10
+
11
+ > `readonly` **Policy**: `"Policy"` = `"Policy"`
12
+
13
+ Policy type.
14
+
15
+ ### Set
16
+
17
+ > `readonly` **Set**: `"Set"` = `"Set"`
18
+
19
+ Set type.
20
+
21
+ ### Offer
22
+
23
+ > `readonly` **Offer**: `"Offer"` = `"Offer"`
24
+
25
+ Offer type.
26
+
27
+ ### Agreement
28
+
29
+ > `readonly` **Agreement**: `"Agreement"` = `"Agreement"`
30
+
31
+ Agreement type.
@@ -0,0 +1,13 @@
1
+ # Variable: RightOperandTypes
2
+
3
+ > `const` **RightOperandTypes**: `object`
4
+
5
+ Right operand types for ODRL constraints
6
+
7
+ ## Type declaration
8
+
9
+ ### PolicyUsage
10
+
11
+ > `readonly` **PolicyUsage**: `"odrl:policyUsage"` = `"odrl:policyUsage"`
12
+
13
+ Reference to policy usage events
@@ -0,0 +1,25 @@
1
+ # Variable: RuleType
2
+
3
+ > `const` **RuleType**: `object`
4
+
5
+ The types for ODRL Rules.
6
+
7
+ ## Type declaration
8
+
9
+ ### Permission
10
+
11
+ > `readonly` **Permission**: `"Permission"` = `"Permission"`
12
+
13
+ Permission type.
14
+
15
+ ### Prohibition
16
+
17
+ > `readonly` **Prohibition**: `"Prohibition"` = `"Prohibition"`
18
+
19
+ Prohibition type.
20
+
21
+ ### Duty
22
+
23
+ > `readonly` **Duty**: `"Duty"` = `"Duty"`
24
+
25
+ Duty type.
@@ -0,0 +1,31 @@
1
+ # Variable: StatusType
2
+
3
+ > `const` **StatusType**: `object`
4
+
5
+ The types for ODRL Status.
6
+
7
+ ## Type declaration
8
+
9
+ ### Active
10
+
11
+ > `readonly` **Active**: `"active"` = `"active"`
12
+
13
+ Active type.
14
+
15
+ ### Inactive
16
+
17
+ > `readonly` **Inactive**: `"inactive"` = `"inactive"`
18
+
19
+ Inactive type.
20
+
21
+ ### Pending
22
+
23
+ > `readonly` **Pending**: `"pending"` = `"pending"`
24
+
25
+ Pending type.
26
+
27
+ ### Revoked
28
+
29
+ > `readonly` **Revoked**: `"revoked"` = `"revoked"`
30
+
31
+ Revoked type.