CodeQL library for C/C++
codeql/cpp-all 0.12.10 (changelog, source)
Search

Class XmlElement

An XML element in an XML file.

Example:

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
          package="com.example.exampleapp" android:versionCode="1">
</manifest>

Import path

import cpp

Direct supertypes

Indirect supertypes

Predicates

getAnAttribute

Gets an XML attribute of this XML element.

getAttribute

Gets the attribute with the specified name, if any.

getAttributeValue

Gets the value of the attribute with the specified name, if any.

getDepth

Gets the depth of this element within the XML file tree structure.

getElementPositionIndex

Gets the index of this XML element among its parent’s children.

getFile

Gets the XML file in which this XML element occurs.

getIndex

Gets the index of this XML element among its parent’s children.

getName

Gets the name of this XML element.

getNamespace

Gets the namespace of this XML element, if any.

getParent

Gets the parent of this XML element.

hasAttribute

Holds if this XML element has an attribute with the specified name.

hasName

Holds if this XML element has the given name.

hasNamespace

Holds if this XML element has a namespace.

toString

Gets a printable representation of this XML element.

Inherited predicates

allCharactersString

Gets the result of appending all the character sequences of this XML parent from left to right, separated by a space.

from XmlParent
getACharactersSet

Gets a character sequence that is a child of this XML parent.

from XmlParent
getAChild

Gets a child element of this XML parent.

from XmlParent
getAChild

Gets a child element of this XML parent with the given name.

from XmlParent
getAComment

Gets a comment that is a child of this XML parent.

from XmlParent
getChild

Gets the child element at a specified index of this XML parent.

from XmlParent
getLocation

Gets the source location for this element.

from XmlLocatable
getNumberOfCharacterSets

Gets the number of places in the body of this XML parent where text occurs.

from XmlParent
getNumberOfChildren

Gets the number of child XML elements of this XML parent.

from XmlParent
getTextValue

Gets the text value contained in this XML parent.

from XmlParent
hasLocationInfo

Holds if this element is at the specified location. The location spans column startcolumn of line startline to column endcolumn of line endline in file filepath. For more information, see Locations.

from XmlLocatable