Sha256: f072191367f0611cfffa1818db879c31aaa0eb3825781577a55fb239594b3a10

Contents?: true

Size: 675 Bytes

Versions: 6

Compression:

Stored size: 675 Bytes

Contents

module Hyrax
  class CurationConcern
    # This attribute is set by Hyrax::Engine
    class_attribute :actor_factory

    self.actor_factory = Hyrax::ActorFactory

    # A consumer of this method can inject a different factory
    # into this class in order to change the behavior of this method.
    # @param [ActiveFedora::Base] curation_concern a work to be updated
    # @param [Ability] current_ability the permission object for depositing this
    #   work.
    # @return [#create, #update] an actor that can create and update the work
    def self.actor(curation_concern, current_ability)
      actor_factory.build(curation_concern, current_ability)
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
geo_works-0.2.0 app/services/hyrax/curation_concern.rb
geo_works-0.1.4 app/services/hyrax/curation_concern.rb
geo_works-0.1.3 app/services/hyrax/curation_concern.rb
geo_works-0.1.2 app/services/hyrax/curation_concern.rb
geo_works-0.1.1 app/services/hyrax/curation_concern.rb
geo_works-0.1.0 app/services/hyrax/curation_concern.rb