org.apache.batik.bridge
public abstract class SVGAnimationElementBridge extends AbstractSVGBridge implements GenericBridge, BridgeUpdateHandler, SVGAnimationContext, AnimatableElement
| Nested Class Summary | |
|---|---|
| protected class | SVGAnimationElementBridge.SVGTimedElement
A TimedElement class for SVG animation elements. |
| Field Summary | |
|---|---|
| protected AbstractAnimation | animation
The animation object that provides the values for the animation. |
| protected AnimationTarget | animationTarget
The AnimationTarget the provides a context to the animation engine. |
| protected short | animationType
The animation type. |
| protected String | attributeLocalName
The local name of the attribute or the name of the property being
animated. |
| protected String | attributeNamespaceURI
The namespace URI of the attribute being animated. |
| protected BridgeContext | ctx
The BridgeContext to be used. |
| protected SVGOMElement | element
The animation element. |
| protected SVGAnimationEngine | eng
The AnimationEngine that manages all of the animations in the document. |
| protected SVGOMElement | targetElement
The target element of the animation. |
| protected TimedElement | timedElement
The TimedElement object that provides the timing for the animation. |
| Method Summary | |
|---|---|
| void | addTargetListener(String pn, AnimationTargetListener l)
Adds a listener for changes to the given attribute value. |
| boolean | beginElement()
DOM: Implements org.w3c.dom.smil.ElementTimeControl#beginElement(). |
| boolean | beginElementAt(float offset)
DOM: Implements org.w3c.dom.smil.ElementTimeControl#beginElementAt(float). |
| protected abstract boolean | canAnimateType(int type)
Returns whether the animation element being handled by this bridge can
animate attributes of the specified type. |
| protected boolean | checkValueType(AnimatableValue v)
Returns whether the specified AnimatableValue is of a type allowed
by this animation. |
| protected abstract AbstractAnimation | createAnimation(AnimationTarget t)
Creates the animation object for the animation element. |
| protected TimedElement | createTimedElement()
Creates a TimedElement for the animation element. |
| void | dispose()
Disposes this BridgeUpdateHandler and releases all resources. |
| boolean | endElement()
DOM: Implements org.w3c.dom.smil.ElementTimeControl#endElement(). |
| boolean | endElementAt(float offset)
DOM: Implements org.w3c.dom.smil.ElementTimeControl#endElementAt(float). |
| Rectangle2D | getBBox() |
| AffineTransform | getCTM() |
| float | getCurrentTime()
DOM: Implements org.w3c.dom.svg.SVGAnimationElement#getCurrentTime(). |
| float | getFontSize() |
| AffineTransform | getGlobalTransform() |
| float | getHyperlinkBeginTime()
Returns the time that the document would seek to if this animation
element were hyperlinked to, or NaN if there is no
such begin time. |
| float | getPixelToMM()
Returns the size of a px CSS unit in millimeters.
|
| float | getPixelUnitToMillimeter()
Returns the size of a px CSS unit in millimeters. |
| AffineTransform | getScreenTransform() |
| float | getSimpleDuration()
DOM: Implements org.w3c.dom.svg.SVGAnimationElement#getSimpleDuration(). |
| float | getStartTime()
DOM: Implements org.w3c.dom.svg.SVGAnimationElement#getStartTime(). |
| SVGElement | getTargetElement()
DOM: Implements org.w3c.dom.svg.SVGAnimationElement#getTargetElement(). |
| TimedElement | getTimedElement()
Returns the TimedElement for the animation. |
| AnimatableValue | getUnderlyingValue()
Returns the underlying value of the animated attribute. |
| float | getViewportHeight() |
| float | getViewportWidth() |
| void | handleAnimatedAttributeChanged(AnimatedLiveAttributeValue alav)
Invoked when the animated value of an animatable attribute has changed. |
| void | handleCSSEngineEvent(CSSEngineEvent evt)
Invoked when an CSSEngineEvent is fired. |
| void | handleDOMAttrModifiedEvent(MutationEvent evt)
Invoked when an MutationEvent of type 'DOMAttrModified' is fired. |
| void | handleDOMCharacterDataModified(MutationEvent evt)
Invoked when an MutationEvent of type 'DOMCharacterDataModified'
is fired. |
| void | handleDOMNodeInsertedEvent(MutationEvent evt)
Invoked when an MutationEvent of type 'DOMNodeInserted' is fired. |
| void | handleDOMNodeRemovedEvent(MutationEvent evt)
Invoked when an MutationEvent of type 'DOMNodeRemoved' is fired. |
| void | handleElement(BridgeContext ctx, Element e)
Handles this animation element.
|
| void | handleOtherAnimationChanged(String type)
Invoked when an 'other' animation value has changed. |
| protected void | initializeAnimation()
Parses the animation element's target attributes and adds it to the
document's AnimationEngine. |
| protected void | initializeTimedElement()
Parses the animation element's timing attributes and initializes the
TimedElement object. |
| protected void | initializeTimedElement(TimedElement timedElement)
Initializes the timing attributes of the timed element. |
| protected boolean | isConstantAnimation()
Returns whether this is a constant animation (i.e., a 'set' animation). |
| protected AnimatableValue | parseAnimatableValue(String an)
Parses an attribute as an AnimatableValue. |
| void | removeTargetListener(String pn, AnimationTargetListener l)
Removes a listener for changes to the given attribute value. |
| void | setScreenTransform(AffineTransform at) |
| float | svgToUserSpace(float v, int type, int pcInterp) |
ANIM_TYPE_*
constants defined in AnimationEngine.Parameters: type one of the TYPE_ constants defined in SVGTypes.
NaN if there is no
such begin time.See Also: getPixelUnitToMillimeter
Parameters: ctx the bridge context to use e the element being handled