vendor/plugins/acts_as_state_machine/lib/acts_as_state_machine.rb
def acts_as_state_machine(opts)
          self.extend(ClassMethods)
          raise NoInitialState unless opts[:initial]
          
          write_inheritable_attribute :states, {}
          write_inheritable_attribute :initial_state, opts[:initial]
          write_inheritable_attribute :transition_table, {}
          write_inheritable_attribute :state_column, opts[:column] || 'state'
          
          class_inheritable_reader    :initial_state
          class_inheritable_reader    :state_column
          class_inheritable_reader    :transition_table
          
          class_eval "include RailsStudio::Acts::StateMachine::InstanceMethods"
          class_eval "def initialize(args={});super;set_initial_state;end"

          before_create               :set_initial_state
        end
# Configuration options are
#
# * +column+ - specifies the column name to use for keeping the state (default: state)
# * +initial+ - specifies an initial state for newly created objects (required)
Configuration options are
+column+ - specifies the column name to use for keeping the state (default: state)
+initial+ - specifies an initial state for newly created objects (required)
Configuration options are + column + - specifies the column name to use for keeping the state ( default : state ) + initial + - specifies an initial state for newly created objects ( required )
def acts_as_state_machine(opts)
          self.extend(ClassMethods)
          raise NoInitialState unless opts[:initial]
          write_inheritable_attribute :states, {}
          write_inheritable_attribute :initial_state, opts[:initial]
          write_inheritable_attribute :transition_table, {}
          write_inheritable_attribute :state_column, opts[:column] || 'state'
          class_inheritable_reader    :initial_state
          class_inheritable_reader    :state_column
          class_inheritable_reader    :transition_table
          class_eval "include RailsStudio::Acts::StateMachine::InstanceMethods"
          class_eval "def initialize(args={});super;set_initial_state;end"
          before_create               :set_initial_state
        end
def acts_as_state_machine ( opts ) self . extend ( ClassMethods ) raise NoInitialState unless opts [ :initial ] write_inheritable_attribute :states , { } write_inheritable_attribute :initial_state , opts [ :initial ] write_inheritable_attribute :transition_table , { } write_inheritable_attribute :state_column , opts [ :column ] || 'state' class_inheritable_reader :initial_state class_inheritable_reader :state_column class_inheritable_reader :transition_table class_eval "include RailsStudio::Acts::StateMachine::InstanceMethods" class_eval "def initialize(args={});super;set_initial_state;end" before_create :set_initial_state end
Configuration options are
 +column+ - specifies the column name to use for keeping the state (default: state)
 +initial+ - specifies an initial state for newly created objects (required)
Configuration options are + column + - specifies the column name to use for keeping the state ( default : state ) + initial + - specifies an initial state for newly created objects ( required )
opts