PMDescriptorsNodepublic class PMDescriptorsNode extends RuntimeDescriptorNode This node handles the pm-descriptors runtime xml element |
Constructors Summary |
---|
public PMDescriptorsNode()Creates new CmpNode
registerElementHandler(new XMLElement(RuntimeTagNames.PM_DESCRIPTOR),
PMDescriptorNode.class, "addPersistenceManager");
registerElementHandler(new XMLElement(RuntimeTagNames.PM_INUSE),
PMInUseNode.class, "setPersistenceManagerInUse");
|
Methods Summary |
---|
public org.w3c.dom.Node | writeDescriptor(org.w3c.dom.Node parent, java.lang.String nodeName, com.sun.enterprise.deployment.EjbBundleDescriptor descriptor)write the descriptor class to a DOM tree and return it
Node pms = null;
Vector pmDescriptors = descriptor.getPersistenceManagers();
if (pmDescriptors!=null && !pmDescriptors.isEmpty()) {
pms = super.writeDescriptor(parent, nodeName, descriptor);
PMDescriptorNode pmNode = new PMDescriptorNode();
for (Iterator pmIterator = pmDescriptors.iterator();pmIterator.hasNext();) {
IASPersistenceManagerDescriptor pmDescriptor = (IASPersistenceManagerDescriptor) pmIterator.next();
pmNode.writeDescriptor(pms, RuntimeTagNames.PM_DESCRIPTOR, pmDescriptor);
}
PersistenceManagerInUse inUse = descriptor.getPersistenceManagerInUse();
if (inUse!=null) {
PMInUseNode inUseNode = new PMInUseNode();
inUseNode.writeDescriptor(pms, RuntimeTagNames.PM_INUSE, inUse);
}
}
return pms;
|
|