Class ImportControlLoader
- java.lang.Object
-
- org.xml.sax.helpers.DefaultHandler
-
- com.puppycrawl.tools.checkstyle.XmlLoader
-
- com.puppycrawl.tools.checkstyle.checks.imports.ImportControlLoader
-
- All Implemented Interfaces:
org.xml.sax.ContentHandler
,org.xml.sax.DTDHandler
,org.xml.sax.EntityResolver
,org.xml.sax.ErrorHandler
public final class ImportControlLoader extends XmlLoader
Responsible for loading the contents of an import control configuration file.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.puppycrawl.tools.checkstyle.XmlLoader
XmlLoader.LoadExternalDtdFeatureProvider
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
endElement(java.lang.String namespaceUri, java.lang.String localName, java.lang.String qName)
static com.puppycrawl.tools.checkstyle.checks.imports.PkgImportControl
load(java.net.URI uri)
Loads the import control file from a file.void
startElement(java.lang.String namespaceUri, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes attributes)
-
Methods inherited from class com.puppycrawl.tools.checkstyle.XmlLoader
error, parseInputSource, resolveEntity
-
-
-
-
Method Detail
-
startElement
public void startElement(java.lang.String namespaceUri, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes attributes) throws org.xml.sax.SAXException
- Specified by:
startElement
in interfaceorg.xml.sax.ContentHandler
- Overrides:
startElement
in classorg.xml.sax.helpers.DefaultHandler
- Throws:
org.xml.sax.SAXException
-
endElement
public void endElement(java.lang.String namespaceUri, java.lang.String localName, java.lang.String qName)
- Specified by:
endElement
in interfaceorg.xml.sax.ContentHandler
- Overrides:
endElement
in classorg.xml.sax.helpers.DefaultHandler
-
load
public static com.puppycrawl.tools.checkstyle.checks.imports.PkgImportControl load(java.net.URI uri) throws CheckstyleException
Loads the import control file from a file.- Parameters:
uri
- the uri of the file to load.- Returns:
- the root
PkgImportControl
object. - Throws:
CheckstyleException
- if an error occurs.
-
-