Class: Fog::Associations::OracleDefault
- Inherits:
-
Default
- Object
- Default
- Fog::Associations::OracleDefault
show all
- Defined in:
- lib/fog/oracle/models/associations.rb
Instance Method Summary
collapse
Instance Method Details
#create_getter ⇒ Object
12
13
14
15
16
17
18
|
# File 'lib/fog/oracle/models/associations.rb', line 12
def create_getter
model.class_eval <<-EOS, __FILE__, __LINE__
def #{name}
associations[:#{name}]
end
EOS
end
|
#create_setter ⇒ Object
4
5
6
7
8
9
10
|
# File 'lib/fog/oracle/models/associations.rb', line 4
def create_setter
model.class_eval <<-EOS, __FILE__, __LINE__
def #{name}=(new_#{name})
associations[:#{name}] = new_#{name}
end
EOS
end
|