RiTa
index
Name RiTextBehavior
Description An abstract superclass for an extensible set of text-behaviors (found in rita.support.behaviors) including a variety of interpolation algorithms for moving, fading, scaling, color-change, etc.

Included in the rita.* package primarily to document callbacks as follows:

    public void onRiTaEvent(RiTaEvent re)
    {
      // do something with the RiText whose behavior has finished
      RiText parent = (RiText)re.getSource();  
      ...
      
      // do something with the Behavior directly
      RiTextBehavior rtb = (RiTextBehavior)re.getData();     
      ...
      
    }
Constructors
RiTextBehavior(riText, duration);
RiTextBehavior(riText);
RiTextBehavior(riText, timerName, duration);
RiTextBehavior(riText, startOffsetInSec, durationInSeconds);
Methods
checkForCompletion()   Checks for completion, and if so, fires the callback

delete()   Optional method for subclasses needing to clean-up/release resources
(Note: implementations should generally call super.delete())

finish()  

getDuration()   Returns the total duration for the behavior

getId()   Returns the unique Id for this behavior

getName()   Returns the user-assigned name for this behavior; Will return the class name if not set by the user.

getParent()   Returns the RiText object in which this behavior is operating.

getStartOffset()   Returns the original startOffset for the behavior

getType()   Returns the type for the behavior

getValue()  

isCompleted()   Returns whether this behavior has completed

isPaused()   Returns the paused status for the behavior

isRepeating()   Returns whether the behavior will repeat (indefinately) when finished

isReusable()  

isRunning()   Returns the paused status for the behavior

isWaiting()  

pause()   Pauses the behavior for 'pauseTime' seconds

reset()   Causes the behavior to be (immediately) repeated with its initial params and the specified 'duration'

Note: ignores startOffset and restarts immediately.

setId()  

setName()   Sets a (user-assigned) name for this behavior.

setPaused()   Sets the paused status for the behavior

setRepeating()   Sets whether the behavior should repeat (indefinately) when finished

setReusable()  

stop()  

toString()  

update()   Required method for all subclasses

RiTextBehavior.disposeAll()   Calls delete() on all existing behaviors

RiTextBehavior.findById()  

RiTextBehavior.findByName()  

RiTextBehavior.findByType()  

RiTextBehavior.getBehaviorById()   Returns the behavior corresponding to the specified 'id'.

RiTextBehavior.pauseAll()   Pauses/un-pauses all existing behaviors

Usage Web & Application