Class: StateMachineBuilder Abstract

Inherits:
Object
  • Object
show all
Defined in:
state_machine_builder.rb

Overview

This class is abstract.
  • subclass and implement #build and #reset, ensuring that BuildException and ResetException are raised when building or resetting is exceptional.

A wrapper around a StateMachine.

Direct Known Subclasses

ParserBuilder

Defined Under Namespace

Classes: BuildException, ResetException

Instance Method Summary collapse

Instance Method Details

#buildStateMachine

Returns an instance of StateMachine which includes a custom implementation

Returns:

Raises:


19
20
21
# File 'state_machine_builder.rb', line 19

def build
  raise BuildException
end

#resetnil

Resets the state machine

Returns:

  • (nil)

Raises:


26
27
28
# File 'state_machine_builder.rb', line 26

def reset
  raise ResetException
end