|
1 | 1 | # generated by datamodel-codegen: |
2 | 2 | # filename: metadata-container-json-schema.json |
3 | | -# timestamp: 2025-09-03T08:11:07+00:00 |
| 3 | +# timestamp: 2025-09-03T09:21:45+00:00 |
4 | 4 |
|
5 | 5 | from __future__ import annotations |
6 | 6 |
|
@@ -34,12 +34,23 @@ class DataSetState(str, Enum): |
34 | 34 | OUTPUT_DATA = "OUTPUT_DATA" |
35 | 35 |
|
36 | 36 |
|
37 | | -class UseRestriction(str, Enum): |
| 37 | +class UseRestrictionType(Enum): |
38 | 38 | DELETION_ANONYMIZATION = "DELETION_ANONYMIZATION" |
39 | 39 | PROCESS_LIMITATIONS = "PROCESS_LIMITATIONS" |
40 | 40 | SECONDARY_USE_RESTRICTIONS = "SECONDARY_USE_RESTRICTIONS" |
41 | 41 |
|
42 | 42 |
|
| 43 | +class UseRestrictionItem(DatadocBaseModel): |
| 44 | + use_restriction: Optional[UseRestrictionType] = Field( |
| 45 | + None, description="Use restriction type", title="Use restriction type" |
| 46 | + ) |
| 47 | + use_restriction_date: Optional[AwareDatetime] = Field( |
| 48 | + None, |
| 49 | + description="Use restriction date, eg. the date (deadline) for when data must be deleted/anonymised.", |
| 50 | + title="Use restriction date", |
| 51 | + ) |
| 52 | + |
| 53 | + |
43 | 54 | class CustomTypeForDatasetMetadatum(DatadocBaseModel): |
44 | 55 | key: Optional[str] = Field(None, description="Custom type KEY", title="Key") |
45 | 56 | value: Optional[Union[str, list, dict[str, Any]]] = Field( |
@@ -192,13 +203,8 @@ class Dataset(DatadocBaseModel): |
192 | 203 | description="Description of the data set's spatial coverage", |
193 | 204 | title="Spatial coverage description", |
194 | 205 | ) |
195 | | - use_restriction: Optional[UseRestriction] = Field( |
196 | | - None, description="Data set use restriction", title="Use restriction" |
197 | | - ) |
198 | | - use_restriction_date: Optional[AwareDatetime] = Field( |
199 | | - None, |
200 | | - description="Use restriction date, eg. the date (deadline) for when data must be deleted/anonymised.", |
201 | | - title="Use restriction date", |
| 206 | + use_restriction: Optional[list[UseRestrictionItem]] = Field( |
| 207 | + None, description="Use restriction", title="Use restriction" |
202 | 208 | ) |
203 | 209 | custom_type: Optional[list[CustomTypeForDatasetMetadatum]] = Field( |
204 | 210 | None, |
@@ -380,8 +386,8 @@ class DatadocMetadata(DatadocBaseModel): |
380 | 386 | percentage_complete: Optional[int] = Field( |
381 | 387 | None, description="Percentage of obligatory metadata fields populated." |
382 | 388 | ) |
383 | | - document_version: Literal["6.0.0"] = Field( |
384 | | - "6.0.0", description="Version of this model" |
| 389 | + document_version: Literal["6.0.1"] = Field( |
| 390 | + "6.0.1", description="Version of this model" |
385 | 391 | ) |
386 | 392 | dataset: Optional[Dataset] = None |
387 | 393 | variables: Optional[list[Variable]] = None |
|
0 commit comments