Sha256: 25ca0f9116a83280b2afcf225c7ce6ae0739ccf1c33095ff64ba6b1e19d1dc91

Contents?: true

Size: 198 Bytes

Versions: 7

Compression:

Stored size: 198 Bytes

Contents

class Switch
  state_machine do
    event :turn_on do
      transition :to => 'on', :from => 'off'
    end
    
    event :turn_off do
      transition :to => 'off', :from => 'on'
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
state_machine-0.4.0 test/classes/switch.rb
state_machine-0.4.3 test/classes/switch.rb
state_machine-0.5.0 test/classes/switch.rb
state_machine-0.4.1 test/classes/switch.rb
state_machine-0.5.2 test/classes/switch.rb
state_machine-0.4.2 test/classes/switch.rb
state_machine-0.5.1 test/classes/switch.rb