org.apache.batik.anim.values

Class AnimatableLengthListValue

public class AnimatableLengthListValue extends AnimatableValue

An SVG length list value in the animation system.
Field Summary
protected short[]lengthTypes
The length types.
protected float[]lengthValues
The length values.
protected shortpercentageInterpretation
How to interpret percentage values.
Constructor Summary
protected AnimatableLengthListValue(AnimationTarget target)
Creates a new, uninitialized AnimatableLengthListValue.
AnimatableLengthListValue(AnimationTarget target, short[] types, float[] values, short pcInterp)
Creates a new AnimatableLengthListValue.
Method Summary
booleancanPace()
Returns whether two values of this type can have their distance computed, as needed by paced animation.
floatdistanceTo(AnimatableValue other)
Returns the absolute distance between this value and the specified other value.
StringgetCssText()
Returns the CSS text representation of the value.
short[]getLengthTypes()
Gets the length types.
float[]getLengthValues()
Gets the length values.
AnimatableValuegetZeroValue()
Returns a zero value of this AnimatableValue's type.
AnimatableValueinterpolate(AnimatableValue result, AnimatableValue to, float interpolation, AnimatableValue accumulation, int multiplier)
Performs interpolation to the given value.

Field Detail

lengthTypes

protected short[] lengthTypes
The length types.

lengthValues

protected float[] lengthValues
The length values. These should be one of the constants defined in {@link SVGLength}.

percentageInterpretation

protected short percentageInterpretation
How to interpret percentage values. These should be one of the {@link AnimationTarget}.PERCENTAGE_* constants.

Constructor Detail

AnimatableLengthListValue

protected AnimatableLengthListValue(AnimationTarget target)
Creates a new, uninitialized AnimatableLengthListValue.

AnimatableLengthListValue

public AnimatableLengthListValue(AnimationTarget target, short[] types, float[] values, short pcInterp)
Creates a new AnimatableLengthListValue.

Method Detail

canPace

public boolean canPace()
Returns whether two values of this type can have their distance computed, as needed by paced animation.

distanceTo

public float distanceTo(AnimatableValue other)
Returns the absolute distance between this value and the specified other value.

getCssText

public String getCssText()
Returns the CSS text representation of the value. Length lists can never be used for CSS properties.

getLengthTypes

public short[] getLengthTypes()
Gets the length types.

getLengthValues

public float[] getLengthValues()
Gets the length values.

getZeroValue

public AnimatableValue getZeroValue()
Returns a zero value of this AnimatableValue's type.

interpolate

public AnimatableValue interpolate(AnimatableValue result, AnimatableValue to, float interpolation, AnimatableValue accumulation, int multiplier)
Performs interpolation to the given value.
Copyright B) 2007 Apache Software Foundation. All Rights Reserved.