com.puppycrawl.tools.checkstyle.api

Class AbstractLoader

public abstract class AbstractLoader extends DefaultHandler

Contains the common implementation of a loader, for loading a configuration from an XML file.

The error handling policy can be described as being austere, dead set, disciplinary, dour, draconian, exacting, firm, forbidding, grim, hard, hard- boiled, harsh, harsh, in line, iron-fisted, no-nonsense, oppressive, persnickety, picky, prudish, punctilious, puritanical, rigid, rigorous, scrupulous, set, severe, square, stern, stickler, straight, strait-laced, stringent, stuffy, stuffy, tough, unpermissive, unsparing and uptight.

Author: Oliver Burn

Constructor Summary
protected AbstractLoader(String aPublicId, String aDtdResourceName)
Creates a new instance.
protected AbstractLoader(Map aPublicIdToResourceNameMap)
Creates a new instance.
Method Summary
voiderror(SAXParseException aEx)
{@inheritDoc}
voidfatalError(SAXParseException aEx)
{@inheritDoc}
voidparseInputSource(InputSource aInputSource)
Parses the specified input source.
InputSourceresolveEntity(String aPublicId, String aSystemId)
{@inheritDoc}
voidwarning(SAXParseException aEx)
{@inheritDoc}

Constructor Detail

AbstractLoader

protected AbstractLoader(String aPublicId, String aDtdResourceName)
Creates a new instance.

Parameters: aPublicId the public ID for the DTD to resolve aDtdResourceName the resource for the DTD

Throws: SAXException if an error occurs ParserConfigurationException if an error occurs

AbstractLoader

protected AbstractLoader(Map aPublicIdToResourceNameMap)
Creates a new instance.

Parameters: aPublicIdToResourceNameMap maps public IDs to DTD resource names

Throws: SAXException if an error occurs ParserConfigurationException if an error occurs

Method Detail

error

public void error(SAXParseException aEx)
{@inheritDoc}

fatalError

public void fatalError(SAXParseException aEx)
{@inheritDoc}

parseInputSource

public void parseInputSource(InputSource aInputSource)
Parses the specified input source.

Parameters: aInputSource the input source to parse.

Throws: IOException if an error occurs SAXException in an error occurs

resolveEntity

public InputSource resolveEntity(String aPublicId, String aSystemId)
{@inheritDoc}

warning

public void warning(SAXParseException aEx)
{@inheritDoc}