FileDocCategorySizeDatePackage
TransactionService.javaAPI DocGlassfish v2 API3731Fri May 04 22:35:10 BST 2007com.sun.enterprise.tools.upgrade.transform.elements

TransactionService

public class TransactionService extends BaseElement
author
prakash

Fields Summary
Constructors Summary
public TransactionService()
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 - transaction-service parentSource - parent server of element parentResult - domain

        // There is always a security service in result as well as source
       NodeList transacServs = parentResult.getElementsByTagName("transaction-service");
        Element transacServ = null;
        if(transacServs.getLength() == 0){
            NodeList config = parentResult.getElementsByTagName("config");
            transacServ = parentResult.getOwnerDocument().createElement("transaction-service");
            java.util.Vector notToTransferAttrList = new java.util.Vector();
            notToTransferAttrList.add("tx-log-dir");
            this.transferAttributes(element, transacServ, notToTransferAttrList);
            this.appendElementToParent((Element)config.item(0),transacServ);  
        }else {
            transacServ = (Element)transacServs.item(0);
            java.util.Vector notToTransferAttrList = new java.util.Vector();
            notToTransferAttrList.add("tx-log-dir");
            this.transferAttributes(element, transacServ, notToTransferAttrList);
        } 
        super.transform(element,  parentSource, transacServ);