cocina-models 0.24.0 → 0.25.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/pull_request_template.md +8 -0
- data/docs/maps/DRO.json +11 -0
- data/docs/schema.json +17 -0
- data/docs/schema.md +1 -0
- data/lib/cocina/models/dro.rb +7 -0
- data/lib/cocina/models/request_dro.rb +1 -0
- data/lib/cocina/models/request_file_set.rb +1 -1
- data/lib/cocina/models/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ea6c13e33db6453db29a003cf18a8336be1413d86df77d9149ecf137ab72b44b
|
4
|
+
data.tar.gz: 6129384ecfa8d18d39733afe2c9ee2178d57215490fa034b6303e05367b5c933
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 99a1fc3d0ccdb4cc08d80f16ece04fe583cc957a8df574526d4a0e6294423085ffe24e6fdef5b8e8d4ed08368303eaef6e0e86bcd5c27a023905b2d41321f0c3
|
7
|
+
data.tar.gz: 3bee949d8082f953ebc4ef03f04fc4b8c909d3342448d82bda908f69a8efba0b8d693d5f4747e7526f491a4225658fb72bded2122890d48bfc909f0e90bfa02b
|
@@ -3,3 +3,11 @@
|
|
3
3
|
|
4
4
|
|
5
5
|
## Was the documentation (README, wiki) updated?
|
6
|
+
|
7
|
+
|
8
|
+
|
9
|
+
## Does this change affect how this gem integrates with other services?
|
10
|
+
|
11
|
+
If so, please confirm:
|
12
|
+
- [ ] change was tested on stage and/or
|
13
|
+
- [ ] test added to sul-dlss/infrastructure-integration-test
|
data/docs/maps/DRO.json
CHANGED
@@ -176,6 +176,17 @@
|
|
176
176
|
"description": "Descriptive metadata for the DRO.",
|
177
177
|
"$ref": "/Description"
|
178
178
|
},
|
179
|
+
"geographic": {
|
180
|
+
"description": "Geographic metadata for the DRO.",
|
181
|
+
"type": "object",
|
182
|
+
"required": ["iso19139"],
|
183
|
+
"properties": {
|
184
|
+
"iso19139": {
|
185
|
+
"description": "Geographic ISO 19139 XML metadata",
|
186
|
+
"type": "string"
|
187
|
+
}
|
188
|
+
}
|
189
|
+
},
|
179
190
|
"identification": {
|
180
191
|
"description": "Identifying information for the DRO.",
|
181
192
|
"type": "object",
|
data/docs/schema.json
CHANGED
@@ -694,6 +694,23 @@
|
|
694
694
|
"description": "Descriptive metadata for the DRO.",
|
695
695
|
"$ref": "#/definitions/Description"
|
696
696
|
},
|
697
|
+
"geographic": {
|
698
|
+
"description": "Geographic metadata for the DRO.",
|
699
|
+
"type": [
|
700
|
+
"object"
|
701
|
+
],
|
702
|
+
"required": [
|
703
|
+
"iso19139"
|
704
|
+
],
|
705
|
+
"properties": {
|
706
|
+
"iso19139": {
|
707
|
+
"description": "Geographic ISO 19139 XML metadata",
|
708
|
+
"type": [
|
709
|
+
"string"
|
710
|
+
]
|
711
|
+
}
|
712
|
+
}
|
713
|
+
},
|
697
714
|
"identification": {
|
698
715
|
"description": "Identifying information for the DRO.",
|
699
716
|
"type": [
|
data/docs/schema.md
CHANGED
@@ -103,6 +103,7 @@ Domain-defined abstraction of a 'work'. Digital Repository Objects' abstraction
|
|
103
103
|
| **description:title** | *array* | The title of the item. | `[{"primary":true,"titleFull":"example"}]` |
|
104
104
|
| **externalIdentifier** | *string* | Identifier for the resource within the SDR architecture but outside of the repository. DRUID or UUID depending on resource type. Constant across resource versions. What clients will use calling the repository. Same as `identification.identifier` | `"example"` |
|
105
105
|
| **followingVersion** | *string* | Following version for the Object within SDR. | `"example"` |
|
106
|
+
| **geographic:iso19139** | *string* | Geographic ISO 19139 XML metadata | `"example"` |
|
106
107
|
| **identification:catalogLinks/catalog** | *string* | Catalog that is the source of the linked record. | `"example"` |
|
107
108
|
| **identification:catalogLinks/catalogRecordId** | *string* | Record identifier that is unique within the context of the linked record's catalog. | `"example"` |
|
108
109
|
| **identification:catalogLinks/deliverMetadata** | *boolean* | If the linked record should be automatically updated when the DRO descriptive metadata changes. | `true` |
|
data/lib/cocina/models/dro.rb
CHANGED
@@ -55,10 +55,16 @@ module Cocina
|
|
55
55
|
# Structural sub-schema for the DRO
|
56
56
|
class Structural < Struct
|
57
57
|
attribute :contains, Types::Strict::Array.of(FileSet).meta(omittable: true)
|
58
|
+
attribute :hasAgreement, Types::Strict::String.meta(omittable: true)
|
58
59
|
attribute :isMemberOf, Types::Strict::String.meta(omittable: true)
|
59
60
|
attribute :hasMemberOrders, Types::Strict::Array.of(Sequence).meta(omittable: true)
|
60
61
|
end
|
61
62
|
|
63
|
+
# Geographic sub-schema for the DRO
|
64
|
+
class Geographic < Struct
|
65
|
+
attribute :iso19139, Types::Strict::String
|
66
|
+
end
|
67
|
+
|
62
68
|
attribute :externalIdentifier, Types::Strict::String
|
63
69
|
attribute :type, Types::String.enum(*TYPES)
|
64
70
|
attribute :label, Types::Strict::String
|
@@ -68,6 +74,7 @@ module Cocina
|
|
68
74
|
# Allowing description to be omittable for now (until rolled out to consumers),
|
69
75
|
# but I think it's actually required for every DRO
|
70
76
|
attribute :description, Description.optional.meta(omittable: true)
|
77
|
+
attribute :geographic, Geographic.optional.meta(omittable: true)
|
71
78
|
attribute(:identification, Identification.default { Identification.new })
|
72
79
|
attribute(:structural, Structural.default { Structural.new })
|
73
80
|
|
@@ -21,6 +21,7 @@ module Cocina
|
|
21
21
|
# Allowing description to be omittable for now (until rolled out to consumers),
|
22
22
|
# but I think it's actually required for every DRO
|
23
23
|
attribute :description, Description.optional.meta(omittable: true)
|
24
|
+
attribute :geographic, DRO::Geographic.optional.meta(omittable: true)
|
24
25
|
attribute(:identification, DRO::Identification.default { DRO::Identification.new })
|
25
26
|
attribute(:structural, Structural.default { Structural.new })
|
26
27
|
|
@@ -14,7 +14,7 @@ module Cocina
|
|
14
14
|
attribute :label, Types::Strict::String
|
15
15
|
attribute :version, Types::Coercible::Integer
|
16
16
|
attribute(:identification, FileSet::Identification.default { FileSet::Identification.new })
|
17
|
-
attribute(:structural,
|
17
|
+
attribute(:structural, Structural.default { Structural.new })
|
18
18
|
end
|
19
19
|
end
|
20
20
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cocina-models
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.25.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Justin Coyne
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-02-
|
11
|
+
date: 2020-02-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dry-struct
|