Android XML Document Load loadData(String xmlData)

Here you can find the source of loadData(String xmlData)

Description

load Data

Declaration

public static XmlPullParser loadData(String xmlData)
            throws XmlPullParserException 

Method Source Code

//package com.java2s;
import java.io.StringReader;

import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;
import org.xmlpull.v1.XmlPullParserFactory;

public class Main {
    public static XmlPullParser loadData(String xmlData)
            throws XmlPullParserException {
        XmlPullParserFactory parserFactory = XmlPullParserFactory
                .newInstance();/*from ww  w . j  a v  a 2  s .  c om*/
        XmlPullParser parser = parserFactory.newPullParser();
        parser.setInput(new StringReader(xmlData));

        return parser;
    }
}

Related

  1. URLToDocument(URL url)
  2. getDocument(String strxml)
  3. getDocument(String strxml)
  4. loadXMLFromString(String xml)
  5. load(String filename)
  6. loadFile(Context context, String fileName)