Class BufferingParser
java.lang.Object
org.apache.maven.model.transform.pull.BufferingParser
- All Implemented Interfaces:
XmlPullParser
- Direct Known Subclasses:
NodeBufferingParser
An xml pull parser filter base implementation.
- Since:
- 4.0.0
- Author:
- Guillaume Nodet
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
static class
static class
-
Field Summary
Modifier and TypeFieldDescriptionprotected boolean
protected BufferingParser.Event
protected Deque<BufferingParser.Event>
protected XmlPullParser
Fields inherited from interface org.codehaus.plexus.util.xml.pull.XmlPullParser
CDSECT, COMMENT, DOCDECL, END_DOCUMENT, END_TAG, ENTITY_REF, FEATURE_PROCESS_DOCDECL, FEATURE_PROCESS_NAMESPACES, FEATURE_REPORT_NAMESPACE_ATTRIBUTES, FEATURE_VALIDATION, IGNORABLE_WHITESPACE, NO_NAMESPACE, PROCESSING_INSTRUCTION, START_DOCUMENT, START_TAG, TEXT, TYPES
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
accept()
protected BufferingParser.Event
boolean
bypass()
void
bypass
(boolean bypass) void
defineEntityReplacementText
(String entityName, String replacementText) int
getAttributeName
(int index) getAttributeNamespace
(int index) getAttributePrefix
(int index) getAttributeType
(int index) getAttributeValue
(int index) getAttributeValue
(String namespace, String name) int
int
getDepth()
int
boolean
getFeature
(String name) int
getName()
getNamespace
(String prefix) int
getNamespaceCount
(int depth) getNamespacePrefix
(int pos) getNamespaceUri
(int pos) getProperty
(String name) getText()
char[]
getTextCharacters
(int[] holderForStartAndLength) boolean
isAttributeDefault
(int index) boolean
boolean
int
next()
int
nextTag()
nextText()
int
protected static String
nullSafeAppend
(String originalValue, String charSegment) protected void
pushEvent
(BufferingParser.Event event) void
void
setFeature
(String name, boolean state) void
setInput
(InputStream inputStream, String inputEncoding) void
void
setProperty
(String name, Object value)
-
Field Details
-
xmlPullParser
-
events
-
current
-
bypass
protected boolean bypass
-
-
Constructor Details
-
BufferingParser
-
-
Method Details
-
setFeature
- Specified by:
setFeature
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
getFeature
- Specified by:
getFeature
in interfaceXmlPullParser
-
setProperty
- Specified by:
setProperty
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
getProperty
- Specified by:
getProperty
in interfaceXmlPullParser
-
setInput
- Specified by:
setInput
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
setInput
- Specified by:
setInput
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
getInputEncoding
- Specified by:
getInputEncoding
in interfaceXmlPullParser
-
defineEntityReplacementText
public void defineEntityReplacementText(String entityName, String replacementText) throws XmlPullParserException - Specified by:
defineEntityReplacementText
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
getNamespaceCount
- Specified by:
getNamespaceCount
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
getNamespacePrefix
- Specified by:
getNamespacePrefix
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
getNamespaceUri
- Specified by:
getNamespaceUri
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
getNamespace
- Specified by:
getNamespace
in interfaceXmlPullParser
-
getDepth
public int getDepth()- Specified by:
getDepth
in interfaceXmlPullParser
-
getPositionDescription
- Specified by:
getPositionDescription
in interfaceXmlPullParser
-
getLineNumber
public int getLineNumber()- Specified by:
getLineNumber
in interfaceXmlPullParser
-
getColumnNumber
public int getColumnNumber()- Specified by:
getColumnNumber
in interfaceXmlPullParser
-
isWhitespace
- Specified by:
isWhitespace
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
getText
- Specified by:
getText
in interfaceXmlPullParser
-
getTextCharacters
public char[] getTextCharacters(int[] holderForStartAndLength) - Specified by:
getTextCharacters
in interfaceXmlPullParser
-
getNamespace
- Specified by:
getNamespace
in interfaceXmlPullParser
-
getName
- Specified by:
getName
in interfaceXmlPullParser
-
getPrefix
- Specified by:
getPrefix
in interfaceXmlPullParser
-
isEmptyElementTag
- Specified by:
isEmptyElementTag
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
getAttributeCount
public int getAttributeCount()- Specified by:
getAttributeCount
in interfaceXmlPullParser
-
getAttributeNamespace
- Specified by:
getAttributeNamespace
in interfaceXmlPullParser
-
getAttributeName
- Specified by:
getAttributeName
in interfaceXmlPullParser
-
getAttributePrefix
- Specified by:
getAttributePrefix
in interfaceXmlPullParser
-
getAttributeType
- Specified by:
getAttributeType
in interfaceXmlPullParser
-
isAttributeDefault
public boolean isAttributeDefault(int index) - Specified by:
isAttributeDefault
in interfaceXmlPullParser
-
getAttributeValue
- Specified by:
getAttributeValue
in interfaceXmlPullParser
-
getAttributeValue
- Specified by:
getAttributeValue
in interfaceXmlPullParser
-
require
public void require(int type, String namespace, String name) throws XmlPullParserException, IOException - Specified by:
require
in interfaceXmlPullParser
- Throws:
XmlPullParserException
IOException
-
getEventType
- Specified by:
getEventType
in interfaceXmlPullParser
- Throws:
XmlPullParserException
-
next
- Specified by:
next
in interfaceXmlPullParser
- Throws:
XmlPullParserException
IOException
-
nextToken
- Specified by:
nextToken
in interfaceXmlPullParser
- Throws:
XmlPullParserException
IOException
-
nextTag
- Specified by:
nextTag
in interfaceXmlPullParser
- Throws:
XmlPullParserException
IOException
-
nextText
- Specified by:
nextText
in interfaceXmlPullParser
- Throws:
XmlPullParserException
IOException
-
bufferEvent
- Throws:
XmlPullParserException
-
pushEvent
-
accept
- Throws:
XmlPullParserException
IOException
-
bypass
public void bypass(boolean bypass) -
bypass
public boolean bypass() -
nullSafeAppend
-