Class SequenceStateMachine

All Implemented Interfaces:
Application, OnDemandValueProcessor.ValueProvider

public class SequenceStateMachine extends StateMachine
This State Machine delegated too sequence of state machines..
Author:
igor@scictrl.com
  • Constructor Details

    • SequenceStateMachine

      public SequenceStateMachine()

      Constructor for SequenceStateMachine.

  • Method Details

    • newApplication

      public static final SequenceStateMachine newApplication(String name, double timeout, String[] names)

      newApplication.

      Parameters:
      name - a String object
      timeout - a double
      names - an array of String objects
      Returns:
      a SequenceStateMachine object
    • configure

      public void configure(String name, org.apache.commons.configuration.HierarchicalConfiguration config)
      Configures the internals of this application, provides reference to configuration with root inside applications tag. Server structure is not yet initialized, so does not have reference to Database, the Database reference will be available during activate call.
      Specified by:
      configure in interface Application
      Overrides:
      configure in class StateMachine
      Parameters:
      name - a String object
      config - configuration with room inside application tag.
    • activate

      public void activate()
      Application has now reference to Database. Application might want to connect to other records on this server or PVs on other servers. This can not be done until all records from configuration has been loaded. Call to this method signals application that records has been loaded and linking to other values can be commenced.
      Specified by:
      activate in interface Application
      Overrides:
      activate in class StateMachine
    • updateProgress

      public void updateProgress()

      updateProgress.

    • updateState

      public void updateState()

      updateState.

    • stateMachinePrepare

      public void stateMachinePrepare()

      stateMachinePrepare.

      Overrides:
      stateMachinePrepare in class StateMachine
    • stateMachineActivate

      public void stateMachineActivate(boolean dryrun)

      Activates state machine. If this state machine is in dry-run mode or dry-run parameter with true is called, then this step is activate in dry-run mode.

      Overrides:
      stateMachineActivate in class StateMachine
      Parameters:
      dryrun - dry-run mode request
    • stateMachineAbort

      public void stateMachineAbort()

      stateMachineAbort.

      Overrides:
      stateMachineAbort in class StateMachine
    • setState

      public void setState(StateMachine.State st)

      setState.

      Overrides:
      setState in class StateMachine
      Parameters:
      st - a StateMachine.State object