Class: Yacl::Define::Plan::Item

Inherits:
Object
  • Object
show all
Defined in:
lib/yacl/define/plan.rb

Overview

Internal: An internal class used to encapsulate the individual items of the lookup plan.

Instance Method Summary collapse

Constructor Details

#initialize(klass, options) ⇒ Item

Internal: Create a new Item. Thiis is what is created from a call to Plan.try



42
43
44
45
# File 'lib/yacl/define/plan.rb', line 42

def initialize( klass, options )
  @loader_klass = klass
  @options      = options
end

Instance Method Details

#load_properties(params) ⇒ Object

Internal: load hte properties from the given Loader class

Returns a Properties instance



50
51
52
53
54
# File 'lib/yacl/define/plan.rb', line 50

def load_properties( params )
  opt    = @options.merge( params )
  loader = @loader_klass.new( opt )
  loader.properties
end