1 23 package com.sun.enterprise.deployment.node.ejb; 24 25 import java.util.Map ; 26 import org.w3c.dom.Node ; 27 import org.xml.sax.Attributes ; 28 29 import com.sun.enterprise.deployment.node.XMLElement; 30 import com.sun.enterprise.deployment.node.DeploymentDescriptorNode; 31 import com.sun.enterprise.deployment.node.LocalizedInfoNode; 32 import com.sun.enterprise.deployment.node.MethodNode; 33 import com.sun.enterprise.deployment.node.DescriptorFactory; 34 35 import com.sun.enterprise.deployment.Descriptor; 36 import com.sun.enterprise.deployment.EjbBundleDescriptor; 37 import com.sun.enterprise.deployment.EjbApplicationExceptionInfo; 38 39 import com.sun.enterprise.deployment.xml.EjbTagNames; 40 41 public class EjbApplicationExceptionNode extends DeploymentDescriptorNode { 42 43 public EjbApplicationExceptionNode() { 44 super(); 45 } 46 47 53 protected Map getDispatchTable() { 54 Map table = super.getDispatchTable(); 56 57 table.put(EjbTagNames.APP_EXCEPTION_CLASS, "setExceptionClassName"); 58 table.put(EjbTagNames.APP_EXCEPTION_ROLLBACK, "setRollback"); 59 60 return table; 61 } 62 63 71 public Node writeDescriptor(Node parent, String nodeName, 72 EjbApplicationExceptionInfo descriptor) { 73 74 Node appExceptionNode = appendChild(parent, nodeName); 75 76 appendTextChild(appExceptionNode, EjbTagNames.APP_EXCEPTION_CLASS, 77 descriptor.getExceptionClassName()); 78 appendTextChild(appExceptionNode, EjbTagNames.APP_EXCEPTION_ROLLBACK, 79 Boolean.toString(descriptor.getRollback())); 80 81 return appExceptionNode; 82 } 83 } 84 | Popular Tags |