Class: Neo4j::MetaModel::HasAssociation

Inherits:
Object
  • Object
show all
Includes:
ActiveRel
Defined in:
app/models/neo4j/meta_model/has_association.rb

Instance Method Summary collapse

Instance Method Details

#from_modelObject



22
23
24
# File 'app/models/neo4j/meta_model/has_association.rb', line 22

def from_model
  from_node
end

#from_model=(other) ⇒ Object



30
31
32
# File 'app/models/neo4j/meta_model/has_association.rb', line 30

def from_model=(other)
  self.from_node = other
end

#from_model_id=(id) ⇒ Object



38
39
40
# File 'app/models/neo4j/meta_model/has_association.rb', line 38

def from_model_id=(id)
  self.from_model = Model.find(id)
end

#to_modelObject



26
27
28
# File 'app/models/neo4j/meta_model/has_association.rb', line 26

def to_model
  to_node
end

#to_model=(other) ⇒ Object



34
35
36
# File 'app/models/neo4j/meta_model/has_association.rb', line 34

def to_model=(other)
  self.to_node = other
end

#to_model_id=(id) ⇒ Object



42
43
44
# File 'app/models/neo4j/meta_model/has_association.rb', line 42

def to_model_id=(id)
  self.to_model = Model.find(id)
end