Package ptolemy.domains.metroII.kernel
Class NonBlockingFire
- java.lang.Object
-
- ptolemy.domains.metroII.kernel.FireMachine
-
- ptolemy.domains.metroII.kernel.NonBlockingFire
-
- All Implemented Interfaces:
StartOrResumable
public class NonBlockingFire extends FireMachine
NonBlockingFire is a wrapper for Ptolemy actor. It provides an implementation of FireMachine. More specifically, the wrapper implements a startOrResume() function that associates the state of FireMachine with the state of fire() of the wrapped actor as follows:- START: initial state
- FINAL: final state
- Since:
- Ptolemy II 11.0
- Version:
- $Id$
- Author:
- Liangpeng Guo
- Pt.AcceptedRating:
- Red (glp)
- Pt.ProposedRating:
- Red (glp)
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class ptolemy.domains.metroII.kernel.FireMachine
FireMachine.State
-
-
Constructor Summary
Constructors Constructor Description NonBlockingFire(Actor actor)
Constructs a NonBlockingfire by wrapping the actor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
startOrResume(java.util.LinkedList<metroIIcomm.Event.Builder> metroIIEventList)
if the current state is START, call fire() of the wrapped actor, and transition to FINAL.-
Methods inherited from class ptolemy.domains.metroII.kernel.FireMachine
actor, getState, getStateEvent, proposeStateEvent, reset, setState, wrapup
-
-
-
-
Constructor Detail
-
NonBlockingFire
public NonBlockingFire(Actor actor)
Constructs a NonBlockingfire by wrapping the actor.- Parameters:
actor
- actor to be wrapped.
-
-
Method Detail
-
startOrResume
public void startOrResume(java.util.LinkedList<metroIIcomm.Event.Builder> metroIIEventList) throws IllegalActionException
if the current state is START, call fire() of the wrapped actor, and transition to FINAL.- Parameters:
metroIIEventList
- the list of MetroII events that trigger startOrResume().- Throws:
IllegalActionException
- if the associated action (e.g. firing) is not permitted.
-
-