FileDocCategorySizeDatePackage
J2EEModuleMdl.javaAPI DocGlassfish v2 API4803Fri May 04 22:24:16 BST 2007com.sun.enterprise.management.model

J2EEModuleMdl

public abstract class J2EEModuleMdl extends J2EEDeployedObjectMdl

Fields Summary
HashSet
externalVMs
Constructors Summary
J2EEModuleMdl(com.sun.enterprise.management.util.J2EEModuleCallBack module)


      
        super(module);
    
Methods Summary
public voidaddVm(java.lang.String name)
The name of the J2EEManagedObject. All managed objects must have a unique name within the context of the management domain. The name must not be null.

        externalVMs.add(name);
    
public abstract java.lang.StringgetJ2EEApplication()

public abstract java.lang.StringgetModuleName()

public java.lang.String[]getjavaVMs()

        //get the internal VM name
        //App Clients never run on the internal VM
        Set res = new HashSet();
        if (!(this instanceof AppClientModuleMdl)) {
            //res.addAll(findNames("j2eeType=JVM,name=" + MOAgentFactory.getAgent().getJVMId()));
        }
        //get the external VM names
        Iterator vmNames = externalVMs.iterator();
        while(vmNames.hasNext()) {
              String vmName = (String)vmNames.next();
              Set x = findNames("j2eeType=JVM,name=" + vmName);
              if(x.size() > 0) {
        		res.addAll(x);
              } else {
                //no longer an active VM
                externalVMs.remove(vmName);
                vmNames = externalVMs.iterator();
              }
        }
        Iterator it = res.iterator();
        String [] vms = new String [res.size()];
        int i =0;
        while(it.hasNext()) {
            vms[i++] = ((ObjectName)it.next()).toString();
        }
        return vms;
    
public static booleanisStandAloneModule(java.lang.String applicationName)

	if ( applicationName == null 
	     || applicationName.equals("") 
	     || applicationName.equals("null") ) {
	    return true;
	}
        return false;
    
public booleaniseventProvider()
Overriding method of ManagedObject

        if(this.getJ2EEApplication().equals("null"))
            return true;
        return false;
    
public booleanisstateManageable()
Overriding method of ManagedObject

	/*
        if(this.getJ2EEApplication().equals("null"))
            return true;
	*/
        return false;