Exemplo n.º 1
0
 public void fromXNode(XNode node) {
   setID(node.getAttributeValue("id"));
   setName(node.getChildText("name"));
   setDescription(node.getChildText("description"));
   setNotes(node.getChildText("notes"));
   XNode subNode = node.getChild("subCategories");
   for (XNode subCatNode : subNode.getChildren()) {
     addSubCategory(new NonHumanSubCategory(subCatNode));
   }
 }
Exemplo n.º 2
0
 private void storeSimpleFieldValues(NonHumanCategory category) {
   String name = (String) txtName.getText();
   if (name.length() > 0) category.setName(name);
   category.setDescription((String) txtDesc.getText());
   category.setNotes((String) txtNotes.getText());
 }