public String getInstanceValue(Element element) throws MissingNodeException {
public String getInstanceValue(Element element, String appName) throws MissingNodeException {
		public String getInstanceValue(Element element) throws MissingNodeException {			Object value = element.selectObject(xpath);			if (value == null)				throw new MissingNodeException("Could not get value from element (path=" +					xpath + ")");			if (value instanceof List) {				List list = (List) value;				value = list.get(0);			}			if (value instanceof Node) {				Node node = (Node) value;				return node.getText();			} else if (value instanceof String) {				return (String) value;			} else if (value instanceof Number) {				String s = value.toString();				if (s.endsWith(".0"))					s = s.substring(0, s.length() - 2);				return s;			} else				throw new IllegalStateException("Unexpected object returned from xpath query: " + value);		}