Package schema2template.template
Class FileCreationListHandler
- java.lang.Object
-
- org.xml.sax.helpers.DefaultHandler
-
- schema2template.template.FileCreationListHandler
-
- All Implemented Interfaces:
ContentHandler
,DTDHandler
,EntityResolver
,ErrorHandler
public class FileCreationListHandler extends DefaultHandler
If a Velocity template should be used multiple times (e.g. for every element of the schema), For every file to be created we create a line in the file-creation-list. This file-creation-list XML is being created from the main-template. This class parses this list of the output files to be created.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
endElement(String uri, String localName, String qName)
static List<FileCreationListEntry>
readFileListFile(File flf)
void
setDocumentLocator(Locator locator)
With the DocumentLocator line numbers will be received during errorsvoid
startElement(String uri, String localName, String qName, Attributes attributes)
-
Methods inherited from class org.xml.sax.helpers.DefaultHandler
characters, endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning
-
-
-
-
Method Detail
-
setDocumentLocator
public void setDocumentLocator(Locator locator)
With the DocumentLocator line numbers will be received during errors- Specified by:
setDocumentLocator
in interfaceContentHandler
- Overrides:
setDocumentLocator
in classDefaultHandler
-
startElement
public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException
- Specified by:
startElement
in interfaceContentHandler
- Overrides:
startElement
in classDefaultHandler
- Throws:
SAXException
-
endElement
public void endElement(String uri, String localName, String qName) throws SAXException
- Specified by:
endElement
in interfaceContentHandler
- Overrides:
endElement
in classDefaultHandler
- Throws:
SAXException
-
readFileListFile
public static List<FileCreationListEntry> readFileListFile(File flf) throws ParserConfigurationException, SAXException, IOException
-
-