Sha256: daedb8e2b03fed786dd8e494210892579473a65add8db77f5ec9aa89282ba546
Contents?: true
Size: 1.18 KB
Versions: 8
Compression:
Stored size: 1.18 KB
Contents
# frozen_string_literal: true module Cocina module Models class RequestFile < Struct include Checkable TYPES = ['https://cocina.sul.stanford.edu/models/file'].freeze attribute :type, Types::Strict::String.enum(*RequestFile::TYPES) attribute :label, Types::Strict::String attribute :filename, Types::Strict::String attribute? :size, Types::Strict::Integer attribute :version, Types::Strict::Integer attribute? :hasMimeType, Types::Strict::String # BCP 47 language tag: https://www.rfc-editor.org/rfc/rfc4646.txt -- other applications (like media players) expect language codes of this format, see e.g. https://videojs.com/guides/text-tracks/#srclang attribute? :languageTag, LanguageTag.optional attribute? :externalIdentifier, Types::Strict::String # Use for the File. attribute? :use, FileUse.optional attribute :hasMessageDigests, Types::Strict::Array.of(MessageDigest).default([].freeze) attribute(:access, FileAccess.default { FileAccess.new }) attribute(:administrative, FileAdministrative.default { FileAdministrative.new }) attribute? :presentation, Presentation.optional end end end
Version data entries
8 entries across 8 versions & 1 rubygems