Module: Hyrax::FileSetBehavior

Extended by:
ActiveSupport::Concern
Includes:
Hydra::AccessControls::Embargoable, Hydra::WithDepositor, Hydra::Works::FileSetBehavior, BasicMetadata, CoreMetadata, Hyrax::FileSet::BelongsToWorks, Hyrax::FileSet::Characterization, Hyrax::FileSet::Derivatives, Hyrax::FileSet::Indexing, Hyrax::FileSet::Querying, Hyrax::FileSet::Transcripts, HumanReadableType, Naming, Noid, Permissions, Serializers, VirusCheck, WithEvents
Defined in:
app/models/concerns/hyrax/file_set_behavior.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods included from HumanReadableType

#human_readable_type, #to_solr

Methods included from Hyrax::FileSet::BelongsToWorks

#parent, #parents, #related_files

Methods included from Permissions::Readable

#private?, #public?, #registered?

Methods included from Permissions::Writable

#paranoid_permissions

Methods included from Noid

#assign_id

Methods included from Serializers

#to_s

Methods included from WithEvents

#event_class, #events, #log_event, #stream

Class Method Details

.flexible?Boolean

Returns:

  • (Boolean)


43
44
45
# File 'app/models/concerns/hyrax/file_set_behavior.rb', line 43

def self.flexible?
  false
end

Instance Method Details

#flexible?Boolean

Returns:

  • (Boolean)


47
48
49
# File 'app/models/concerns/hyrax/file_set_behavior.rb', line 47

def flexible?
  false
end

#representative_idObject



29
30
31
# File 'app/models/concerns/hyrax/file_set_behavior.rb', line 29

def representative_id
  to_param
end

#thumbnail_idObject



33
34
35
# File 'app/models/concerns/hyrax/file_set_behavior.rb', line 33

def thumbnail_id
  to_param
end

#to_presenterObject

Cast to a SolrDocument by querying from Solr



38
39
40
41
# File 'app/models/concerns/hyrax/file_set_behavior.rb', line 38

def to_presenter
  Deprecation.warn "Method #to_presenter will be removed in Hyrax 5.0. Use Hyrax::FileSetsController#presenter.solr_document or `@presenter.solr_document` from a view instead."
  Blacklight::SearchService.new(config: CatalogController.blacklight_config).fetch(id).last
end