Class: ActiveForce::Association::AbstractBuildFrom

Inherits:
Object
  • Object
show all
Defined in:
lib/active_force/association/relation_model_builder.rb

Direct Known Subclasses

BuildFromArray, BuildFromHash, BuildFromNilClass

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(association, value, association_mapping = {}) ⇒ AbstractBuildFrom

Returns a new instance of AbstractBuildFrom.



34
35
36
37
38
# File 'lib/active_force/association/relation_model_builder.rb', line 34

def initialize(association, value, association_mapping = {})
  @association = association
  @value = value
  @association_mapping = association_mapping
end

Instance Attribute Details

#associationObject (readonly)

Returns the value of attribute association.



32
33
34
# File 'lib/active_force/association/relation_model_builder.rb', line 32

def association
  @association
end

#association_mappingObject (readonly)

Returns the value of attribute association_mapping.



32
33
34
# File 'lib/active_force/association/relation_model_builder.rb', line 32

def association_mapping
  @association_mapping
end

#valueObject (readonly)

Returns the value of attribute value.



32
33
34
# File 'lib/active_force/association/relation_model_builder.rb', line 32

def value
  @value
end

Instance Method Details

#callObject



40
41
42
# File 'lib/active_force/association/relation_model_builder.rb', line 40

def call
  raise "Must implement #{self.class.name}#call"
end