Class: Ice::BaseCube
- Extended by:
- CubeAssociation
- Defined in:
- lib/ice/base_cube.rb
Instance Attribute Summary collapse
-
#source ⇒ Object
readonly
Returns the value of attribute source.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(source) ⇒ BaseCube
constructor
A new instance of BaseCube.
- #to_ice ⇒ Object
Methods included from CubeAssociation
Constructor Details
#initialize(source) ⇒ BaseCube
Returns a new instance of BaseCube.
20 21 22 |
# File 'lib/ice/base_cube.rb', line 20 def initialize(source) @source = source end |
Instance Attribute Details
#source ⇒ Object (readonly)
Returns the value of attribute source.
14 15 16 |
# File 'lib/ice/base_cube.rb', line 14 def source @source end |
Class Method Details
.revealing(*attributes) ⇒ Object
5 6 7 8 9 10 11 12 |
# File 'lib/ice/base_cube.rb', line 5 def self.revealing(* attributes) attributes.each do |attr| define_method attr.to_sym do @source.send(attr).to_ice end end end |
Instance Method Details
#to_ice ⇒ Object
16 17 18 |
# File 'lib/ice/base_cube.rb', line 16 def to_ice self end |