Use is subject to License Terms. Your use of this web site or any of its content or software indicates your agreement to be bound by these License Terms.

Copyright © 2006 Sun Microsystems, Inc. All rights reserved.

JSR-927 (Maintenance Release)

javax.media
Class TransitionEvent

java.lang.Object
  extended byjava.util.EventObject
      extended byjavax.media.ControllerEvent
          extended byjavax.media.TransitionEvent
All Implemented Interfaces:
MediaEvent, java.io.Serializable
Direct Known Subclasses:
PrefetchCompleteEvent, RealizeCompleteEvent, StartEvent, StopEvent

public class TransitionEvent
extends ControllerEvent

TransitionEvent is a ControllerEvent that indicates that a Controller has changed state.

See Also:
Controller, ControllerListener, Serialized Form

Field Summary
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
TransitionEvent(Controller from, int previous, int current, int target)
          Construct a new TransitionEvent.
 
Method Summary
 int getCurrentState()
          Get the Controller's state at the time this event was generated
 int getPreviousState()
          Get the state that the Controller was in before this event occurred.
 int getTargetState()
          Get the Controller's target state at the time this event was generated.
 
Methods inherited from class javax.media.ControllerEvent
getSource, getSourceController
 
Methods inherited from class java.util.EventObject
toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TransitionEvent

public TransitionEvent(Controller from,
                       int previous,
                       int current,
                       int target)
Construct a new TransitionEvent.

Parameters:
from - The Controller that is generating this event.
previous - The state that the Controller was in before this event.
current - The state that the Controller is in as a result of this event.
target - The state that the Controller is heading to.
Method Detail

getPreviousState

public int getPreviousState()
Get the state that the Controller was in before this event occurred.

Returns:
The Controller's previous state.

getCurrentState

public int getCurrentState()
Get the Controller's state at the time this event was generated

Returns:
The Controller's current state.

getTargetState

public int getTargetState()
Get the Controller's target state at the time this event was generated.

Returns:
The Controller's target state.

JSR-927 (Maintenance Release)

Copyright © 2006 Sun Microsystems, Inc. All rights reserved. Use is subject to License Terms. Your use of this web site or any of its content or software indicates your agreement to be bound by these License Terms.

For more information, please consult the JSR 927 specification.