service / com.scurab.android.uitor.tools / DOM2XmlPullBuilder

DOM2XmlPullBuilder

open class DOM2XmlPullBuilder

Simplistic DOM2 builder that should be enough to do support most cases. Requires JAXP DOMBuilder to provide DOM2 implementation.

NOTE:this class is stateless factory and it is safe to share between multiple threads.

Author
Aleksander Slominski

Constructors

<init>

Simplistic DOM2 builder that should be enough to do support most cases. Requires JAXP DOMBuilder to provide DOM2 implementation.

DOM2XmlPullBuilder()

Functions

naiveFormat

Simple naive formatting of xml file to have 1 attribute per line

open static fun naiveFormat(xml: String!): String!

newDoc

open fun newDoc(): Document!

newParser

open fun newParser(): XmlPullParser!

parse

open fun parse(reader: Reader!): Element!
open fun parse(reader: Reader!, docFactory: Document!): Element!
open fun parse(pp: XmlPullParser!, docFactory: Document!): Element!

parseSubTree

open fun parseSubTree(pp: XmlPullParser!): Element!
open fun parseSubTree(pp: XmlPullParser!, docFactory: Document!): Element!

transform

open static fun transform(xmlPullParser: XmlPullParser!): String!