org.jfree.xml.parser.coretypes

Class GradientPaintReadHandler

Implemented Interfaces:
XmlReadHandler

public class GradientPaintReadHandler
extends AbstractXmlReadHandler

A SAX handler for reading a GradientPaint from an XML element.

Constructor Summary

GradientPaintReadHandler()
Creates a new handler.

Method Summary

protected void
doneParsing()
At the end of parsing the element, the gradient paint is constructed.
protected XmlReadHandler
getHandlerForChild(String tagName, Attributes atts)
Returns the handler for a child element.
Object
getObject()
Returns the gradient paint under construction.

Methods inherited from class org.jfree.xml.parser.AbstractXmlReadHandler

characters, doneParsing, endElement, getHandlerForChild, getRootHandler, getTagName, init, startElement, startParsing

Constructor Details

GradientPaintReadHandler

public GradientPaintReadHandler()
Creates a new handler.

Method Details

doneParsing

protected void doneParsing()
            throws XmlReaderException
At the end of parsing the element, the gradient paint is constructed.
Overrides:
doneParsing in interface AbstractXmlReadHandler
Throws:
XmlReaderException - if there is a parsing error.

getHandlerForChild

protected XmlReadHandler getHandlerForChild(String tagName,
                                            Attributes atts)
            throws SAXException,
                   XmlReaderException
Returns the handler for a child element.
Overrides:
getHandlerForChild in interface AbstractXmlReadHandler
Parameters:
tagName - the tag name.
atts - the attributes.
Returns:
the handler.
Throws:
XmlReaderException - if there is a reader error.

getObject

public Object getObject()
Returns the gradient paint under construction.
Specified by:
getObject in interface XmlReadHandler
Returns:
the gradient paint.