Created
October 1, 2010 09:45
-
-
Save jeanlaurent/605994 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package foo.bar; | |
import com.mycila.xmltool.XMLDoc; | |
import com.mycila.xmltool.XMLTag; | |
public class PoiBuilder { | |
public Poi buildFromXml(String xml) { | |
XMLTag xmlTag = XMLDoc.from(xml, true); | |
return new Poi(xmlTag.getText("//xml/address/way"), xmlTag.getText("//xml/address/town")); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Reading xml without headache with XmlTool