Examples of ModuleDefinition


Examples of org.impalaframework.module.definition.ModuleDefinition

public class DefaultModuleStateChangeNotifier implements ModuleStateChangeNotifier {

  private List<ModuleStateChangeListener> listeners = new LinkedList<ModuleStateChangeListener>();

  public void notify(ModuleStateHolder moduleStateHolder, ModuleStateChange change) {
    ModuleDefinition moduleDefinition = change.getModuleDefinition();

    for (ModuleStateChangeListener moduleStateChangeListener : listeners) {
      String moduleName = moduleStateChangeListener.getModuleName();

      boolean notify = true;

      if (moduleName != null) {
        if (!moduleName.equals(moduleDefinition.getName())) {
          notify = false;
        }
      }

      if (notify) {
View Full Code Here

Examples of org.jbpm.module.def.ModuleDefinition

    String resource = JbpmConfiguration.Configs.getString("resource.default.modules");
    Properties defaultModulesProperties = ClassLoaderUtil.getProperties(resource);
    for (Object key : defaultModulesProperties.keySet()) {
      String moduleClassName = (String) key;
      try {
        ModuleDefinition moduleDefinition = (ModuleDefinition) ClassLoaderUtil.classForName(moduleClassName).newInstance();
        processDefinition.addDefinition(moduleDefinition);
       
      } catch (Exception e) {
        throw new JbpmException("couldn't instantiate default module '"+moduleClassName+"'", e);
      }     
View Full Code Here

Examples of org.jbpm.module.def.ModuleDefinition

    moduleDefinition.setProcessDefinition(this);
    return moduleDefinition;
  }
 
  public ModuleDefinition removeDefinition(ModuleDefinition moduleDefinition) {
    ModuleDefinition removedDefinition = null;
    if (moduleDefinition == null) throw new IllegalArgumentException("can't remove a null moduleDefinition from a process definition");
    if (definitions != null) {
      removedDefinition = definitions.remove(moduleDefinition.getClass().getName());
      if (removedDefinition!=null) {
        moduleDefinition.setProcessDefinition(null);
View Full Code Here

Examples of org.jbpm.module.def.ModuleDefinition

    if ( definitions != null ) {
      instances = new HashMap();
      // loop over each optional definition
      Iterator iter = definitions.values().iterator();
      while (iter.hasNext()) {
        ModuleDefinition definition = (ModuleDefinition) iter.next();
        // and create the corresponding optional instance
        ModuleInstance instance = definition.createInstance();
        if (instance != null) {
          addInstance( instance );
        }
      }
    }
View Full Code Here

Examples of org.jbpm.module.def.ModuleDefinition

    Properties defaultModulesProperties = ClassLoaderUtil.getProperties(resource);
    Iterator iter = defaultModulesProperties.keySet().iterator();
    while (iter.hasNext()) {
      String moduleClassName = (String) iter.next();
      try {
        ModuleDefinition moduleDefinition = (ModuleDefinition) ClassLoaderUtil.loadClass(moduleClassName).newInstance();
        processDefinition.addDefinition(moduleDefinition);
       
      } catch (Exception e) {
        e.printStackTrace();
        throw new JbpmException("couldn't instantiate default module '"+moduleClassName+"'", e);
View Full Code Here

Examples of org.jbpm.module.def.ModuleDefinition

    moduleDefinition.setProcessDefinition(this);
    return moduleDefinition;
  }
 
  public ModuleDefinition removeDefinition(ModuleDefinition moduleDefinition) {
    ModuleDefinition removedDefinition = null;
    if (moduleDefinition == null) throw new IllegalArgumentException("can't remove a null moduleDefinition from a process definition");
    if (definitions != null) {
      removedDefinition = (ModuleDefinition) definitions.remove(moduleDefinition.getClass().getName());
      if (removedDefinition!=null) {
        moduleDefinition.setProcessDefinition(null);
View Full Code Here

Examples of org.jbpm.module.def.ModuleDefinition

    }
    return removedDefinition;
  }

  public ModuleDefinition getDefinition(Class clazz) {
    ModuleDefinition moduleDefinition = null;
    if (definitions != null) {
      moduleDefinition = (ModuleDefinition) definitions.get(clazz.getName());
    }
    return moduleDefinition;
  }
View Full Code Here

Examples of org.lilyproject.runtime.model.ModuleDefinition

    protected LilyRuntimeModel getRuntimeModel() throws Exception {
        File moduleDir = createModule("org.lilyproject.runtime.test.testmodules.springmode");

        LilyRuntimeModel model = new LilyRuntimeModel();

        ModuleDefinition module = new ModuleDefinition("mod", moduleDir, ModuleSourceType.EXPANDED_JAR);
        model.addModule(module);

        return model;
    }
View Full Code Here

Examples of org.springframework.xd.module.ModuleDefinition

    // List is in reverse order
    ModuleDescriptor lastModule = parsed.get(0);
    String lastModuleName = lastModule.getModuleName();
    ModuleType lastModuleType = lastModule.getType();
    ModuleDefinition lastModuleDefinition = moduleRegistry.findDefinition(lastModuleName, lastModuleType);

    Set<String> alreadyPresentOptions = new HashSet<String>(lastModule.getParameters().keySet().size());
    // If we're providing completions for a composed module, some options
    // may already have a value appearing from the definition of the module itself, yet
    // the user *may* want to override them anyways. So pretend they're not there
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.