Code example for Element

Methods: getFirstChild

0
////		System.out.println("xml string: " +xmlString); 
//	} 
 
	private String getCharacterDataFromElement(Element e) {
		try { 
			Node child = e.getFirstChild();
			if (child instanceof CharacterData) {
				CharacterData cd = (CharacterData) child;
				return cd.getData();
			} 
		} catch (Exception ex) {
 
		} 
		return ""; 
	} // private String getCharacterDataFromElement 
 
	/** 
	 * Gets the float. 
	 * 
	 * @param value the value 
	 * @return the float