try {
Doc doc = XMLParser.parse(file);
Elem e = doc.xpathElement("/example");
Example ex = new Example();
ex.name = e.attr("name");
for(Elem k : e.xpath("keyword")) {
ex.keywords.add(k.text().toLowerCase());
//Util.p("added keyword: " + k.text().toLowerCase());
}
ex.description = e.xpathString("description/text()");
ex.directory = file.getParentFile();