cocina-models 0.40.1 → 0.44.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b1a41a02c7e3c3d58b65f4b94e4afdbc885795920eee91fa83f87374a207c0c1
4
- data.tar.gz: 3c70761dd272739012387d78df18c69d114ab5a152d79283131f8d727112dcb9
3
+ metadata.gz: b11ea0c5efe76fc9a4a59bc70e4c60e7c25c8a97491259687ae63899c45f5e2e
4
+ data.tar.gz: 2edc2ee62490fbf0c0cf29942cc1820d7bdfbd28e0cddb39db8df1753e6e64b0
5
5
  SHA512:
6
- metadata.gz: e7f56d6aa41f0d13d2dcf17a2aef82354b566025caf04ffff84b2857fabfcc8c703c16f3aae00cf43c4654922f7b9240ededef6366ed9b111b2b4690f5a11fd2
7
- data.tar.gz: b452f06a8f0525035a0699e74345b8bd1fb7f96d5b3f9cfbd996f1f65bd99b82d7ffbd9fa71cd2a5c32e60ef8731df159833b2bae98070ddf9f40803316b3caf
6
+ metadata.gz: 822ff54e876a9c4384dc9f7530a2ab9bd11b86e21cf4e7d426f5975dbf98ac8f387968a45e0ea1afae57a2d5a72283b8af71a8ab0776e45c81f24f9fa26c4160
7
+ data.tar.gz: c88924f5de3c54a11c026864df8713eabf89693f51a3cd789c6e92d6a15618a0ba7ee725d0c742de9480de2f7fee8ece3a5c8b7ffac2e08fe381a53654ced9b0
@@ -1,3 +1,5 @@
1
+ **NOTE: Changes to openapi.yml require updating openapi.yml for sdr-api and dor-services-app and generating models - see README.**
2
+
1
3
  ## Why was this change made?
2
4
 
3
5
 
@@ -7,6 +9,3 @@
7
9
 
8
10
 
9
11
  ## Which documentation and/or configurations were updated?
10
-
11
-
12
-
@@ -7,139 +7,148 @@ require:
7
7
  AllCops:
8
8
  TargetRubyVersion: 2.5
9
9
 
10
+ # ----- Layout ------
11
+
10
12
  Layout/LineLength:
11
13
  Max: 114
12
14
  Exclude:
13
15
  - lib/cocina/models/*
14
16
 
15
- Metrics/BlockLength:
16
- Exclude:
17
- - cocina-models.gemspec
18
- - spec/cocina/**/*
19
-
20
- Metrics/MethodLength:
21
- Max: 14
22
-
23
- RSpec/MultipleExpectations:
24
- Enabled: false
25
-
26
- RSpec/ExampleLength:
27
- Max: 18
28
- Exclude:
29
- - spec/cocina/models/description_spec.rb
30
- - spec/cocina/models/dro_shared_examples.rb
31
-
32
- Style/Documentation:
33
- Exclude:
34
- - lib/cocina/models/*
35
-
17
+ Layout/BeginEndAlignment: # (new in 0.91)
18
+ Enabled: true
36
19
  Layout/EmptyLinesAroundAttributeAccessor:
37
20
  Enabled: true
38
-
39
21
  Layout/SpaceAroundMethodCallOperator:
40
22
  Enabled: true
41
23
 
24
+ # ----- Lint ------
25
+
26
+ Lint/BinaryOperatorWithIdenticalOperands:
27
+ Enabled: true
28
+ Lint/ConstantDefinitionInBlock: # (new in 0.91)
29
+ Enabled: true
42
30
  Lint/DeprecatedOpenSSLConstant:
43
31
  Enabled: true
44
-
45
- Lint/MixedRegexpCaptureTypes:
32
+ Lint/DuplicateElsifCondition:
46
33
  Enabled: true
47
-
48
- Lint/RaiseException:
34
+ Lint/DuplicateRequire: # (new in 0.90)
49
35
  Enabled: true
50
-
51
- Lint/StructNewOverride:
36
+ Lint/DuplicateRescueException:
52
37
  Enabled: true
53
-
54
- Style/AccessorGrouping:
38
+ Lint/EmptyConditionalBody:
55
39
  Enabled: true
56
-
57
- Style/BisectedAttrAccessor:
40
+ Lint/EmptyFile: # (new in 0.90)
58
41
  Enabled: true
59
-
60
- Style/ExponentialNotation:
42
+ Lint/FloatComparison:
61
43
  Enabled: true
62
-
63
- Style/HashEachMethods:
44
+ Lint/HashCompareByIdentity: # (new in 0.93)
64
45
  Enabled: true
65
-
66
- Style/HashTransformKeys:
46
+ Lint/IdentityComparison: # (new in 0.91)
67
47
  Enabled: true
68
-
69
- Style/HashTransformValues:
48
+ Lint/MissingSuper:
70
49
  Enabled: true
71
-
72
- Style/RedundantAssignment:
50
+ Lint/MixedRegexpCaptureTypes:
73
51
  Enabled: true
74
-
75
- Style/RedundantFetchBlock:
52
+ Lint/OutOfRangeRegexpRef:
76
53
  Enabled: true
77
-
78
- Style/RedundantRegexpCharacterClass:
54
+ Lint/RaiseException:
79
55
  Enabled: true
80
-
81
- Style/RedundantRegexpEscape:
56
+ Lint/RedundantSafeNavigation: # (new in 0.93)
82
57
  Enabled: true
83
-
84
- Style/SlicingWithRange:
58
+ Lint/SelfAssignment:
85
59
  Enabled: true
86
-
87
- Lint/BinaryOperatorWithIdenticalOperands:
60
+ Lint/StructNewOverride:
88
61
  Enabled: true
89
-
90
- Lint/DuplicateElsifCondition:
62
+ Lint/TopLevelReturnWithArgument:
91
63
  Enabled: true
92
-
93
- Lint/DuplicateRescueException:
64
+ Lint/TrailingCommaInAttributeDeclaration: # (new in 0.90)
94
65
  Enabled: true
95
-
96
- Lint/EmptyConditionalBody:
66
+ Lint/UnreachableLoop:
97
67
  Enabled: true
98
-
99
- Lint/FloatComparison:
68
+ Lint/UselessMethodDefinition: # (new in 0.90)
100
69
  Enabled: true
101
-
102
- Lint/MissingSuper:
70
+ Lint/UselessTimes: # (new in 0.91)
103
71
  Enabled: true
104
72
 
105
- Lint/OutOfRangeRegexpRef:
106
- Enabled: true
73
+ # ----- Metrics ------
107
74
 
108
- Lint/SelfAssignment:
109
- Enabled: true
75
+ Metrics/BlockLength:
76
+ Exclude:
77
+ - cocina-models.gemspec
78
+ - spec/cocina/**/*
110
79
 
111
- Lint/TopLevelReturnWithArgument:
112
- Enabled: true
80
+ Metrics/MethodLength:
81
+ Max: 14
113
82
 
114
- Lint/UnreachableLoop:
83
+ # ----- RSpec ------
84
+
85
+ RSpec/ExampleLength:
86
+ Max: 18
87
+ Exclude:
88
+ - spec/cocina/models/description_spec.rb
89
+ - spec/cocina/models/dro_shared_examples.rb
90
+
91
+ RSpec/MultipleExpectations:
92
+ Enabled: false
93
+
94
+ RSpec/StubbedMock: # (new in 1.44)
115
95
  Enabled: true
116
96
 
97
+ # ----- Style ------
98
+
99
+ Style/Documentation:
100
+ Exclude:
101
+ - lib/cocina/models/*
102
+
103
+ Style/AccessorGrouping:
104
+ Enabled: true
117
105
  Style/ArrayCoercion:
118
106
  Enabled: true
119
-
107
+ Style/BisectedAttrAccessor:
108
+ Enabled: true
120
109
  Style/CaseLikeIf:
121
110
  Enabled: true
122
-
111
+ Style/ClassEqualityComparison: # (new in 0.93)
112
+ Enabled: true
113
+ Style/CombinableLoops: # (new in 0.90)
114
+ Enabled: true
123
115
  Style/ExplicitBlockArgument:
124
116
  Enabled: true
125
-
117
+ Style/ExponentialNotation:
118
+ Enabled: true
126
119
  Style/GlobalStdStream:
127
120
  Enabled: true
128
-
129
121
  Style/HashAsLastArrayItem:
130
122
  Enabled: true
131
-
123
+ Style/HashEachMethods:
124
+ Enabled: true
132
125
  Style/HashLikeCase:
133
126
  Enabled: true
134
-
127
+ Style/HashTransformKeys:
128
+ Enabled: true
129
+ Style/HashTransformValues:
130
+ Enabled: true
131
+ Style/KeywordParametersOrder: # (new in 0.90)
132
+ Enabled: true
135
133
  Style/OptionalBooleanParameter:
136
134
  Enabled: false
137
-
135
+ Style/RedundantAssignment:
136
+ Enabled: true
137
+ Style/RedundantFetchBlock:
138
+ Enabled: true
138
139
  Style/RedundantFileExtensionInRequire:
139
140
  Enabled: true
140
-
141
+ Style/RedundantRegexpCharacterClass:
142
+ Enabled: true
143
+ Style/RedundantRegexpEscape:
144
+ Enabled: true
145
+ Style/RedundantSelfAssignment: # (new in 0.90)
146
+ Enabled: true
141
147
  Style/SingleArgumentDig:
142
148
  Enabled: true
143
-
149
+ Style/SlicingWithRange:
150
+ Enabled: true
151
+ Style/SoleNestedConditional: # (new in 0.89)
152
+ Enabled: true
144
153
  Style/StringConcatenation:
145
154
  Enabled: true
data/README.md CHANGED
@@ -52,6 +52,9 @@ Once the above listed gems are updated all the following services that use cocin
52
52
  * sul-dlss/common-accessioning
53
53
  * sul-dlss/argo
54
54
  * sul-dlss/pre-assembly
55
+ * sul-dlss/hydrus
56
+ * sul-dlss/happy-heron
57
+ * sul-dlss/infrastructure-integration-test
55
58
 
56
59
  ## Using this gem
57
60
 
@@ -45,7 +45,7 @@ module Cocina
45
45
  FileUtils.rm_f(filepath)
46
46
 
47
47
  create_file filepath, vocab.generate
48
- run("rubocop -a #{filepath}")
48
+ run("rubocop -a #{filepath} > /dev/null")
49
49
  end
50
50
 
51
51
  private
@@ -71,7 +71,7 @@ module Cocina
71
71
  FileUtils.rm_f(filepath)
72
72
 
73
73
  create_file filepath, schema.generate
74
- run("rubocop -a #{filepath}")
74
+ run("rubocop -a #{filepath} > /dev/null")
75
75
  end
76
76
 
77
77
  def clean_output
@@ -5,8 +5,6 @@ module Cocina
5
5
  class Access < Struct
6
6
  # Access level
7
7
  attribute :access, Types::Strict::String.default('dark').enum('world', 'stanford', 'location-based', 'citation-only', 'dark').meta(omittable: true)
8
- # Download access level for a file
9
- attribute :download, Types::Strict::String.default('none').enum('world', 'stanford', 'location-based', 'none').meta(omittable: true)
10
8
  # If access is "location-based", which location should have access.
11
9
  attribute :readLocation, Types::Strict::String.enum('spec', 'music', 'ars', 'art', 'hoover', 'm&m').meta(omittable: true)
12
10
  end
@@ -3,10 +3,11 @@
3
3
  module Cocina
4
4
  module Models
5
5
  class Description < Struct
6
- attribute :title, Types::Strict::Array.of(DescriptiveValueRequired).default([].freeze)
6
+ attribute :title, Types::Strict::Array.of(Title).default([].freeze)
7
7
  attribute :contributor, Types::Strict::Array.of(Contributor).meta(omittable: true)
8
8
  attribute :event, Types::Strict::Array.of(Event).meta(omittable: true)
9
9
  attribute :form, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
10
+ attribute :geographic, Types::Strict::Array.of(DescriptiveGeographicMetadata).meta(omittable: true)
10
11
  attribute :language, Types::Strict::Array.of(Language).meta(omittable: true)
11
12
  attribute :note, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
12
13
  attribute :identifier, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
@@ -5,6 +5,7 @@ module Cocina
5
5
  class DescriptiveAccessMetadata < Struct
6
6
  attribute :url, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
7
7
  attribute :physicalLocation, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
8
+ attribute :digitalLocation, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
8
9
  attribute :accessContact, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
9
10
  attribute :digitalRepository, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
10
11
  attribute :note, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
@@ -17,6 +17,7 @@ module Cocina
17
17
  attribute :uri, Types::Strict::String.meta(omittable: true)
18
18
  attribute :standard, Standard.optional.meta(omittable: true)
19
19
  attribute :encoding, Standard.optional.meta(omittable: true)
20
+ attribute :identifier, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
20
21
  attribute :source, Source.optional.meta(omittable: true)
21
22
  # The preferred display label to use for the descriptive element in access systems.
22
23
  attribute :displayLabel, Types::Strict::String.meta(omittable: true)
@@ -0,0 +1,10 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Cocina
4
+ module Models
5
+ class DescriptiveGeographicMetadata < Struct
6
+ attribute :form, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
7
+ attribute :subject, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
8
+ end
9
+ end
10
+ end
@@ -17,6 +17,7 @@ module Cocina
17
17
  attribute :uri, Types::Strict::String.meta(omittable: true)
18
18
  attribute :standard, Standard.optional.meta(omittable: true)
19
19
  attribute :encoding, Standard.optional.meta(omittable: true)
20
+ attribute :identifier, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
20
21
  attribute :source, Source.optional.meta(omittable: true)
21
22
  # The preferred display label to use for the descriptive element in access systems.
22
23
  attribute :displayLabel, Types::Strict::String.meta(omittable: true)
@@ -10,6 +10,8 @@ module Cocina
10
10
  # String describing the standard or encoding.
11
11
  attribute :value, Types::Strict::String.meta(omittable: true)
12
12
  attribute :note, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
13
+ # The version of the standard or encoding.
14
+ attribute :version, Types::Strict::String.meta(omittable: true)
13
15
  attribute :source, Source.optional.meta(omittable: true)
14
16
  attribute :valueScript, Standard.optional.meta(omittable: true)
15
17
  end
@@ -6,9 +6,12 @@ module Cocina
6
6
  attribute :structuredValue, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
7
7
  # Description of the event (creation, publication, etc.).
8
8
  attribute :type, Types::Strict::String.meta(omittable: true)
9
+ # The preferred display label to use for the event in access systems.
10
+ attribute :displayLabel, Types::Strict::String.meta(omittable: true)
9
11
  attribute :date, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
10
12
  attribute :contributor, Types::Strict::Array.of(Contributor).meta(omittable: true)
11
13
  attribute :location, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
14
+ attribute :identifier, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
12
15
  attribute :note, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
13
16
  end
14
17
  end
@@ -3,29 +3,27 @@
3
3
  module Cocina
4
4
  module Models
5
5
  class Language < Struct
6
- attribute :structuredValue, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
7
- attribute :parallelValue, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
8
- # String or integer value of the descriptive element.
9
- attribute :value, Types::Nominal::Any.meta(omittable: true)
10
- # Type of value provided by the descriptive element.
11
- attribute :type, Types::Strict::String.meta(omittable: true)
12
- # Status of the descriptive element value relative to other instances of the element.
13
- attribute :status, Types::Strict::String.meta(omittable: true)
6
+ attribute :appliesTo, Types::Strict::Array.of(DescriptiveBasicValue).meta(omittable: true)
14
7
  # Code value of the descriptive element.
15
8
  attribute :code, Types::Strict::String.meta(omittable: true)
16
- # URI value of the descriptive element.
17
- attribute :uri, Types::Strict::String.meta(omittable: true)
18
- attribute :standard, Standard.optional.meta(omittable: true)
19
- attribute :encoding, Standard.optional.meta(omittable: true)
20
- attribute :source, Source.optional.meta(omittable: true)
21
9
  # The preferred display label to use for the descriptive element in access systems.
22
10
  attribute :displayLabel, Types::Strict::String.meta(omittable: true)
23
- # A term providing information about the circumstances of the statement (e.g., approximate dates).
24
- attribute :qualifier, Types::Strict::String.meta(omittable: true)
11
+ attribute :encoding, Standard.optional.meta(omittable: true)
25
12
  attribute :note, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
26
- attribute :valueLanguage, DescriptiveValueLanguage.optional.meta(omittable: true)
27
- attribute :appliesTo, Types::Strict::Array.of(DescriptiveBasicValue).meta(omittable: true)
13
+ attribute :parallelValue, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
14
+ # present for mapping to additional schemas in the future and for consistency but not otherwise used
15
+ attribute :qualifier, Types::Strict::String.meta(omittable: true)
28
16
  attribute :script, DescriptiveValue.optional.meta(omittable: true)
17
+ attribute :source, Source.optional.meta(omittable: true)
18
+ # Status of the language relative to other parallel language elements (e.g. the primary language)
19
+ attribute :status, Types::Strict::String.enum('primary').meta(omittable: true)
20
+ attribute :standard, Standard.optional.meta(omittable: true)
21
+ attribute :structuredValue, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
22
+ # URI value of the descriptive element.
23
+ attribute :uri, Types::Strict::String.meta(omittable: true)
24
+ # Value of the descriptive element.
25
+ attribute :value, Types::Strict::String.meta(omittable: true)
26
+ attribute :valueLanguage, DescriptiveValueLanguage.optional.meta(omittable: true)
29
27
  end
30
28
  end
31
29
  end
@@ -10,7 +10,7 @@ module Cocina
10
10
 
11
11
  # The algorithm that was used
12
12
  attribute :type, Types::Strict::String.enum(*MessageDigest::TYPES)
13
- # The digest value Base64 encoded
13
+ # The digest value hexidecimal encoded
14
14
  attribute :digest, Types::Strict::String
15
15
  end
16
16
  end
@@ -5,6 +5,10 @@ module Cocina
5
5
  class RelatedResource < Struct
6
6
  # The relationship of the related resource to the described resource.
7
7
  attribute :type, Types::Strict::String.meta(omittable: true)
8
+ # Status of the related resource relative to other related resources.
9
+ attribute :status, Types::Strict::String.meta(omittable: true)
10
+ # The preferred display label to use for the related resource in access systems.
11
+ attribute :displayLabel, Types::Strict::String.meta(omittable: true)
8
12
  attribute :title, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
9
13
  attribute :contributor, Types::Strict::Array.of(Contributor).meta(omittable: true)
10
14
  attribute :event, Types::Strict::Array.of(Event).meta(omittable: true)
@@ -12,10 +16,15 @@ module Cocina
12
16
  attribute :language, Types::Strict::Array.of(Language).meta(omittable: true)
13
17
  attribute :note, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
14
18
  attribute :identifier, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
19
+ attribute :standard, Standard.optional.meta(omittable: true)
15
20
  attribute :subject, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
16
21
  # Stanford persistent URL associated with the related resource.
17
22
  attribute :purl, Types::Strict::String.meta(omittable: true)
18
23
  attribute :access, DescriptiveAccessMetadata.optional.meta(omittable: true)
24
+ attribute :relatedResource, Types::Strict::Array.of(RelatedResource).meta(omittable: true)
25
+ attribute :adminMetadata, DescriptiveAdminMetadata.optional.meta(omittable: true)
26
+ # The version of the related resource.
27
+ attribute :version, Types::Strict::String.meta(omittable: true)
19
28
  end
20
29
  end
21
30
  end
@@ -10,6 +10,8 @@ module Cocina
10
10
  # String describing the value source.
11
11
  attribute :value, Types::Strict::String.meta(omittable: true)
12
12
  attribute :note, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
13
+ # The version of the value source.
14
+ attribute :version, Types::Strict::String.meta(omittable: true)
13
15
  end
14
16
  end
15
17
  end
@@ -10,6 +10,8 @@ module Cocina
10
10
  # String describing the standard or encoding.
11
11
  attribute :value, Types::Strict::String.meta(omittable: true)
12
12
  attribute :note, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
13
+ # The version of the standard or encoding.
14
+ attribute :version, Types::Strict::String.meta(omittable: true)
13
15
  attribute :source, Source.optional.meta(omittable: true)
14
16
  end
15
17
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Cocina
4
4
  module Models
5
- class DescriptiveValueRequired < Struct
5
+ class Title < Struct
6
6
  attribute :structuredValue, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
7
7
  attribute :parallelValue, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
8
8
  # String or integer value of the descriptive element.
@@ -17,6 +17,7 @@ module Cocina
17
17
  attribute :uri, Types::Strict::String.meta(omittable: true)
18
18
  attribute :standard, Standard.optional.meta(omittable: true)
19
19
  attribute :encoding, Standard.optional.meta(omittable: true)
20
+ attribute :identifier, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true)
20
21
  attribute :source, Source.optional.meta(omittable: true)
21
22
  # The preferred display label to use for the descriptive element in access systems.
22
23
  attribute :displayLabel, Types::Strict::String.meta(omittable: true)
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Cocina
4
4
  module Models
5
- VERSION = '0.40.1'
5
+ VERSION = '0.44.0'
6
6
  end
7
7
  end
@@ -108,15 +108,6 @@ components:
108
108
  - 'citation-only'
109
109
  - 'dark'
110
110
  default: 'dark'
111
- download:
112
- description: Download access level for a file
113
- type: string
114
- enum:
115
- - 'world'
116
- - 'stanford'
117
- - 'location-based'
118
- - 'none'
119
- default: 'none'
120
111
  readLocation:
121
112
  description: If access is "location-based", which location should have access.
122
113
  type: string
@@ -295,7 +286,7 @@ components:
295
286
  type: array
296
287
  minItems: 1
297
288
  items:
298
- $ref: "#/components/schemas/DescriptiveValueRequired"
289
+ $ref: "#/components/schemas/Title"
299
290
  contributor:
300
291
  description: Agents contributing in some way to the creation and history of the
301
292
  resource.
@@ -309,10 +300,15 @@ components:
309
300
  $ref: "#/components/schemas/Event"
310
301
  form:
311
302
  description: Characteristics of the resource's physical, digital, and intellectual
312
- form and genre.
303
+ form and genre, and of its process of creation.
313
304
  type: array
314
305
  items:
315
306
  $ref: "#/components/schemas/DescriptiveValue"
307
+ geographic:
308
+ description: Geographic description for items with coordinates or bounding boxes.
309
+ type: array
310
+ items:
311
+ $ref: "#/components/schemas/DescriptiveGeographicMetadata"
316
312
  language:
317
313
  description: Languages, scripts, symbolic systems, and notations used in all or
318
314
  part of a resource.
@@ -369,6 +365,11 @@ components:
369
365
  type: array
370
366
  items:
371
367
  $ref: "#/components/schemas/DescriptiveValue"
368
+ digitalLocation:
369
+ description: Location of a digital version of the resource, such as a file path for a born digital resource.
370
+ type: array
371
+ items:
372
+ $ref: "#/components/schemas/DescriptiveValue"
372
373
  accessContact:
373
374
  description: The library, organization, or person responsible for access to the resource.
374
375
  type: array
@@ -433,7 +434,10 @@ components:
433
434
  description: String or integer value of the descriptive element.
434
435
  oneOf:
435
436
  - type: string
436
- - type: integer
437
+ # Title note (nonsorting character count) was supposed to be able to accept an integer value,
438
+ # but this triggered a bug in committee:
439
+ # https://github.com/interagent/committee/issues/286
440
+ # - type: integer
437
441
  type:
438
442
  description: Type of value provided by the descriptive element.
439
443
  type: string
@@ -454,6 +458,11 @@ components:
454
458
  encoding:
455
459
  # description: Encoding schema, standard, or syntax to which the value conforms.
456
460
  $ref: "#/components/schemas/Standard"
461
+ identifier:
462
+ description: Identifiers and URIs associated with the descriptive element.
463
+ type: array
464
+ items:
465
+ $ref: "#/components/schemas/DescriptiveValue"
457
466
  source:
458
467
  $ref: "#/components/schemas/Source"
459
468
  displayLabel:
@@ -469,6 +478,20 @@ components:
469
478
  $ref: "#/components/schemas/DescriptiveValue"
470
479
  valueLanguage:
471
480
  $ref: "#/components/schemas/DescriptiveValueLanguage"
481
+ DescriptiveGeographicMetadata:
482
+ description: Value model for mods geographic extension metadata
483
+ type: object
484
+ additionalProperties: false
485
+ properties:
486
+ form:
487
+ type: array
488
+ items:
489
+ $ref: "#/components/schemas/DescriptiveValue"
490
+ subject:
491
+ description: Terms associated with the intellectual content of the related resource.
492
+ type: array
493
+ items:
494
+ $ref: "#/components/schemas/DescriptiveValue"
472
495
  DescriptiveParallelValue:
473
496
  description: Value model for multiple representations of the same information (e.g. in different languages).
474
497
  type: object
@@ -506,7 +529,7 @@ components:
506
529
  $ref: '#/components/schemas/Standard'
507
530
  # description: An alphabet or other notation used to represent a
508
531
  # language or other symbolic system of the descriptive element value.
509
- DescriptiveValueRequired:
532
+ Title:
510
533
  type: object
511
534
  additionalProperties: false
512
535
  allOf:
@@ -691,6 +714,9 @@ components:
691
714
  type:
692
715
  description: Description of the event (creation, publication, etc.).
693
716
  type: string
717
+ displayLabel:
718
+ description: The preferred display label to use for the event in access systems.
719
+ type: string
694
720
  date:
695
721
  description: Dates associated with the event.
696
722
  type: array
@@ -706,6 +732,11 @@ components:
706
732
  type: array
707
733
  items:
708
734
  $ref: "#/components/schemas/DescriptiveValue"
735
+ identifier:
736
+ description: Identifiers and URIs associated with the event.
737
+ type: array
738
+ items:
739
+ $ref: "#/components/schemas/DescriptiveValue"
709
740
  note:
710
741
  description: Other information about the event.
711
742
  type: array
@@ -871,17 +902,62 @@ components:
871
902
  or part of a resource or its descriptive metadata.
872
903
  type: object
873
904
  additionalProperties: false
874
- allOf:
875
- - $ref: '#/components/schemas/DescriptiveValue'
876
- - type: object
877
- # additionalProperties breaks the validator, presumably because it can't
878
- # conform to other schemas (allOf) and not have additionalProperties
879
- # additionalProperties: false
880
- properties:
881
- script:
882
- $ref: '#/components/schemas/DescriptiveValue'
883
- # description: An alphabet or other notation used to represent a
884
- # language or other symbolic system associated with the resource.
905
+ properties:
906
+ appliesTo:
907
+ type: array
908
+ items:
909
+ $ref: "#/components/schemas/DescriptiveBasicValue"
910
+ code:
911
+ description: Code value of the descriptive element.
912
+ type: string
913
+ displayLabel:
914
+ description: The preferred display label to use for the descriptive element in access systems.
915
+ type: string
916
+ encoding:
917
+ # description: present for mapping to additional schemas in the future and for consistency but not otherwise used
918
+ $ref: "#/components/schemas/Standard"
919
+ note:
920
+ description: present for mapping to additional schemas in the future and for consistency but not otherwise used
921
+ type: array
922
+ items:
923
+ $ref: "#/components/schemas/DescriptiveValue"
924
+ parallelValue:
925
+ description: present for mapping to additional schemas in the future and for consistency but not otherwise used
926
+ type: array
927
+ items:
928
+ $ref: "#/components/schemas/DescriptiveValue"
929
+ qualifier:
930
+ type: string
931
+ description: present for mapping to additional schemas in the future and for consistency but not otherwise used
932
+ script:
933
+ $ref: '#/components/schemas/DescriptiveValue'
934
+ # description: An alphabet or other notation used to represent a
935
+ # language or other symbolic system associated with the resource.
936
+ source:
937
+ $ref: "#/components/schemas/Source"
938
+ status:
939
+ description: Status of the language relative to other parallel language elements (e.g. the primary language)
940
+ type: string
941
+ enum:
942
+ - primary
943
+ standard:
944
+ # description: present for mapping to additional schemas in the future and for consistency but not otherwise used
945
+ $ref: "#/components/schemas/Standard"
946
+ structuredValue:
947
+ description: present for mapping to additional schemas in the future and for consistency but not otherwise used
948
+ type: array
949
+ items:
950
+ $ref: "#/components/schemas/DescriptiveValue"
951
+ uri:
952
+ description: URI value of the descriptive element.
953
+ type: string
954
+ format: uri
955
+ value:
956
+ description: Value of the descriptive element.
957
+ type: string
958
+ valueLanguage:
959
+ # description: present for mapping to additional schemas in the future and for consistency but not otherwise used
960
+ $ref: "#/components/schemas/DescriptiveValueLanguage"
885
961
  MessageDigest:
886
962
  description: The output of the message digest algorithm.
887
963
  type: object
@@ -894,7 +970,7 @@ components:
894
970
  - md5
895
971
  - sha1
896
972
  digest:
897
- description: The digest value Base64 encoded
973
+ description: The digest value hexidecimal encoded
898
974
  type: string
899
975
  required:
900
976
  - type
@@ -918,6 +994,12 @@ components:
918
994
  type:
919
995
  description: The relationship of the related resource to the described resource.
920
996
  type: string
997
+ status:
998
+ description: Status of the related resource relative to other related resources.
999
+ type: string
1000
+ displayLabel:
1001
+ description: The preferred display label to use for the related resource in access systems.
1002
+ type: string
921
1003
  title:
922
1004
  description: Titles of the related resource.
923
1005
  type: array
@@ -936,7 +1018,7 @@ components:
936
1018
  $ref: "#/components/schemas/Event"
937
1019
  form:
938
1020
  description: Characteristics of the related resource's physical, digital, and intellectual
939
- form and genre.
1021
+ form and genre, and of its process of creation.
940
1022
  type: array
941
1023
  items:
942
1024
  $ref: "#/components/schemas/DescriptiveValue"
@@ -956,6 +1038,9 @@ components:
956
1038
  type: array
957
1039
  items:
958
1040
  $ref: "#/components/schemas/DescriptiveValue"
1041
+ standard:
1042
+ # description: Descriptive or content standards to which the value conforms.
1043
+ $ref: "#/components/schemas/Standard"
959
1044
  subject:
960
1045
  description: Terms associated with the intellectual content of the related resource.
961
1046
  type: array
@@ -967,6 +1052,16 @@ components:
967
1052
  format: uri
968
1053
  access:
969
1054
  $ref: "#/components/schemas/DescriptiveAccessMetadata"
1055
+ relatedResource:
1056
+ description: Other resources associated with the related resource.
1057
+ type: array
1058
+ items:
1059
+ $ref: "#/components/schemas/RelatedResource"
1060
+ adminMetadata:
1061
+ $ref: "#/components/schemas/DescriptiveAdminMetadata"
1062
+ version:
1063
+ description: The version of the related resource.
1064
+ type: string
970
1065
  ReleaseTag:
971
1066
  description: A tag that indicates the item or collection should be released.
972
1067
  type: object
@@ -1234,6 +1329,9 @@ components:
1234
1329
  type: array
1235
1330
  items:
1236
1331
  $ref: "#/components/schemas/DescriptiveValue"
1332
+ version:
1333
+ description: The version of the value source.
1334
+ type: string
1237
1335
  SourceId:
1238
1336
  type: string
1239
1337
  pattern: '^.+:.+$'
@@ -1247,7 +1345,7 @@ components:
1247
1345
  example: 'sul:PC0170_s3_Fiesta_Bowl_2012-01-02_210609_2026'
1248
1346
  Standard:
1249
1347
  description: Property model for indicating the encoding, standard, or syntax
1250
- to which a value conforms.
1348
+ to which a value conforms (e.g. RDA).
1251
1349
  type: object
1252
1350
  additionalProperties: false
1253
1351
  properties:
@@ -1266,5 +1364,8 @@ components:
1266
1364
  type: array
1267
1365
  items:
1268
1366
  $ref: "#/components/schemas/DescriptiveValue"
1367
+ version:
1368
+ description: The version of the standard or encoding.
1369
+ type: string
1269
1370
  source:
1270
1371
  $ref: "#/components/schemas/Source"
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.40.1
4
+ version: 0.44.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-09-10 00:00:00.000000000 Z
11
+ date: 2020-12-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -267,11 +267,11 @@ files:
267
267
  - lib/cocina/models/descriptive_access_metadata.rb
268
268
  - lib/cocina/models/descriptive_admin_metadata.rb
269
269
  - lib/cocina/models/descriptive_basic_value.rb
270
+ - lib/cocina/models/descriptive_geographic_metadata.rb
270
271
  - lib/cocina/models/descriptive_parallel_value.rb
271
272
  - lib/cocina/models/descriptive_structured_value.rb
272
273
  - lib/cocina/models/descriptive_value.rb
273
274
  - lib/cocina/models/descriptive_value_language.rb
274
- - lib/cocina/models/descriptive_value_required.rb
275
275
  - lib/cocina/models/dro.rb
276
276
  - lib/cocina/models/dro_access.rb
277
277
  - lib/cocina/models/dro_structural.rb
@@ -302,6 +302,7 @@ files:
302
302
  - lib/cocina/models/source.rb
303
303
  - lib/cocina/models/source_id.rb
304
304
  - lib/cocina/models/standard.rb
305
+ - lib/cocina/models/title.rb
305
306
  - lib/cocina/models/validator.rb
306
307
  - lib/cocina/models/version.rb
307
308
  - lib/cocina/models/vocab.rb