/** * Return the file extension string for this enumeration. */ public String getModuleExtension() { return (moduleExtension[getValue()]); }
/** * Return the file extension string for this enumeration. */ public String getModuleExtension() { return (moduleExtension[getValue()]); }
/** * Return the file extension string for this enumeration. */ public String getModuleExtension() { return (moduleExtension[getValue()]); }
@Override public int getValue() { return super.getValue(); } @Override
public boolean accept(ConfigurationInfo info) { return moduleType == null || info.getType() == ConfigurationModuleType.getFromValue(moduleType.getValue()); } };
public SerializableTargetModuleID(SerializableTargetModuleID parent, TargetModuleIDImpl impl) { parentModuleID = parent; moduleID = impl.getModuleID(); moduleType = impl.getModuleType().getValue(); TargetModuleID[] children = impl.getChildTargetModuleID(); int length = children != null ? children.length : 0; for (int n = 0; n < length; n++) { TargetModuleIDImpl child = (TargetModuleIDImpl)children[n]; childModuleIDs.add(new SerializableTargetModuleID(this, child)); } }
public boolean accept(ConfigurationInfo info) { return info.getState() == State.RUNNING && (moduleType == null || info.getType() == ConfigurationModuleType.getFromValue(moduleType.getValue())); } };
public boolean accept(ConfigurationInfo info) { return info.getState() != State.RUNNING && (moduleType == null || info.getType() == ConfigurationModuleType.getFromValue(moduleType.getValue())); } };
/** * Given a list of TargetModuleIDs, figure out which ones represent web * modules and add a WebURL to each if possible. */ public static void addWebContextPaths(Kernel kernel, List moduleIDs) throws Exception{ Set webApps = null; for (int i = 0; i < moduleIDs.size(); i++) { TargetModuleIDImpl id = (TargetModuleIDImpl) moduleIDs.get(i); if(id.getType() != null && id.getType().getValue() == ModuleType.WAR.getValue()) { if(webApps == null) { webApps = kernel.listGBeans(new AbstractNameQuery("org.apache.geronimo.management.geronimo.WebModule")); } for (Iterator it = webApps.iterator(); it.hasNext();) { AbstractName name = (AbstractName) it.next(); if(name.getName().get("name").equals(id.getModuleID())) { id.setWebURL(kernel.getAttribute(name, "contextPath").toString()); } } } if(id.getChildTargetModuleID() != null) { addWebContextPaths(kernel, Arrays.asList(id.getChildTargetModuleID())); } } }
Object[] args = { new Integer(moduleType.getValue()) }; String[] sig = { int.class.getName() }; SerializableTargetModuleID[] modules = (SerializableTargetModuleID[])server.invoke(jsr88MBean, "getAvailableModules", args, sig);