Android XmlPullParser Read readText(XmlPullParser parser)

Here you can find the source of readText(XmlPullParser parser)

Description

read Text

License

Open Source License

Declaration

public static String readText(XmlPullParser parser) throws IOException,
            XmlPullParserException 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.io.IOException;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;

public class Main {
    public static String readText(XmlPullParser parser) throws IOException,
            XmlPullParserException {/*from  w  w  w  .ja va 2s . c  o  m*/
        String result = "";
        if (parser.next() == XmlPullParser.TEXT) {
            result = parser.getText();
            parser.nextTag();
        }
        return result;
    }
}

Related

  1. readNumber(XmlPullParser parser)
  2. readString(XmlPullParser parser, String ns, String tag)
  3. readStringArray(XmlPullParser parser, String tagName, String delimiter)
  4. readStringAttribute(XmlPullParser in, String name)
  5. readText(XmlPullParser parser)
  6. readText(XmlPullParser parser)
  7. readText(XmlPullParser parser)
  8. readText(XmlPullParser parser, String tagName)
  9. readThisDoubleArrayXml( XmlPullParser parser, String endTag, String[] name)