| java.lang.Object org.xml.sax.helpers.DefaultHandler jimm.datavision.ParameterReader
ParameterReader | public class ParameterReader extends DefaultHandler (Code) | | A parameter reader reads an XML file and sets a
Report 's parameter
values. This class is used when the report is being run from the
command line and the user has given us the name of an XML file containing
parameter elements.
Unlike a
ReportReader , a parameter reader's constructor
takes not only the report but also the input method (file name, stream,
or reader). That way the report object doesn't have to know how to hold
on to those multipule input types.
author: Jim Menard, jimm@io.com |
Method Summary | |
public void | characters(char ch, int start, int length) Reads text data. | public void | endElement(String namespaceURI, String localName, String qName) | public String | getInputName() Returns the file name or, if that is null , the class name of
whatever input source was handed to a constructor. | public void | read() Reads parameter values from whichever input method was specified
in the constructor. | public void | startElement(String namespaceURI, String localName, String qName, Attributes attributes) |
DEFAULT_DTD_VERSION | final protected static double DEFAULT_DTD_VERSION(Code) | | If there is no report element dtd-version attribute, this is the
default value to use.
|
ParameterReader | public ParameterReader(Report report, File f)(Code) | | Constructor.
Parameters: report - the report whose parameters we are setting Parameters: f - the parameter XML file |
ParameterReader | public ParameterReader(Report report, InputSource in)(Code) | | Constructor. To specify a URL, use new
InputSource("http://...") .
Parameters: report - the report whose parameters we are setting Parameters: in - the param XML input source |
characters | public void characters(char ch, int start, int length)(Code) | | Reads text data. Text data inside a single tag can be broken up into
multiple calls to this method.
|
getInputName | public String getInputName()(Code) | | Returns the file name or, if that is null , the class name of
whatever input source was handed to a constructor.
a file name or class name |
read | public void read() throws Exception(Code) | | Reads parameter values from whichever input method was specified
in the constructor.
|
Methods inherited from org.xml.sax.helpers.DefaultHandler | public void characters(char ch, int start, int length) throws SAXException(Code)(Java Doc) public void endDocument() throws SAXException(Code)(Java Doc) public void endElement(String uri, String localName, String qName) throws SAXException(Code)(Java Doc) public void endPrefixMapping(String prefix) throws SAXException(Code)(Java Doc) public void error(SAXParseException e) throws SAXException(Code)(Java Doc) public void fatalError(SAXParseException e) throws SAXException(Code)(Java Doc) public void ignorableWhitespace(char ch, int start, int length) throws SAXException(Code)(Java Doc) public void notationDecl(String name, String publicId, String systemId) throws SAXException(Code)(Java Doc) public void processingInstruction(String target, String data) throws SAXException(Code)(Java Doc) public InputSource resolveEntity(String publicId, String systemId) throws IOException, SAXException(Code)(Java Doc) public void setDocumentLocator(Locator locator)(Code)(Java Doc) public void skippedEntity(String name) throws SAXException(Code)(Java Doc) public void startDocument() throws SAXException(Code)(Java Doc) public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException(Code)(Java Doc) public void startPrefixMapping(String prefix, String uri) throws SAXException(Code)(Java Doc) public void unparsedEntityDecl(String name, String publicId, String systemId, String notationName) throws SAXException(Code)(Java Doc) public void warning(SAXParseException e) throws SAXException(Code)(Java Doc)
|
|
|