| java.lang.Object com.sun.perseus.model.StringRefValues
StringRefValues | public class StringRefValues implements RefValues(Code) | | version: $Id: StringRefValues.java,v 1.2 2006/04/21 06:38:51 st125089 Exp $ |
Method Summary | |
public Object[] | compute(int si, float p) Computes the value for the input interpolated values. | public int | getComponents() StringRefValues only have one component. | public float | getLength() Computes the length of the RefValues. | public float | getLength(int si) Computes the length of segment at index si. | public Segment | getSegment(int i) Parameters: i - requested segment index. | public int | getSegments() | public void | initialize() Should be called after the RefValue's configuration is complete
to give the implementation a chance to initialize
internal data and cache values. | public void | makeDiscrete() Adds a new time segment so accomodate for discreet behavior.
If there is only one segment for discreet animations, the
last value is never shown. | public String | toString() Debug helper. |
length | float[] length(Code) | | Used to store the length of this RefValues
|
compute | public Object[] compute(int si, float p)(Code) | | Computes the value for the input interpolated values.
There should be as many entries in the return array as there
are components in the RefValues.
Parameters: si - the current segment index Parameters: p - the current penetration Parameters: the - interpolated value. |
getComponents | public int getComponents()(Code) | | StringRefValues only have one component.
the number of string components |
getLength | public float getLength()(Code) | | Computes the length of the RefValues. This is meant for paced timing
computation.
the length between the various ref values. For strings, we consider that each segment is of length 1, so this simply returns the number of segments. |
getLength | public float getLength(int si)(Code) | | Computes the length of segment at index si.
Parameters: si - the segment index. |
getSegment | public Segment getSegment(int i)(Code) | | Parameters: i - requested segment index. Segment at index i |
getSegments | public int getSegments()(Code) | | the number of segments in refValues |
initialize | public void initialize()(Code) | | Should be called after the RefValue's configuration is complete
to give the implementation a chance to initialize
internal data and cache values.
|
makeDiscrete | public void makeDiscrete()(Code) | | Adds a new time segment so accomodate for discreet behavior.
If there is only one segment for discreet animations, the
last value is never shown. To accomodate for that, this
method should add a segment to the RefValues so that the
last animation value is shown during the last value interval
of a discreet animation.
|
|
|