Class ExpressionStreamReaderDelegate
- java.lang.Object
-
- javax.xml.stream.util.StreamReaderDelegate
-
- org.jboss.as.server.deployment.module.ExpressionStreamReaderDelegate
-
- All Implemented Interfaces:
XMLStreamConstants,XMLStreamReader
public class ExpressionStreamReaderDelegate extends StreamReaderDelegate
An XML Stream reader delegate adding methods that use aFunctionto resolve values retrieved by getElementTexts.- Author:
- Yeray Borges
-
-
Field Summary
-
Fields inherited from interface javax.xml.stream.XMLStreamConstants
ATTRIBUTE, CDATA, CHARACTERS, COMMENT, DTD, END_DOCUMENT, END_ELEMENT, ENTITY_DECLARATION, ENTITY_REFERENCE, NAMESPACE, NOTATION_DECLARATION, PROCESSING_INSTRUCTION, SPACE, START_DOCUMENT, START_ELEMENT
-
-
Constructor Summary
Constructors Constructor Description ExpressionStreamReaderDelegate(XMLStreamReader reader, Function<String,String> exprExpandFunction)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetElementText()-
Methods inherited from class javax.xml.stream.util.StreamReaderDelegate
close, getAttributeCount, getAttributeLocalName, getAttributeName, getAttributeNamespace, getAttributePrefix, getAttributeType, getAttributeValue, getAttributeValue, getCharacterEncodingScheme, getEncoding, getEventType, getLocalName, getLocation, getName, getNamespaceContext, getNamespaceCount, getNamespacePrefix, getNamespaceURI, getNamespaceURI, getNamespaceURI, getParent, getPIData, getPITarget, getPrefix, getProperty, getText, getTextCharacters, getTextCharacters, getTextLength, getTextStart, getVersion, hasName, hasNext, hasText, isAttributeSpecified, isCharacters, isEndElement, isStandalone, isStartElement, isWhiteSpace, next, nextTag, require, setParent, standaloneSet
-
-
-
-
Constructor Detail
-
ExpressionStreamReaderDelegate
public ExpressionStreamReaderDelegate(XMLStreamReader reader, Function<String,String> exprExpandFunction)
- Parameters:
reader- TheXMLStreamReaderfor the XML fileexprExpandFunction- A function which will be used, if provided, to expand any expressions (of the form of${foobar}) in the content being parsed. This function can be null, in which case the content is processed literally.
-
-
Method Detail
-
getElementText
public String getElementText() throws XMLStreamException
- Specified by:
getElementTextin interfaceXMLStreamReader- Overrides:
getElementTextin classStreamReaderDelegate- Throws:
XMLStreamException
-
-