runAs.setDescriptions(getDescriptions(runAsE));
servletDefinition.setRunAs(runAs);
}
// Add servlet security role refs
SecurityRoleRefSetImpl securityRoleRefs = new SecurityRoleRefSetImpl();
NodeList securityRoleRefNL = servletE.getElementsByTagName("security-role-ref");
for (int m = 0; m < securityRoleRefNL.getLength(); m += 1) {
Element securityRoleRefE = (Element)securityRoleRefNL.item(m);
String roleName = XML.getChildElementText(securityRoleRefE, "role-name");
String roleLink = XML.getChildElementText(securityRoleRefE, "role-link");
String description = XML.getChildElementText(securityRoleRefE, "description");
SecurityRoleRefImpl securityRoleRef = new SecurityRoleRefImpl();
securityRoleRef.setDescription(description);
securityRoleRef.setRoleName(roleName);
securityRoleRef.setRoleLink(roleLink);
securityRoleRefs.add(securityRoleRef);
}
servletDefinition.setSecurityRoleRefs(securityRoleRefs);
// Add servlet mappings for this servlet
NodeList servletMappingNL = webAppE.getElementsByTagName("servlet-mapping");