Method, apparatus, and program for a state machine framework
First Claim
1. A method for creating a software state machine, comprising:
- providing a state machine object in a runtime environment on a computer hardware platform, wherein the state machine object includes an object constructor method; and
providing an initializer object in the runtime environment on the computer hardware platform, wherein the initializer object defines states, actions, and conditions for a software state machine and wherein the object constructor method is configured to create an instance of the initializer object,wherein the state machine object is configured to use the initializer object to create a table object, wherein the initializer object includes a table element array creation method and wherein the state machine object is configured to call the table element array creation method to create the table object using the results of the table element array creation method,wherein the state machine object is configured to create an array of state variables, wherein the initializer object includes a table variable array creation method and wherein the state machine object is configured to call the table variable array creation method to create the array of state variables using the results of the table variable array creation method,wherein the table object is configured to create an array of state transition objects based on the array of state variables and return the array of state transition objects to the state machine object, andwherein the state machine object is configured to execute the software state machine using the array of state transition objects.
1 Assignment
0 Petitions
Accused Products
Abstract
A programming framework is provided for designing and implementing software state machines. A state machine initializer may be created that defines the states, conditions, actions, triggers, and state transitions for the software state machines. A set of user interfaces, such as graphical user interfaces, may also be provided for creating initializers. An abstract state machine object may then be created that creates an instance of a particular state machine initializer. The state machine initializer acts as a helper to the state machine object, which uses the initializer to create an array of state transition objects. Once the state machine objects creates the array of state transition objects, the state machine is ready to run. A set of programming interfaces may also be provided to define the programming framework.
90 Citations
9 Claims
-
1. A method for creating a software state machine, comprising:
-
providing a state machine object in a runtime environment on a computer hardware platform, wherein the state machine object includes an object constructor method; and providing an initializer object in the runtime environment on the computer hardware platform, wherein the initializer object defines states, actions, and conditions for a software state machine and wherein the object constructor method is configured to create an instance of the initializer object, wherein the state machine object is configured to use the initializer object to create a table object, wherein the initializer object includes a table element array creation method and wherein the state machine object is configured to call the table element array creation method to create the table object using the results of the table element array creation method, wherein the state machine object is configured to create an array of state variables, wherein the initializer object includes a table variable array creation method and wherein the state machine object is configured to call the table variable array creation method to create the array of state variables using the results of the table variable array creation method, wherein the table object is configured to create an array of state transition objects based on the array of state variables and return the array of state transition objects to the state machine object, and wherein the state machine object is configured to execute the software state machine using the array of state transition objects. - View Dependent Claims (2, 3)
-
-
4. A method for creating software state machines, comprising:
-
providing a state machine object in a runtime environment on a computer hardware platform; receiving, using a set of graphical user interfaces in the runtime environment on the computer hardware platform, entry of a plurality of states, one or more actions, one or more inputs, one or more conditions, one or more events, one or more triggers, and a plurality of state transitions for a software state machine; creating an initializer object in the runtime environment on the computer hardware platform, wherein the initializer object define the plurality of state, the one or more actions, the one or more inputs, ths one or more conditions, the one or more events, the one or more triggers, and the plurality of state transition for the software state machine; configuring the state machine object in, the runtime environment on the computer hardware platform to use the initializer object to create an array of state transition objects based on the plurality of state transitions, wherein each state transition object in the array of state transition objects references at least one of the one or more conditions that causes a given state transition in the software state machine, and wherein each condition is a Boolean expression formed from at least one of the one or more inputs; and responsive to occurrence of a trigger, evaluating the one or more inputs, computing the one or more conditions, and determining a next state based on the array of state transition objects, wherein a first state transition object in the array of state transition objects defines an action to take responsive to a given state transition, and wherein a second state transition object in the array of state transition objects defines an event to be generated responsive to a given state transition.
-
-
5. An apparatus for creating a software state machine, comprising:
-
a processor; and a memory having stored therein a state machine object and an initializer object, wherein the state machine object includes an object constructor method, wherein the initializer object defines states, actions, and conditions for a state machine, wherein the object constructor method is configured to create an instance of the initializer object, wherein the state machine object is configured to use the initializer object to create a table object, wherein the initializer object includes a table element array creation method and wherein the state machine object is configured to call the table element array creation method to create the table object using the results of the table element array creation method, wherein the state machine abject is configured to create an array of state variables, wherein the initializer object includes a table variable array creation method and wherein the state machine object is configured to call the table variable array creation method to create the array of state variables using the results of the variable array creation method, wherein the table object is configured to create an may of state transition objects based on the array of state variables and return the may of state transition objects to the state machine object, and wherein the state machine object is configured to execute the software state machine using the array of state transition objects. - View Dependent Claims (6, 7)
-
-
8. A computer program product, in a tangible computer readable medium, for creating a software state machine, comprising:
-
instructions for providing a state machine object, wherein the state machine object includes an object constructor method; and instructions for providing an initializer object, wherein the initializer object defines states, actions, and conditions for a software state machine, wherein the object constructor method is configured to create an instance of the initializer object, wherein the state machine object is configured to use the initializer object to create a table object, wherein the initializer object includes a table element array creation method and wherein the state machine object is configured to call the table element array creation method to create the table object using the results of the table element array creation method, wherein the table object is configured to create and array of state variables, wherein the initializer object includes a table variable array creation method and wherein the state machine object is configured to call the table variable array creation method to create the array of state variables using the results of the variable array creation method, wherein the table object is configured to create an array of state transition objects based on the array of state variables and return the array of state transition objects to the state machine object, wherein the state machine object is configured to receive the array of state transition objects and execute the software state machine using the array of state transition objects.
-
-
9. A computer program product, in a tangible computer readable medium, for creating software state machines, comprising:
-
instructions for providing a state machine object; instructions for receiving, using a set of graphical user interfaces, entry of a plurality of states, one or more actions, one or more inputs, one or more conditions, one or more events, one or more triggers, and a plurality of states transitions for a software state machine; instructions for creating an initializer object, wherein the initializer object defines the plurality of states, the one or more actions, the one or more inputs, the one or more conditions, the one or more events, the one or more triggers, and the plurality of state transitions for the software state machine; configuring the state machine object to use the initializer object to create an array of state transition object based on the plurality of state transitions, wherein each state transition object in the array of state transition objects references at least one of the one or more conditions that causes a given state transition in the software state machine, and wherein each condition is a Boolean expression formed from at least one of the one or more inputs; and instructions, responsive to occurrence of a trigger, for evaluating the one or more inputs, computing the one or more conditions, and determining a next state based on the array of state transition objects, wherein a first state transition object in the array of state transition objects defines an action to take responsive to a given state transition, and wherein a second state transition object in the array of state transition objects defines an event to be generated responsive to a given state transition.
-
Specification