Sha256: c6a57ebf42406791f088708ce04ac9b5309d902a9a9d80c1ea51e2abf1eee8a2
Contents?: true
Size: 1.72 KB
Versions: 22
Compression:
Stored size: 1.72 KB
Contents
# frozen_string_literal: true module Cocina module Models class Description < Struct attribute :title, Types::Strict::Array.of(Title).default([].freeze) attribute :contributor, Types::Strict::Array.of(Contributor).meta(omittable: true) attribute :event, Types::Strict::Array.of(Event).meta(omittable: true) attribute :form, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true) attribute :geographic, Types::Strict::Array.of(DescriptiveGeographicMetadata).meta(omittable: true) attribute :language, Types::Strict::Array.of(Language).meta(omittable: true) attribute :note, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true) attribute :identifier, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true) attribute :subject, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true) # Stanford persistent URL associated with the resource. attribute :purl, Types::Strict::String.meta(omittable: true) attribute :access, DescriptiveAccessMetadata.optional.meta(omittable: true) attribute :relatedResource, Types::Strict::Array.of(RelatedResource).meta(omittable: true) attribute :marcEncodedData, Types::Strict::Array.of(DescriptiveValue).meta(omittable: true) attribute :adminMetadata, DescriptiveAdminMetadata.optional.meta(omittable: true) # URL or other pointer to the location of the resource description. attribute :valueAt, Types::Strict::String.meta(omittable: true) def self.new(attributes = default_attributes, safe = false, validate = true, &block) Validator.validate(self, attributes.with_indifferent_access) if validate && name super(attributes, safe, &block) end end end end
Version data entries
22 entries across 22 versions & 1 rubygems