Class AbstractElement
java.lang.Object
org.x4o.xml.element.AbstractElement
- All Implemented Interfaces:
Element
- Direct Known Subclasses:
AttributeAliasElement, BeanElement, DefaultElement, DefaultElementBodyComment, DefaultElementBodyWhitespace, DescriptionElement, ElementClassAddParentElement, ELReferenceElement, MethodElement, ModuleElement, NextAttributeElement, ParentObjectElement, PropertyElement, SkipPhaseElement
-
Nested Class Summary
Nested classes/interfaces inherited from interface Element
Element.ElementType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdds an Elment as child of this element.voiddoCharacters(String characters) Sets the body texts on an event based system.voidSets the comment texts on an event based system.voidThis method is fired when the end xml tag is parsed.voidThis method is fired only once in the run phase.voidThis method is fired when the start of xml tag is parsed.voiddoIgnorableWhitespace(String space) Is called when there is whitespace in xml.Gets the childeren elements including those which are comment and white space.Gets the xml attributes.Gets the childeren elements.Gets the ElementClass.Gives back the object this Element has made and configed.
So other elements can do stuff to that object.Gets the Element type.Gets the X4OLanguageSession.Returns the parent Element.
Or null when there is no parent Element.booleanDefaults to false.voidrelease()Cleans the attributes and elements(class) and context.voidremoveChild(Element element) Removes an Elment as child of this element.voidsetAttribute(String name, String value) Sets the xml attributes.voidsetElementClass(ElementClass elementClass) Sets the ElementClass.voidsetElementObject(Object object) Sets the object which we control.voidsetLanguageSession(X4OLanguageSession languageSession) Sets the X4OLanguageSession.voidSet the parent Element.
-
Constructor Details
-
AbstractElement
public AbstractElement()
-
-
Method Details
-
doElementStart
Description copied from interface:ElementThis method is fired when the start of xml tag is parsed.- Specified by:
doElementStartin interfaceElement- Throws:
ElementException- Can be thrown when structure is not correct.- See Also:
-
doElementEnd
Description copied from interface:ElementThis method is fired when the end xml tag is parsed.- Specified by:
doElementEndin interfaceElement- Throws:
ElementException- Can be thrown when structure is not correct.- See Also:
-
doElementRun
Description copied from interface:ElementThis method is fired only once in the run phase.- Specified by:
doElementRunin interfaceElement- Throws:
ElementException- Can be thrown when structure is not correct.- See Also:
-
setParent
-
getParent
-
release
Cleans the attributes and elements(class) and context.- Specified by:
releasein interfaceElement- Throws:
ElementException- Can be thrown when structure is not correct.- See Also:
-
getElementObject
Description copied from interface:ElementGives back the object this Element has made and configed.
So other elements can do stuff to that object.- Specified by:
getElementObjectin interfaceElement- Returns:
- An Object.
- See Also:
-
setElementObject
Description copied from interface:ElementSets the object which we control.- Specified by:
setElementObjectin interfaceElement- Parameters:
object- The object to configed by this element.- See Also:
-
setLanguageSession
Description copied from interface:ElementSets the X4OLanguageSession.- Specified by:
setLanguageSessionin interfaceElement- Parameters:
languageSession- The X4OLanguageSession to set.- See Also:
-
getLanguageSession
Description copied from interface:ElementGets the X4OLanguageSession.- Specified by:
getLanguageSessionin interfaceElement- Returns:
- Returns the X4OLanguageSession.
- See Also:
-
doCharacters
Description copied from interface:ElementSets the body texts on an event based system.- Specified by:
doCharactersin interfaceElement- Parameters:
characters- The body text.- Throws:
ElementException- Can be thrown when structure is not correct.- See Also:
-
doComment
Description copied from interface:ElementSets the comment texts on an event based system.- Specified by:
doCommentin interfaceElement- Parameters:
comment- The comment text.- Throws:
ElementException- Can be thrown when structure is not correct.- See Also:
-
doIgnorableWhitespace
Description copied from interface:ElementIs called when there is whitespace in xml.- Specified by:
doIgnorableWhitespacein interfaceElement- Parameters:
space- The space.- Throws:
ElementException- Can be thrown when structure is not correct.- See Also:
-
setElementClass
Description copied from interface:ElementSets the ElementClass.- Specified by:
setElementClassin interfaceElement- Parameters:
elementClass- The ElementClass to set.- See Also:
-
getElementClass
Description copied from interface:ElementGets the ElementClass.- Specified by:
getElementClassin interfaceElement- Returns:
- Returns the ElementClass.
- See Also:
-
getAttributes
-
setAttribute
Description copied from interface:ElementSets the xml attributes.- Specified by:
setAttributein interfaceElement- Parameters:
name- The name to set.value- The value to set.- See Also:
-
getChilderen
Description copied from interface:ElementGets the childeren elements.- Specified by:
getChilderenin interfaceElement- Returns:
- Returns the childeren.
- See Also:
-
addChild
-
removeChild
Description copied from interface:ElementRemoves an Elment as child of this element.- Specified by:
removeChildin interfaceElement- Parameters:
element- The child to remove.- See Also:
-
getAllChilderen
Description copied from interface:ElementGets the childeren elements including those which are comment and white space. (text)- Specified by:
getAllChilderenin interfaceElement- Returns:
- Returns all the childeren.
- See Also:
-
getElementType
Description copied from interface:ElementGets the Element type.- Specified by:
getElementTypein interfaceElement- Returns:
- Returns the ElementType.
- See Also:
-
isTransformingTree
public boolean isTransformingTree()Defaults to false.- Specified by:
isTransformingTreein interfaceElement- Returns:
- Returns true if transforming tree.
- See Also:
-