Class: Hydra::Config::PermissionsConfig::LeaseConfig

Inherits:
Object
  • Object
show all
Defined in:
lib/hydra/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(values = {}, attributes = {prefix:''}) ⇒ LeaseConfig

Returns a new instance of LeaseConfig.



153
154
155
156
157
158
# File 'lib/hydra/config.rb', line 153

def initialize(values = {}, attributes={prefix:''})
  @expiration_date = solr_name("#{attributes[:prefix]}lease_expiration_date", :stored_sortable, type: :date)
  @visibility_during = solr_name("visibility_during_lease", :symbol)
  @visibility_after = solr_name("visibility_after_lease", :symbol)
  @history = solr_name("lease_history", :symbol)
end

Instance Attribute Details

#expiration_dateObject

Returns the value of attribute expiration_date.



152
153
154
# File 'lib/hydra/config.rb', line 152

def expiration_date
  @expiration_date
end

#historyObject

Returns the value of attribute history.



152
153
154
# File 'lib/hydra/config.rb', line 152

def history
  @history
end

#visibility_afterObject

Returns the value of attribute visibility_after.



152
153
154
# File 'lib/hydra/config.rb', line 152

def visibility_after
  @visibility_after
end

#visibility_duringObject

Returns the value of attribute visibility_during.



152
153
154
# File 'lib/hydra/config.rb', line 152

def visibility_during
  @visibility_during
end

Instance Method Details

#solr_name(*args) ⇒ Object



160
161
162
# File 'lib/hydra/config.rb', line 160

def solr_name(*args)
  ActiveFedora.index_field_mapper.solr_name(*args)
end