Class: ChildAccessor
- Inherits:
-
Object
- Object
- ChildAccessor
- Defined in:
- lib/fathom/archive/conditional_probability_matrix.rb
Instance Attribute Summary collapse
-
#cpm ⇒ Object
readonly
Returns the value of attribute cpm.
-
#labels ⇒ Object
readonly
Returns the value of attribute labels.
Instance Method Summary collapse
- #given(parent_name) ⇒ Object
-
#initialize(cpm, *labels) ⇒ ChildAccessor
constructor
A new instance of ChildAccessor.
Constructor Details
#initialize(cpm, *labels) ⇒ ChildAccessor
Returns a new instance of ChildAccessor.
26 27 28 |
# File 'lib/fathom/archive/conditional_probability_matrix.rb', line 26 def initialize(cpm, *labels) @cpm, @labels = cpm, labels end |
Instance Attribute Details
#cpm ⇒ Object (readonly)
Returns the value of attribute cpm.
25 26 27 |
# File 'lib/fathom/archive/conditional_probability_matrix.rb', line 25 def cpm @cpm end |
#labels ⇒ Object (readonly)
Returns the value of attribute labels.
25 26 27 |
# File 'lib/fathom/archive/conditional_probability_matrix.rb', line 25 def labels @labels end |
Instance Method Details
#given(parent_name) ⇒ Object
30 31 32 |
# File 'lib/fathom/archive/conditional_probability_matrix.rb', line 30 def given(parent_name) ParentAccessor.new(cpm, labels) end |