Code example for XmlResourceParser

Methods: getAttributeResourceValue, getAttributeValue

0
	 * @param xml 
	 * @param name 
	 * @return 
	 */ 
	private String getXmlAttribute(XmlResourceParser xml, String name) {
		int resId = xml.getAttributeResourceValue(null, name, 0);
		if (resId == 0) {
			return xml.getAttributeValue(null, name);
		} else { 
			return getString(resId);
		} 
	} 
 
	/** 
	 * Looks up if there is a server in the servers.xml file for the given 
	 * domain. 
	 *  
	 * @param domain 
	 * @return 
	 */ 
	private Server findServerForDomain(String domain) {