Class: Stateful::Transition

Inherits:
Object
  • Object
show all
Defined in:
lib/Stateful/Transition.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(event_name, next_state_name) ⇒ Transition

Returns a new instance of Transition.



10
11
12
# File 'lib/Stateful/Transition.rb', line 10

def initialize(event_name, next_state_name)
  @event_name, @next_state_name = event_name, next_state_name
end

Instance Attribute Details

#event_nameObject (readonly)

Returns the value of attribute event_name.



7
8
9
# File 'lib/Stateful/Transition.rb', line 7

def event_name
  @event_name
end

#next_state_nameObject (readonly)

Returns the value of attribute next_state_name.



8
9
10
# File 'lib/Stateful/Transition.rb', line 8

def next_state_name
  @next_state_name
end