org.apache.batik.anim.values

Class AnimatablePreserveAspectRatioValue

public class AnimatablePreserveAspectRatioValue extends AnimatableValue

An SVG preserveAspectRatio value in the animation system.
Field Summary
protected static String[]ALIGN_VALUES
Strings for the 'align' values.
protected shortalign
The align value.
protected shortmeetOrSlice
The meet-or-slice value.
protected static String[]MEET_OR_SLICE_VALUES
Strings for the 'meet-or-slice' values.
Constructor Summary
protected AnimatablePreserveAspectRatioValue(AnimationTarget target)
Creates a new, uninitialized AnimatablePreserveAspectRatioValue.
AnimatablePreserveAspectRatioValue(AnimationTarget target, short align, short meetOrSlice)
Creates a new AnimatablePreserveAspectRatioValue.
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.
shortgetAlign()
Returns the align value.
shortgetMeetOrSlice()
Returns the meet-or-slice value.
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.
StringtoStringRep()
Returns a string representation of this object.

Field Detail

ALIGN_VALUES

protected static final String[] ALIGN_VALUES
Strings for the 'align' values.

align

protected short align
The align value.

meetOrSlice

protected short meetOrSlice
The meet-or-slice value.

MEET_OR_SLICE_VALUES

protected static final String[] MEET_OR_SLICE_VALUES
Strings for the 'meet-or-slice' values.

Constructor Detail

AnimatablePreserveAspectRatioValue

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

AnimatablePreserveAspectRatioValue

public AnimatablePreserveAspectRatioValue(AnimationTarget target, short align, short meetOrSlice)
Creates a new AnimatablePreserveAspectRatioValue.

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.

getAlign

public short getAlign()
Returns the align value.

getMeetOrSlice

public short getMeetOrSlice()
Returns the meet-or-slice value.

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. Preserve aspect ratio values cannot be interpolated.

toStringRep

public String toStringRep()
Returns a string representation of this object.
Copyright B) 2008 Apache Software Foundation. All Rights Reserved.