public abstract class AbstractParser extends DefaultHandler
OsmChangesetContentParser
and OsmHistoryReader
internal parsers.Modifier and Type | Field and Description |
---|---|
protected HistoryOsmPrimitive |
currentPrimitive
the current primitive to be read
|
protected Locator |
locator |
Constructor and Description |
---|
AbstractParser() |
Modifier and Type | Method and Description |
---|---|
protected HistoryOsmPrimitive |
createPrimitive(Attributes atts,
OsmPrimitiveType type) |
protected boolean |
doStartElement(String qName,
Attributes atts) |
protected Double |
getAttributeDouble(Attributes attr,
String name) |
protected Long |
getAttributeLong(Attributes attr,
String name) |
protected boolean |
getMandatoryAttributeBoolean(Attributes attr,
String name) |
protected long |
getMandatoryAttributeLong(Attributes attr,
String name) |
protected String |
getMandatoryAttributeString(Attributes attr,
String name) |
protected void |
handleMember(Attributes atts) |
protected void |
handleNodeReference(Attributes atts) |
protected void |
handleTag(Attributes atts) |
void |
setDocumentLocator(Locator locator) |
protected void |
startNode(Attributes atts) |
protected void |
startRelation(Attributes atts) |
protected void |
startWay(Attributes atts) |
protected abstract void |
throwException(String message) |
characters, endDocument, endElement, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, skippedEntity, startDocument, startElement, startPrefixMapping, unparsedEntityDecl, warning
protected HistoryOsmPrimitive currentPrimitive
public AbstractParser()
public void setDocumentLocator(Locator locator)
setDocumentLocator
in interface ContentHandler
setDocumentLocator
in class DefaultHandler
protected abstract void throwException(String message) throws SAXException
SAXException
protected final long getMandatoryAttributeLong(Attributes attr, String name) throws SAXException
SAXException
protected final Long getAttributeLong(Attributes attr, String name) throws SAXException
SAXException
protected final Double getAttributeDouble(Attributes attr, String name) throws SAXException
SAXException
protected final String getMandatoryAttributeString(Attributes attr, String name) throws SAXException
SAXException
protected boolean getMandatoryAttributeBoolean(Attributes attr, String name) throws SAXException
SAXException
protected final HistoryOsmPrimitive createPrimitive(Attributes atts, OsmPrimitiveType type) throws SAXException
SAXException
protected final void startNode(Attributes atts) throws SAXException
SAXException
protected final void startWay(Attributes atts) throws SAXException
SAXException
protected final void startRelation(Attributes atts) throws SAXException
SAXException
protected final void handleTag(Attributes atts) throws SAXException
SAXException
protected final void handleNodeReference(Attributes atts) throws SAXException
SAXException
protected void handleMember(Attributes atts) throws SAXException
SAXException
protected final boolean doStartElement(String qName, Attributes atts) throws SAXException
SAXException