Added in API level 1

Element


open class Element
kotlin.Any
   ↳ android.sax.Element

An XML element. Provides access to child elements and hooks to listen for events related to this element.

Summary

Public methods
open Element!
getChild(localName: String!)

Gets the child element with the given name.

open Element!
getChild(uri: String!, localName: String!)

Gets the child element with the given name.

open Element!
requireChild(localName: String!)

Gets the child element with the given name.

open Element!
requireChild(uri: String!, localName: String!)

Gets the child element with the given name.

open Unit

Sets start and end element listeners at the same time.

open Unit

Sets a listener for the end of this element.

open Unit

Sets a listener for the end of this text element.

open Unit

Sets a listener for the start of this element.

open Unit

Sets start and end text element listeners at the same time.

open String

Public methods

getChild

Added in API level 1
open fun getChild(localName: String!): Element!

Gets the child element with the given name. Uses an empty string as the namespace.

getChild

Added in API level 1
open fun getChild(
    uri: String!,
    localName: String!
): Element!

Gets the child element with the given name.

requireChild

Added in API level 1
open fun requireChild(localName: String!): Element!

Gets the child element with the given name. Uses an empty string as the namespace. We will throw a org.xml.sax.SAXException at parsing time if the specified child is missing. This helps you ensure that your listeners are called.

requireChild

Added in API level 1
open fun requireChild(
    uri: String!,
    localName: String!
): Element!

Gets the child element with the given name. We will throw a org.xml.sax.SAXException at parsing time if the specified child is missing. This helps you ensure that your listeners are called.

setElementListener

Added in API level 1
open fun setElementListener(elementListener: ElementListener!): Unit

Sets start and end element listeners at the same time.

setEndElementListener

Added in API level 1
open fun setEndElementListener(endElementListener: EndElementListener!): Unit

Sets a listener for the end of this element.

setEndTextElementListener

Added in API level 1
open fun setEndTextElementListener(endTextElementListener: EndTextElementListener!): Unit

Sets a listener for the end of this text element.

setStartElementListener

Added in API level 1
open fun setStartElementListener(startElementListener: StartElementListener!): Unit

Sets a listener for the start of this element.

setTextElementListener

Added in API level 1
open fun setTextElementListener(elementListener: TextElementListener!): Unit

Sets start and end text element listeners at the same time.

toString

Added in API level 1
open fun toString(): String
Return
String a string representation of the object.