Package de.hybris.bootstrap.xml
Class DefaultTagListener
java.lang.Object
de.hybris.bootstrap.xml.DefaultTagListener
- All Implemented Interfaces:
TagListener
- Direct Known Subclasses:
AbstractConfigurationTagListener,AbstractTypeSystemTagListener,AttributeTagListener,AttributeTagListener.TranslationTagListener,ConstraintsTagListener,ConstraintsTagListener.UniqueConstraintTagListener,DummyTagListener,ImpExHeaderTagListener,ImpExHeaderTagListener.AttributesTagListener,ParamsTagListener,ParamsTagListener.ParamTagListener,SimpleValueTagListener
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidvoidaddSubTagListener(TagListener listener) protected voidaddSubTagValue(String subTagListenerName, Object newValue) final voidcharacters(char[] character, int offset, int length) protected voidprotected Collection<TagListener>final voidendElement(ObjectProcessor processor) getAttribute(String qname) intprotected List<DefaultTagListener>protected Listintprotected Map<String,TagListener> protected doublegetSubTagDoubleValue(String subTagListenerName, double defaultValue) protected intgetSubTagIntValue(String subTagListenerName, int defaultValue) getSubTagListener(String tagname) protected ObjectgetSubTagValue(String subTagListenerName) protected CollectiongetSubTagValueCollection(String subTagListenerName) protected MapgetSubTagValueMap(String subTagListenerName) booleanisRoot()protected abstract ObjectprocessEndElement(ObjectProcessor processor) To be overridden.protected voidprocessError(Exception exception) protected ObjectprocessStartElement(ObjectProcessor processor) To be overridden.protected voidreadAttributes(Attributes attributes) voidsetEndLineNumber(int endLineNumber) voidsetStartLineNumber(int startLineNumber) final voidstartElement(ObjectProcessor processor, Attributes attributes) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.hybris.bootstrap.xml.TagListener
getTagName
-
Constructor Details
-
DefaultTagListener
public DefaultTagListener() -
DefaultTagListener
-
-
Method Details
-
getPartentTags
-
getParents
- Returns:
- All parent DefaultTagListeners (i.e. the parent and the parent of the parent and so on)
-
getParent
- Returns:
- The parent DefaultTagListener
-
isRoot
public boolean isRoot()- Returns:
- True, if this DefaultTagListener is the root TagListener (i.e. has no parent TagListeners)
-
getResult
- Specified by:
getResultin interfaceTagListener- See Also:
-
getSubListenerMap
-
addSubTagListener
-
getAttribute
- Specified by:
getAttributein interfaceTagListener- See Also:
-
readAttributes
- Parameters:
attributes-
-
addSubTagValue
-
addResult
-
processStartElement
To be overridden.- Parameters:
processor-- Returns:
- Object
- Throws:
ParseAbortException
-
processEndElement
To be overridden.- Parameters:
processor-- Returns:
- Object
- Throws:
ParseAbortException
-
processError
- Throws:
ParseAbortException
-
clearValues
protected void clearValues() -
startElement
public final void startElement(ObjectProcessor processor, Attributes attributes) throws ParseAbortException - Specified by:
startElementin interfaceTagListener- Throws:
ParseAbortException
-
endElement
- Specified by:
endElementin interfaceTagListener- Throws:
ParseAbortException
-
getSubTagListener
- Specified by:
getSubTagListenerin interfaceTagListener
-
characters
public final void characters(char[] character, int offset, int length) - Specified by:
charactersin interfaceTagListener- See Also:
-
createSubTagListeners
-
setEndLineNumber
public void setEndLineNumber(int endLineNumber) - Specified by:
setEndLineNumberin interfaceTagListener- See Also:
-
setStartLineNumber
public void setStartLineNumber(int startLineNumber) - Specified by:
setStartLineNumberin interfaceTagListener- See Also:
-
getSubTagValue
- Parameters:
subTagListenerName-
-
getSubTagIntValue
-
getSubTagDoubleValue
-
getSubTagValueCollection
- Parameters:
subTagListenerName- the name of the subtag listener to get all values for- Returns:
- all values produced by the specified subtag listener as
Collection- even null values will be returned as empty list
-
getSubTagValueMap
- Parameters:
subTagListenerName- the name of the subtag listener to get all values for- Returns:
- a map containing all maps produced by the specified subtag listener - null values are returned as empty
map, single values as self-mapping (
x := { x->x})
-
getCharacters
-
getEndLineNumber
public int getEndLineNumber()- Returns:
- Returns the endLineNumber.
-
getStartLineNumber
public int getStartLineNumber()- Returns:
- Returns the startLineNumber.
-