Class: DecisionAgent::Dmn::Input
- Inherits:
-
Object
- Object
- DecisionAgent::Dmn::Input
- Defined in:
- lib/decision_agent/dmn/model.rb
Overview
Input clause (column) in decision table
Instance Attribute Summary collapse
-
#expression ⇒ Object
readonly
Returns the value of attribute expression.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#label ⇒ Object
readonly
Returns the value of attribute label.
-
#type_ref ⇒ Object
readonly
Returns the value of attribute type_ref.
Instance Method Summary collapse
- #freeze ⇒ Object
-
#initialize(id:, label:, expression: nil, type_ref: "string") ⇒ Input
constructor
A new instance of Input.
Constructor Details
#initialize(id:, label:, expression: nil, type_ref: "string") ⇒ Input
Returns a new instance of Input.
129 130 131 132 133 134 |
# File 'lib/decision_agent/dmn/model.rb', line 129 def initialize(id:, label:, expression: nil, type_ref: "string") @id = id.to_s @label = label.to_s @expression = expression&.to_s || label.to_s @type_ref = type_ref.to_s end |
Instance Attribute Details
#expression ⇒ Object (readonly)
Returns the value of attribute expression.
127 128 129 |
# File 'lib/decision_agent/dmn/model.rb', line 127 def expression @expression end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
127 128 129 |
# File 'lib/decision_agent/dmn/model.rb', line 127 def id @id end |
#label ⇒ Object (readonly)
Returns the value of attribute label.
127 128 129 |
# File 'lib/decision_agent/dmn/model.rb', line 127 def label @label end |
#type_ref ⇒ Object (readonly)
Returns the value of attribute type_ref.
127 128 129 |
# File 'lib/decision_agent/dmn/model.rb', line 127 def type_ref @type_ref end |
Instance Method Details
#freeze ⇒ Object
136 137 138 139 140 141 142 |
# File 'lib/decision_agent/dmn/model.rb', line 136 def freeze @id.freeze @label.freeze @expression.freeze @type_ref.freeze super end |