List resources = resourceManager.getResources();
// String
// []function=RoleManager.Access.getInstance().getRoleNames();
for (int i = 0; i < resources.size(); i++) {
HumanResource p = (HumanResource) resources.get(i);
addAttribute("id", p.getId(), attrs);
startPrefixedElement("resource", attrs, handler);
addAttribute("id", "0", attrs);
textElement("name", attrs, p.getName(), handler);
addAttribute("id", "1", attrs);
textElement("role", attrs, p.getRole().getName(), handler);
addAttribute("id", "2", attrs);
textElement("mail", attrs, p.getMail(), handler);
addAttribute("id", "3", attrs);
textElement("phone", attrs, p.getPhone(), handler);
List/*<CustomProperty>*/ customFields = p.getCustomProperties();
for (int j=0; j<customFields.size(); j++) {
CustomProperty nextProperty = (CustomProperty) customFields.get(j);
addAttribute("id", nextProperty.getDefinition().getID(), attrs);
String value = nextProperty.getValueAsString();
textElement("custom-field", attrs, value, handler);