FileDocCategorySizeDatePackage
SecurityService.javaAPI DocGlassfish v2 API3691Wed Jul 11 10:00:58 BST 2007com.sun.enterprise.tools.upgrade.transform.elements

SecurityService

public class SecurityService extends BaseElement
author
prakash

Fields Summary
Constructors Summary
public SecurityService()
Creates a new instance of Element

    
Methods Summary
public voidtransform(org.w3c.dom.Element element, org.w3c.dom.Element parentSource, org.w3c.dom.Element parentResult)
element - security-service parentSource - parent server of element parentResult - domain

		logger.log(Level.FINE, stringManager.getString("upgrade.transform.transformingMSG", this.getClass().getName(), element.getTagName()));
        // There is always a security service in result as well as source
       NodeList secureServs = parentResult.getElementsByTagName("security-service");
        Element secureService = null;
        if(secureServs.getLength() == 0){
            NodeList config = parentResult.getElementsByTagName("config");
            secureService = parentResult.getOwnerDocument().createElement("security-service");
            this.transferAttributes(element, secureService, null);
            this.appendElementToParent((Element)config.item(0),secureService);

        }else {
            secureService = (Element)secureServs.item(0);
            this.transferAttributes(element, secureService, null);
        }
        logger.log(Level.FINE, this.getClass().getName() +  ":: secureService", secureService.getTagName());
        super.transform(element,  parentSource, secureService);