Sha256: bfbf6697da54493594e6e760356ccf6bc9edc6b36560b3162506144933396f1b

Contents?: true

Size: 1.36 KB

Versions: 1

Compression:

Stored size: 1.36 KB

Contents

module CurationConcerns
  module FileSetBehavior
    extend ActiveSupport::Concern
    # BasicMetadata needs to be included before Characterization since
    # both of them declare properties with the same predicate (dc:creator
    # and dc:language.) Loading BasicMetadata first allows Characterization
    # to detect the duplicate (via the AlreadyThereStrategy) and prevents
    # the warning.
    include CurationConcerns::BasicMetadata
    include Hydra::Works::FileSetBehavior
    include Hydra::Works::VirusCheck
    include CurationConcerns::Characterization
    include Hydra::WithDepositor
    include CurationConcerns::Serializers
    include CurationConcerns::Noid
    include CurationConcerns::FileSet::Derivatives
    include CurationConcerns::Permissions
    include CurationConcerns::FileSet::FullTextIndexing
    include CurationConcerns::FileSet::Indexing
    include CurationConcerns::FileSet::BelongsToWorks
    include CurationConcerns::FileSet::Querying
    include CurationConcerns::HumanReadableType
    include CurationConcerns::RequiredMetadata
    include CurationConcerns::Naming
    include Hydra::AccessControls::Embargoable
    include GlobalID::Identification

    included do
      attr_accessor :file
      self.human_readable_type = 'File'
    end

    def representative_id
      to_param
    end

    def thumbnail_id
      to_param
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
curation_concerns-1.0.0.beta2 app/models/concerns/curation_concerns/file_set_behavior.rb