Code example for XmlResourceParser

Methods: getAttributeIntValuegetAttributeValue

0
		return group;
	} 
 
	private static TMXObject readTMXObject(XmlResourceParser xrp) throws XmlPullParserException, IOException {
		final TMXObject object = new TMXObject();
		object.name = xrp.getAttributeValue(null, "name");
		object.type = xrp.getAttributeValue(null, "type");
		object.x = xrp.getAttributeIntValue(null, "x", -1);
		object.y = xrp.getAttributeIntValue(null, "y", -1);
		object.width = xrp.getAttributeIntValue(null, "width", -1);
		object.height = xrp.getAttributeIntValue(null, "height", -1);
		XmlResourceParserUtils.readCurrentTagUntilEnd(xrp, new XmlResourceParserUtils.TagHandler() {
			public void handleTag(XmlResourceParser xrp, String tagName) throws XmlPullParserException, IOException {
				if (tagName.equals("property")) {
					object.properties.add(readTMXProperty(xrp));
				} 
			} 
		}); 
		return object;
	} 
Connect your IDE to all the code out there  Get Codota for Java