cocina-models 0.61.1 → 0.62.1

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: 04d6817bcbdb69d319cc3506afef0f7d8374bb8668e6fbdf05a47b6eab40cb3a
4
- data.tar.gz: d36dc1283dc12c3f9bdd881f3c9268e2b6088f0c11d35dcbc9d5adf2bf749513
3
+ metadata.gz: cec7a3ac1ecbadbdbcb8faaa1311e9c03843af53b4256d3694e23c6834b91bbe
4
+ data.tar.gz: 12d1fa927c36ba962b790ef6b2c2d048c7af6251416d286a6392dc6175551164
5
5
  SHA512:
6
- metadata.gz: e75b2cd3134d4b75a30f3511cc5f861001e70f274b53c92988575640460b9869993e18378bf05484d21ab18a7f0ce0a56db714b46718aab288b26202db1ed384
7
- data.tar.gz: 152173ef29e9b971ee2c58ddbd77f6b284576c6be8cbe02fdd043535615d773a50f1df890b9bd7b2c8e10c8a36b3e4b9cb851390132103121cf52534453dce07
6
+ metadata.gz: 10aed08575f11ceb53cebd61603448de768690b10cd06b64bfc6964f4b23fb0827546e18e1a25a5e14c338cc60e0147ad608dbdccb92cd7993dc9c6c2a6c8e86
7
+ data.tar.gz: 6fb48b45f9c87fbb8f517ca523d58c22884f3b1e2dc1b428718083e4463fb59909d02306373bfa999a1cc66237d857dc3cc7c56353666883517325cf718628c0
@@ -944,7 +944,7 @@ xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/
944
944
  <note>Submitted to the Graduate School of Education.</note>
945
945
  <note type="thesis">Thesis (Ph.D.)--Stanford University, 2015.</note>
946
946
  <location>
947
- <url displayLabel="electronic resource" usage="primary display">http://purl.stanford.edu/xn109qc9773</url>
947
+ <url displayLabel="electronic resource" usage="primary display">https://purl.stanford.edu/xn109qc9773</url>
948
948
  </location>
949
949
  <recordInfo>
950
950
  <recordContentSource authority="marcorg">CSt</recordContentSource>
@@ -86,7 +86,7 @@
86
86
 
87
87
  :xn109qc9773_item [ a bf:Item ;
88
88
  bf:electronicLocator [ a rdf:Resource ;
89
- rdf:value <http://purl.stanford.edu/xn109qc9773> ;
89
+ rdf:value <https://purl.stanford.edu/xn109qc9773> ;
90
90
  bf:note [ a bf:Note ;
91
91
  rdfs:label "primary display" ;
92
92
  bf:noteType "URL usage"
@@ -151,7 +151,7 @@
151
151
  ],
152
152
  "accessURL": [{
153
153
  "type": "purl",
154
- "url": "http://purl.stanford.edu/xn109qc9773",
154
+ "url": "https://purl.stanford.edu/xn109qc9773",
155
155
  "primary": "TRUE"
156
156
  }]
157
157
  }
@@ -3,7 +3,7 @@
3
3
  module Cocina
4
4
  module Models
5
5
  DOI = Types::String.constrained(
6
- format: %r{^10\.25740/druid:[b-df-hjkmnp-tv-z]{2}[0-9]{3}[b-df-hjkmnp-tv-z]{2}[0-9]{4}$}i
6
+ format: %r{^10\.(25740|80343)/[b-df-hjkmnp-tv-z]{2}[0-9]{3}[b-df-hjkmnp-tv-z]{2}[0-9]{4}$}i
7
7
  )
8
8
  end
9
9
  end
@@ -3,7 +3,7 @@
3
3
  module Cocina
4
4
  module Models
5
5
  Purl = Types::String.constrained(
6
- format: %r{^http://}i
6
+ format: %r{^https://}i
7
7
  )
8
8
  end
9
9
  end
@@ -6,9 +6,6 @@ module Cocina
6
6
  # A barcode
7
7
  attribute :barcode, Types::Nominal::Any.meta(omittable: true)
8
8
  attribute :catalogLinks, Types::Strict::Array.of(CatalogLink).meta(omittable: true)
9
- # Digital Object Identifier (https://www.doi.org)
10
- # example: 10.25740/druid:bc123df4567
11
- attribute :doi, Types::Strict::String.meta(omittable: true)
12
9
  # Unique identifier in some other system. This is because a large proportion of what is deposited in SDR, historically and currently, are representations of objects that are also represented in other systems. For example, digitized paper and A/V collections have physical manifestations, and those physical objects are managed in systems that have their own identifiers. Similarly, books have barcodes, archival materials have collection numbers and physical locations, etc. The sourceId allows determining if an item has been deposited before and where to look for the original item if you're looking at its SDR representation. The format is: "namespace:identifier"
13
10
 
14
11
  # example: sul:PC0170_s3_Fiesta_Bowl_2012-01-02_210609_2026
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Cocina
4
4
  module Models
5
- VERSION = '0.61.1'
5
+ VERSION = '0.62.1'
6
6
  end
7
7
  end
data/lib/cocina/models.rb CHANGED
@@ -8,6 +8,7 @@ require 'json'
8
8
  require 'yaml'
9
9
  require 'openapi_parser'
10
10
  require 'openapi3_parser'
11
+ require 'active_support'
11
12
  require 'active_support/core_ext/hash/indifferent_access'
12
13
  require 'active_support/core_ext/string'
13
14
  require 'thor'
data/openapi.yml CHANGED
@@ -878,8 +878,9 @@ components:
878
878
  DOI:
879
879
  type: string
880
880
  description: Digital Object Identifier (https://www.doi.org)
881
- pattern: '^10\.25740\/druid:[b-df-hjkmnp-tv-z]{2}[0-9]{3}[b-df-hjkmnp-tv-z]{2}[0-9]{4}$'
882
- example: '10.25740/druid:bc123df4567'
881
+ # The prod and test prefixes are permitted
882
+ pattern: '^10\.(25740|80343)\/[b-df-hjkmnp-tv-z]{2}[0-9]{3}[b-df-hjkmnp-tv-z]{2}[0-9]{4}$'
883
+ example: '10.25740/bc123df4567'
883
884
  DRO:
884
885
  description: Domain-defined abstraction of a 'work'. Digital Repository Objects' abstraction is describable for our domain’s purposes, i.e. for management needs within our system.
885
886
  type: object
@@ -1395,8 +1396,8 @@ components:
1395
1396
  description: Stanford persistent URL associated with the related resource. Note this is http, not https.
1396
1397
  type: string
1397
1398
  format: uri
1398
- # Canonical URI is http, even though this redirects to https.
1399
- pattern: '^http:\/\/'
1399
+ # Canonical URI is https
1400
+ pattern: '^https:\/\/'
1400
1401
  RelatedResource:
1401
1402
  description: Other resource associated with the described resource.
1402
1403
  type: object
@@ -1704,7 +1705,9 @@ components:
1704
1705
  items:
1705
1706
  $ref: '#/components/schemas/RequestFile'
1706
1707
  RequestIdentification:
1707
- description: Same as a Identification, but requires a sourceId.
1708
+ # Doesn't permit a DOI because our DOIs all use the DRUID as part of the DOI.
1709
+ # You have to register the object in order to get the DRUID before you can mint a DOI
1710
+ description: Same as a Identification, but requires a sourceId and doesn't permit a DOI.
1708
1711
  type: object
1709
1712
  additionalProperties: false
1710
1713
  properties:
@@ -1714,8 +1717,6 @@ components:
1714
1717
  type: array
1715
1718
  items:
1716
1719
  $ref: '#/components/schemas/CatalogLink'
1717
- doi:
1718
- $ref: '#/components/schemas/DOI'
1719
1720
  sourceId:
1720
1721
  $ref: '#/components/schemas/SourceId'
1721
1722
  required:
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.61.1
4
+ version: 0.62.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Justin Coyne
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-07-07 00:00:00.000000000 Z
11
+ date: 2021-12-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport