Methods Summary |
---|
public void | close()
// pass
|
public void | defineEntityReplacementText(java.lang.String entityName, java.lang.String replacementText)
throw new XmlPullParserException(
"defineEntityReplacementText() not supported");
|
public void | ensurePopped()
if (mContext != null && mPopped == false) {
mContext.popParser();
mPopped = true;
}
|
public static java.lang.String | eventTypeToString(int eventType)
switch (eventType) {
case START_DOCUMENT:
return "START_DOC";
case END_DOCUMENT:
return "END_DOC";
case START_TAG:
return "START_TAG";
case END_TAG:
return "END_TAG";
case TEXT:
return "TEXT";
case CDSECT:
return "CDSECT";
case ENTITY_REF:
return "ENTITY_REF";
case IGNORABLE_WHITESPACE:
return "IGNORABLE_WHITESPACE";
case PROCESSING_INSTRUCTION:
return "PROCESSING_INSTRUCTION";
case COMMENT:
return "COMMENT";
case DOCDECL:
return "DOCDECL";
}
return "????";
|
public boolean | getAttributeBooleanValue(int index, boolean defaultValue)
return mAttrib.getAttributeBooleanValue(index, defaultValue);
|
public boolean | getAttributeBooleanValue(java.lang.String namespace, java.lang.String attribute, boolean defaultValue)
return mAttrib.getAttributeBooleanValue(namespace, attribute, defaultValue);
|
public int | getAttributeCount()
return mParser.getAttributeCount();
|
public float | getAttributeFloatValue(int index, float defaultValue)
return mAttrib.getAttributeFloatValue(index, defaultValue);
|
public float | getAttributeFloatValue(java.lang.String namespace, java.lang.String attribute, float defaultValue)
return mAttrib.getAttributeFloatValue(namespace, attribute, defaultValue);
|
public int | getAttributeIntValue(int index, int defaultValue)
return mAttrib.getAttributeIntValue(index, defaultValue);
|
public int | getAttributeIntValue(java.lang.String namespace, java.lang.String attribute, int defaultValue)
return mAttrib.getAttributeIntValue(namespace, attribute, defaultValue);
|
public int | getAttributeListValue(int index, java.lang.String[] options, int defaultValue)
return mAttrib.getAttributeListValue(index, options, defaultValue);
|
public int | getAttributeListValue(java.lang.String namespace, java.lang.String attribute, java.lang.String[] options, int defaultValue)
return mAttrib.getAttributeListValue(namespace, attribute, options, defaultValue);
|
public java.lang.String | getAttributeName(int index)
return mParser.getAttributeName(index);
|
public int | getAttributeNameResource(int index)
return mAttrib.getAttributeNameResource(index);
|
public java.lang.String | getAttributeNamespace(int index)
return mParser.getAttributeNamespace(index);
|
public java.lang.String | getAttributePrefix(int index)
throw new RuntimeException("getAttributePrefix not supported");
|
public int | getAttributeResourceValue(int index, int defaultValue)
return mAttrib.getAttributeResourceValue(index, defaultValue);
|
public int | getAttributeResourceValue(java.lang.String namespace, java.lang.String attribute, int defaultValue)
return mAttrib.getAttributeResourceValue(namespace, attribute, defaultValue);
|
public java.lang.String | getAttributeType(int index)
return "CDATA";
|
public int | getAttributeUnsignedIntValue(int index, int defaultValue)
return mAttrib.getAttributeUnsignedIntValue(index, defaultValue);
|
public int | getAttributeUnsignedIntValue(java.lang.String namespace, java.lang.String attribute, int defaultValue)
return mAttrib.getAttributeUnsignedIntValue(namespace, attribute, defaultValue);
|
public java.lang.String | getAttributeValue(int index)
return mParser.getAttributeValue(index);
|
public java.lang.String | getAttributeValue(java.lang.String namespace, java.lang.String name)
return mParser.getAttributeValue(namespace, name);
|
public java.lang.String | getClassAttribute()
return mAttrib.getClassAttribute();
|
public int | getColumnNumber()
return -1;
|
public int | getDepth()
return mParser.getDepth();
|
public int | getEventType()
return mEventType;
|
public boolean | getFeature(java.lang.String name)
if (FEATURE_PROCESS_NAMESPACES.equals(name)) {
return true;
}
if (FEATURE_REPORT_NAMESPACE_ATTRIBUTES.equals(name)) {
return true;
}
return false;
|
public java.lang.String | getIdAttribute()
return mAttrib.getIdAttribute();
|
public int | getIdAttributeResourceValue(int defaultValue)
return mAttrib.getIdAttributeResourceValue(defaultValue);
|
public java.lang.String | getInputEncoding()
return null;
|
public int | getLineNumber()
return mParser.getLineNumber();
|
public java.lang.String | getName()
return mParser.getName();
|
public java.lang.String | getNamespace(java.lang.String prefix)
throw new RuntimeException("getNamespace() not supported");
|
public java.lang.String | getNamespace()
return mParser.getNamespace();
|
public int | getNamespaceCount(int depth)
throw new XmlPullParserException("getNamespaceCount() not supported");
|
public java.lang.String | getNamespacePrefix(int pos)
throw new XmlPullParserException("getNamespacePrefix() not supported");
|
public java.lang.String | getNamespaceUri(int pos)
throw new XmlPullParserException("getNamespaceUri() not supported");
|
public org.xmlpull.v1.XmlPullParser | getParser()
return mParser;
|
public java.lang.String | getPositionDescription()
return "Binary XML file line #" + getLineNumber();
|
public java.lang.String | getPrefix()
throw new RuntimeException("getPrefix not supported");
|
public java.lang.Object | getProperty(java.lang.String name)
return null;
|
public int | getStyleAttribute()
return mAttrib.getStyleAttribute();
|
public java.lang.String | getText()
return mParser.getText();
|
public char[] | getTextCharacters(int[] holderForStartAndLength)
String txt = getText();
char[] chars = null;
if (txt != null) {
holderForStartAndLength[0] = 0;
holderForStartAndLength[1] = txt.length();
chars = new char[txt.length()];
txt.getChars(0, txt.length(), chars, 0);
}
return chars;
|
public java.lang.Object | getViewCookie()
if (mParser instanceof ILayoutPullParser) {
return ((ILayoutPullParser)mParser).getViewCookie();
}
return null;
|
public boolean | isAttributeDefault(int index)
return false;
|
public boolean | isEmptyElementTag()
// XXX Need to detect this.
return false;
|
public boolean | isPlatformFile()
return mPlatformFile;
|
public boolean | isWhitespace()
// Original comment: whitespace was stripped by aapt.
return mParser.isWhitespace();
|
public int | next()
if (!mStarted) {
mStarted = true;
if (ParserFactory.LOG_PARSER) {
System.out.println("STRT " + mParser.toString());
}
return START_DOCUMENT;
}
int ev = mParser.next();
if (ParserFactory.LOG_PARSER) {
System.out.println("NEXT " + mParser.toString() + " " +
eventTypeToString(mEventType) + " -> " + eventTypeToString(ev));
}
if (ev == END_TAG && mParser.getDepth() == 1) {
// done with parser remove it from the context stack.
ensurePopped();
if (ParserFactory.LOG_PARSER) {
System.out.println("");
}
}
mEventType = ev;
return ev;
|
public int | nextTag()
int eventType = next();
if (eventType == TEXT && isWhitespace()) { // skip whitespace
eventType = next();
}
if (eventType != START_TAG && eventType != END_TAG) {
throw new XmlPullParserException(getPositionDescription()
+ ": expected start or end tag", this, null);
}
return eventType;
|
public java.lang.String | nextText()
if (getEventType() != START_TAG) {
throw new XmlPullParserException(getPositionDescription()
+ ": parser must be on START_TAG to read next text", this,
null);
}
int eventType = next();
if (eventType == TEXT) {
String result = getText();
eventType = next();
if (eventType != END_TAG) {
throw new XmlPullParserException(
getPositionDescription()
+ ": event TEXT it must be immediately followed by END_TAG",
this, null);
}
return result;
} else if (eventType == END_TAG) {
return "";
} else {
throw new XmlPullParserException(getPositionDescription()
+ ": parser must be on START_TAG or TEXT to read text",
this, null);
}
|
public int | nextToken()
return next();
|
public void | require(int type, java.lang.String namespace, java.lang.String name)
if (type != getEventType()
|| (namespace != null && !namespace.equals(getNamespace()))
|| (name != null && !name.equals(getName())))
throw new XmlPullParserException("expected " + TYPES[type]
+ getPositionDescription());
|
public void | setFeature(java.lang.String name, boolean state)
if (FEATURE_PROCESS_NAMESPACES.equals(name) && state) {
return;
}
if (FEATURE_REPORT_NAMESPACE_ATTRIBUTES.equals(name) && state) {
return;
}
throw new XmlPullParserException("Unsupported feature: " + name);
|
public void | setInput(java.io.Reader in)
mParser.setInput(in);
|
public void | setInput(java.io.InputStream inputStream, java.lang.String inputEncoding)
mParser.setInput(inputStream, inputEncoding);
|
public void | setProperty(java.lang.String name, java.lang.Object value)
throw new XmlPullParserException("setProperty() not supported");
|