class IIIF::Presentation::Collection

Constants

TYPE

Public Class Methods

new(hsh={}) click to toggle source
# File lib/iiif/presentation/collection.rb, line 17
def initialize(hsh={})
  hsh['@type'] = TYPE unless hsh.has_key? '@type'
  super(hsh)
end

Public Instance Methods

array_only_keys() click to toggle source
# File lib/iiif/presentation/collection.rb, line 13
def array_only_keys
  super + %w{ collections manifests }
end
required_keys() click to toggle source
# File lib/iiif/presentation/collection.rb, line 9
def required_keys
  super + %w{ @id label }
end
validate() click to toggle source
# File lib/iiif/presentation/collection.rb, line 22
def validate
  # each member of collections and manifests must be a Hash
  # each member of collections and manifests MUST have @id, @type, and label
end