congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
WorkflowProcess.getMetaData
Code IndexAdd Tabnine to your IDE (free)

How to use
getMetaData
method
in
org.kie.api.definition.process.WorkflowProcess

Best Java code snippets using org.kie.api.definition.process.WorkflowProcess.getMetaData (Showing top 8 results out of 315)

origin: kiegroup/jbpm

protected void visitHeader(WorkflowProcess process, StringBuilder xmlDump, int metaDataType) {
  Map<String, Object> metaData = getMetaData(process.getMetaData());
  Set<String> imports = ((org.jbpm.process.core.Process) process).getImports();
  Map<String, String> globals = ((org.jbpm.process.core.Process) process).getGlobals();
  if ((imports != null && !imports.isEmpty()) || (globals != null && globals.size() > 0) || !metaData.isEmpty()) {
    xmlDump.append("    <extensionElements>" + EOL);
    if (imports != null) {
      for (String s: imports) {
        xmlDump.append("     <tns:import name=\"" + s + "\" />" + EOL);
      }
    }
    if (globals != null) {
      for (Map.Entry<String, String> global: globals.entrySet()) {
        xmlDump.append("     <tns:global identifier=\"" + global.getKey() + "\" type=\"" + global.getValue() + "\" />" + EOL);
      }
    }
    writeMetaData(getMetaData(process.getMetaData()), xmlDump);
    xmlDump.append("    </extensionElements>" + EOL);
  }
  // TODO: function imports
  // TODO: exception handlers
  VariableScope variableScope = (VariableScope)
    ((org.jbpm.process.core.Process) process).getDefaultContext(VariableScope.VARIABLE_SCOPE);
  if (variableScope != null) {
    visitVariables(variableScope.getVariables(), xmlDump);
  }
  visitLanes(process, xmlDump);
}
origin: kiegroup/jbpm

Integer routerLayout = (Integer) process.getMetaData().get("routerLayout");
if (routerLayout != null && routerLayout != 0) {
  xmlDump.append("routerLayout=\"" + routerLayout + "\" ");
origin: kiegroup/jbpm

protected void visitProcess(WorkflowProcess process, StringBuilder xmlDump, int metaDataType) {
  String targetNamespace = (String) process.getMetaData().get("TargetNamespace");
  if (targetNamespace == null) {
    targetNamespace = "http://www.jboss.org/drools";
    ((org.jbpm.process.core.Process) process).getDefaultContext(VariableScope.VARIABLE_SCOPE);
  Set<String> dumpedItemDefs = new HashSet<String>();
  Map<String, ItemDefinition> itemDefs = (Map<String, ItemDefinition>) process.getMetaData().get("ItemDefinitions");
  Definitions def = (Definitions) process.getMetaData().get("Definitions");
  visitErrors(def, xmlDump);
  visitConnections(process.getNodes(), xmlDump, metaDataType);
  List<Association> associations = (List<Association>) process.getMetaData().get(ProcessHandler.ASSOCIATIONS);
  if( associations != null ) {
    for (Association association : associations ) {
origin: kiegroup/jbpm

private void registerExternalEventNodeListeners() {
  for (Node node : getWorkflowProcess().getNodes()) {
    if (node instanceof EventNode) {
      if ("external".equals(((EventNode) node).getScope())) {
        addEventListener(((EventNode) node).getType(), EMPTY_EVENT_LISTENER, true);
      }
    } else if (node instanceof EventSubProcessNode) {
      List<String> events = ((EventSubProcessNode) node).getEvents();
      for (String type : events) {
        addEventListener(type, EMPTY_EVENT_LISTENER, true);
        if (isVariableExpression(type)) {
          addEventListener(resolveVariable(type), EMPTY_EVENT_LISTENER, true);
        }
      }
    }  else if (node instanceof DynamicNode) {
      if (((DynamicNode) node).getActivationEventName() != null) {
      
        addEventListener(((DynamicNode) node).getActivationEventName(), EMPTY_EVENT_LISTENER, true);
      }
    }
  }
  if( getWorkflowProcess().getMetaData().containsKey("Compensation") ) {
    addEventListener("Compensation", new CompensationEventListener(this), true);
  }
}
origin: org.jbpm/jbpm-bpmn2

protected void visitHeader(WorkflowProcess process, StringBuilder xmlDump, int metaDataType) {
  Map<String, Object> metaData = getMetaData(process.getMetaData());
  Set<String> imports = ((org.jbpm.process.core.Process) process).getImports();
  Map<String, String> globals = ((org.jbpm.process.core.Process) process).getGlobals();
  if ((imports != null && !imports.isEmpty()) || (globals != null && globals.size() > 0) || !metaData.isEmpty()) {
    xmlDump.append("    <extensionElements>" + EOL);
    if (imports != null) {
      for (String s: imports) {
        xmlDump.append("     <tns:import name=\"" + s + "\" />" + EOL);
      }
    }
    if (globals != null) {
      for (Map.Entry<String, String> global: globals.entrySet()) {
        xmlDump.append("     <tns:global identifier=\"" + global.getKey() + "\" type=\"" + global.getValue() + "\" />" + EOL);
      }
    }
    writeMetaData(getMetaData(process.getMetaData()), xmlDump);
    xmlDump.append("    </extensionElements>" + EOL);
  }
  // TODO: function imports
  // TODO: exception handlers
  VariableScope variableScope = (VariableScope)
    ((org.jbpm.process.core.Process) process).getDefaultContext(VariableScope.VARIABLE_SCOPE);
  if (variableScope != null) {
    visitVariables(variableScope.getVariables(), xmlDump);
  }
  visitLanes(process, xmlDump);
}
origin: org.jbpm/jbpm-flow-builder

Integer routerLayout = (Integer) process.getMetaData().get("routerLayout");
if (routerLayout != null && routerLayout != 0) {
  xmlDump.append("routerLayout=\"" + routerLayout + "\" ");
origin: org.jbpm/jbpm-bpmn2

protected void visitProcess(WorkflowProcess process, StringBuilder xmlDump, int metaDataType) {
  String targetNamespace = (String) process.getMetaData().get("TargetNamespace");
  if (targetNamespace == null) {
    targetNamespace = "http://www.jboss.org/drools";
    ((org.jbpm.process.core.Process) process).getDefaultContext(VariableScope.VARIABLE_SCOPE);
  Set<String> dumpedItemDefs = new HashSet<String>();
  Map<String, ItemDefinition> itemDefs = (Map<String, ItemDefinition>) process.getMetaData().get("ItemDefinitions");
  Definitions def = (Definitions) process.getMetaData().get("Definitions");
  visitErrors(def, xmlDump);
  visitConnections(process.getNodes(), xmlDump, metaDataType);
  List<Association> associations = (List<Association>) process.getMetaData().get(ProcessHandler.ASSOCIATIONS);
  if( associations != null ) {
    for (Association association : associations ) {
origin: org.jbpm/jbpm-flow

private void registerExternalEventNodeListeners() {
  for (Node node : getWorkflowProcess().getNodes()) {
    if (node instanceof EventNode) {
      if ("external".equals(((EventNode) node).getScope())) {
        addEventListener(((EventNode) node).getType(), EMPTY_EVENT_LISTENER, true);
      }
    } else if (node instanceof EventSubProcessNode) {
      List<String> events = ((EventSubProcessNode) node).getEvents();
      for (String type : events) {
        addEventListener(type, EMPTY_EVENT_LISTENER, true);
        if (isVariableExpression(type)) {
          addEventListener(resolveVariable(type), EMPTY_EVENT_LISTENER, true);
        }
      }
    }  else if (node instanceof DynamicNode) {
      if (((DynamicNode) node).getActivationEventName() != null) {
      
        addEventListener(((DynamicNode) node).getActivationEventName(), EMPTY_EVENT_LISTENER, true);
      }
    }
  }
  if( getWorkflowProcess().getMetaData().containsKey("Compensation") ) {
    addEventListener("Compensation", new CompensationEventListener(this), true);
  }
}
org.kie.api.definition.processWorkflowProcessgetMetaData

Popular methods of WorkflowProcess

  • getName
  • getNodes
  • getPackageName
  • getVersion
  • getId
  • getNode

Popular in Java

  • Reactive rest calls using spring rest template
  • scheduleAtFixedRate (Timer)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • setRequestProperty (URLConnection)
  • FileReader (java.io)
    A specialized Reader that reads from a file in the file system. All read requests made by calling me
  • String (java.lang)
  • HttpURLConnection (java.net)
    An URLConnection for HTTP (RFC 2616 [http://tools.ietf.org/html/rfc2616]) used to send and receive d
  • Manifest (java.util.jar)
    The Manifest class is used to obtain attribute information for a JarFile and its entries.
  • Options (org.apache.commons.cli)
    Main entry-point into the library. Options represents a collection of Option objects, which describ
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Top 17 PhpStorm Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now