Android Utililty Methods XmlPullParser Move to Next

List of utility methods to do XmlPullParser Move to Next

Description

The list of methods to do XmlPullParser Move to Next are organized into topic(s).

Method

voidnextElement(XmlPullParser parser)
next Element
int type;
while ((type = parser.next()) != parser.START_TAG
        && type != parser.END_DOCUMENT) {
    ;
booleannextElementWithin(XmlPullParser parser, int outerDepth)
next Element Within
for (;;) {
    int type = parser.next();
    if (type == XmlPullParser.END_DOCUMENT
            || type == XmlPullParser.END_TAG
            && parser.getDepth() == outerDepth) {
        return false;
    if (type == XmlPullParser.START_TAG
...
booleannextElementWithin(XmlPullParser parser, int outerDepth)
next Element Within
for (;;) {
    int type = parser.next();
    if (type == XmlPullParser.END_DOCUMENT
            || (type == XmlPullParser.END_TAG && parser.getDepth() == outerDepth)) {
        return false;
    if (type == XmlPullParser.START_TAG
            && parser.getDepth() == outerDepth + 1) {
...
booleannextElementWithin(XmlPullParser parser, int outerDepth)
next Element Within
for (;;) {
    int type = parser.next();
    if (type == XmlPullParser.END_DOCUMENT
            || (type == XmlPullParser.END_TAG && parser.getDepth() == outerDepth)) {
        return false;
    if (type == XmlPullParser.START_TAG
            && parser.getDepth() == outerDepth + 1) {
...
voidnextEndTag(XmlPullParser pp)
Call parser nextTag() and check that it is END_TAG, throw exception if not.
if (pp.nextTag() != XmlPullParser.END_TAG) {
    throw new XmlPullParserException("expected END_TAG and not"
            + pp.getPositionDescription());
voidnextEndTag(XmlPullParser pp)
Call parser nextTag() and check that it is END_TAG, throw exception if not.
if (pp.nextTag() != XmlPullParser.END_TAG) {
    throw new XmlPullParserException("expected END_TAG and not"
            + pp.getPositionDescription());
voidnextEndTag(XmlPullParser pp, String namespace, String name)
combine nextTag(); pp.require(XmlPullParser.END_TAG, namespace, name);
pp.nextTag();
pp.require(XmlPullParser.END_TAG, namespace, name);
voidnextEndTag(XmlPullParser pp, String namespace, String name)
combine nextTag(); pp.require(XmlPullParser.END_TAG, namespace, name);
pp.nextTag();
pp.require(XmlPullParser.END_TAG, namespace, name);
LongnextLong(XmlPullParser parser, String tag)
next Long
parser.require(XmlPullParser.START_TAG, null, tag);
Long value = Long.parseLong(readText(parser));
parser.require(XmlPullParser.END_TAG, null, tag);
return value;
voidnextStartTag(XmlPullParser pp)
call parser nextTag() and check that it is START_TAG, throw exception if not.
if (pp.nextTag() != XmlPullParser.START_TAG) {
    throw new XmlPullParserException("expected START_TAG and not "
            + pp.getPositionDescription());