player
Class JALoadingPlayer

java.lang.Object
  extended by player.JAFramesPlayer
      extended by player.JALoadingPlayer
All Implemented Interfaces:
AvatarEventHandler

public class JALoadingPlayer
extends JAFramesPlayer

A JALoadingPlayer is a JAFramesPlayer equipped with the ability to load an animation sequence for a given SiGML or CAS source (URL or string), and then to play that sequence.


Field Summary
 
Fields inherited from class player.JAFramesPlayer
SZ_CAM_DATA
 
Constructor Summary
JALoadingPlayer(JAOptions jopts, JACanvasEmbedder embedder)
          Constructs a new JA Loading Player using the given options and avatar-canvas embedder, with no avatar-event handler nor speed control, and with the player's cyclic-play and single-sign flags both intitially false.
JALoadingPlayer(JAOptions jopts, JACanvasEmbedder embedder, AvatarEventHandler aehdlr)
          Constructs a JA Loading Player using the given options, avatar-canvas embedder, and avatar-event handler, with no speed control, and with the player's cyclic-play and single-sign flags both intitially false.
JALoadingPlayer(JAOptions jopts, JACanvasEmbedder embedder, AvatarEventHandler aehdlr, SpeedProvider sp)
          Constructs a JALoadingPlayer using the given options, avatar-canvas embedder, avatar-event handler, and speed control, and with the player's cyclic-play and single-sign flags both intitially false.
JALoadingPlayer(JAOptions jopts, JACanvasEmbedder embedder, AvatarEventHandler aehdlr, SpeedProvider sp, boolean cyclic, boolean onesign)
          Constructs a JALoadingPlayer using the given options, avatar-canvas embedder, avatar-event handler, speed control, and initial cyclic-play and single-sign flag settings.
 
Method Summary
 void completePlayerSetUp(java.lang.String avatar)
          Creates this player's animation loader, and requests the loading of the given avatar into our view.
 void completePlayerSetUp(java.lang.String avatar, java.lang.String nonstddef)
          Completes the player set up by requesting the loading of the given avatar into the player's view, using the given special avatar definition URL, if non-null; this task could naturally be performed in the player's constructor, but in the interests of GUI responsiveness it is factored out into this separate initialisation method.
 void playCAS(CASFrame[] frames, JALoadingPlayerEventHandler lpeh)
          Plays the animation defined the given CAS frames sequence, using the given player-event handler for notifications to the caller.
 void playSiGML(java.lang.String sigml, JALoadingPlayerEventHandler lpeh)
          Plays the animation generated from the given SiGML string, using the given player-event handler for notifications to the caller.
 void playSiGMLURL(java.net.URL url, JALoadingPlayerEventHandler lpeh)
          Plays the animation generated from the given SiGML URL, using the given player-event handler for notifications to the caller.
 void replay(JALoadingPlayerEventHandler lpeh)
          Replays this player's current animation, which is assumed to exist as a result of a previous call to one of the play...() methods.
 
Methods inherited from class player.JAFramesPlayer
avatarIsLoaded, avatarIsUnloaded, awaitPlayerInactive, clearAnimation, countFrames, countSigns, createStandardCameraChangeMonitor, currentSign, cyclicPlayIsOn, getAnimation, getCameraChangeMonitor, getCameraSettings, hasAnimationData, makeSignStatusRecord, playerIsActive, requestSwitchAvatar, requestSwitchAvatar, setAnimation, setCamera, setCyclicPlay, setSingleSignPlay, showFrame, showFrame, singleSignPlayIsOn, startPlayer, startPlayer, stopPlayer, terminate
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JALoadingPlayer

public JALoadingPlayer(JAOptions jopts,
                       JACanvasEmbedder embedder)
Constructs a new JA Loading Player using the given options and avatar-canvas embedder, with no avatar-event handler nor speed control, and with the player's cyclic-play and single-sign flags both intitially false.


JALoadingPlayer

public JALoadingPlayer(JAOptions jopts,
                       JACanvasEmbedder embedder,
                       AvatarEventHandler aehdlr)
Constructs a JA Loading Player using the given options, avatar-canvas embedder, and avatar-event handler, with no speed control, and with the player's cyclic-play and single-sign flags both intitially false.


JALoadingPlayer

public JALoadingPlayer(JAOptions jopts,
                       JACanvasEmbedder embedder,
                       AvatarEventHandler aehdlr,
                       SpeedProvider sp)
Constructs a JALoadingPlayer using the given options, avatar-canvas embedder, avatar-event handler, and speed control, and with the player's cyclic-play and single-sign flags both intitially false.


JALoadingPlayer

public JALoadingPlayer(JAOptions jopts,
                       JACanvasEmbedder embedder,
                       AvatarEventHandler aehdlr,
                       SpeedProvider sp,
                       boolean cyclic,
                       boolean onesign)
Constructs a JALoadingPlayer using the given options, avatar-canvas embedder, avatar-event handler, speed control, and initial cyclic-play and single-sign flag settings.

Method Detail

completePlayerSetUp

public void completePlayerSetUp(java.lang.String avatar)
Creates this player's animation loader, and requests the loading of the given avatar into our view.


completePlayerSetUp

public void completePlayerSetUp(java.lang.String avatar,
                                java.lang.String nonstddef)
Completes the player set up by requesting the loading of the given avatar into the player's view, using the given special avatar definition URL, if non-null; this task could naturally be performed in the player's constructor, but in the interests of GUI responsiveness it is factored out into this separate initialisation method.


playSiGMLURL

public void playSiGMLURL(java.net.URL url,
                         JALoadingPlayerEventHandler lpeh)
                  throws java.lang.InterruptedException
Plays the animation generated from the given SiGML URL, using the given player-event handler for notifications to the caller.

Throws:
java.lang.InterruptedException

playSiGML

public void playSiGML(java.lang.String sigml,
                      JALoadingPlayerEventHandler lpeh)
               throws java.lang.InterruptedException
Plays the animation generated from the given SiGML string, using the given player-event handler for notifications to the caller.

Throws:
java.lang.InterruptedException

playCAS

public void playCAS(CASFrame[] frames,
                    JALoadingPlayerEventHandler lpeh)
Plays the animation defined the given CAS frames sequence, using the given player-event handler for notifications to the caller.


replay

public void replay(JALoadingPlayerEventHandler lpeh)
Replays this player's current animation, which is assumed to exist as a result of a previous call to one of the play...() methods.