我是 GWT GWT-EXT 的新手,我模仿它的演示问题是我应该把xml文件放在哪里
final TreePanel treePanel = new TreePanel() {
{
setAnimate(true);
setEnableDD(true);
setContainerScroll(true);
setRootVisible(true);
}
};
final XMLTreeLoader loader = new XMLTreeLoader() {
{
setDataUrl("countries-cb.xml");
setMethod("get");
setRootTag("countries");
setFolderIdMapping("@id");
setLeafIdMapping("@id");
setFolderTitleMapping("@title");
setFolderTag("team");
setLeafTitleMapping("@title");
setLeafTag("country");
setQtipMapping("@qtip");
setDisabledMapping("@disabled");
setCheckedMapping("@checked");
setIconMapping("@icon");
setAttributeMappings(new String[]{"@rank"});
}
};
AsyncTreeNode root = new AsyncTreeNode("Countries", loader);
treePanel.setRootNode(root);
treePanel.render();
root.expand();
treePanel.expandAll();