elem.addContent(
Util.createElement("details", fault.getDetails()));
}
}
public FaultMessage readFault(Element elem) {
FaultMessage fault = new FaultMessage(null, null);
List children = elem.getChildren();
Element child;
for (int i=0; i<children.size(); i++) {
child = (Element)children.get(i);
String name = child.getName();
if (name.equals("type"))
fault.setType(child.getText());
else if (name.equals("message"))
fault.setMessage(child.getText());
else if (name.equals("details"))
fault.setDetails(child.getText());
}
return fault;
}