Class: Resyma::Core::State
- Inherits:
-
Object
- Object
- Resyma::Core::State
- Defined in:
- lib/resyma/core/automaton/state.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
Class Method Summary collapse
-
.with_id(id) ⇒ Resyma::Core::State
Returns a new State whose ID is ‘id`.
Instance Method Summary collapse
-
#initialize(id) ⇒ State
constructor
A new instance of State.
Constructor Details
#initialize(id) ⇒ State
Returns a new instance of State.
4 5 6 |
# File 'lib/resyma/core/automaton/state.rb', line 4 def initialize(id) @id = id end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
8 9 10 |
# File 'lib/resyma/core/automaton/state.rb', line 8 def id @id end |
Class Method Details
.with_id(id) ⇒ Resyma::Core::State
Returns a new State whose ID is ‘id`
17 18 19 |
# File 'lib/resyma/core/automaton/state.rb', line 17 def self.with_id(id) new(id) end |