Class | StateMachine::PathCollection |
In: |
lib/state_machine/path_collection.rb
|
Parent: | Array |
Represents a collection of paths that are generated based on a set of requirements regarding what states to start and end on
from_name | [R] | The initial state to start each path from |
machine | [R] | The state machine these path are walking |
object | [R] | The object whose state machine is being walked |
to_name | [R] | The target state for each path |
Creates a new collection of paths with the given requirements.
Configuration options:
Lists all of the events that can be fired through the paths in this collection.
For example,
paths.events # => [:park, :ignite, :shift_up, ...]
Lists all of the states that can be transitioned from through the paths in this collection.
For example,
paths.from_states # => [:parked, :idling, :first_gear, ...]