Codota Logo
SignallingTaskHandlerDecorator.<init>
Code IndexAdd Codota to your IDE (free)

How to use
org.jbpm.bpmn2.handler.SignallingTaskHandlerDecorator
constructor

Best Java code snippets using org.jbpm.bpmn2.handler.SignallingTaskHandlerDecorator.<init> (Showing top 8 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Charset c =
  • Codota IconString charsetName;Charset.forName(charsetName)
  • Codota IconCharset.defaultCharset()
  • Codota IconContentType contentType;contentType.getCharset()
  • Smart code suggestions by Codota
}
origin: kiegroup/jbpm

public static void runTestSignallingExceptionServiceTask(KieSession ksession) throws Exception {
  SignallingTaskHandlerDecorator signallingTaskWrapper = new SignallingTaskHandlerDecorator(ServiceTaskHandler.class, eventType);
  signallingTaskWrapper.setWorkItemExceptionParameterName(ExceptionService.exceptionParameterName);
  ksession.getWorkItemManager().registerWorkItemHandler("Service Task", signallingTaskWrapper);
origin: kiegroup/jbpm

SignallingTaskHandlerDecorator signallingTaskWrapper = new SignallingTaskHandlerDecorator(ServiceTaskHandler.class, eventType);
signallingTaskWrapper.setWorkItemExceptionParameterName(ExceptionService.exceptionParameterName);
ksession.getWorkItemManager().registerWorkItemHandler("Service Task", signallingTaskWrapper);
origin: kiegroup/jbpm

@Test
public void testEventSubProcessErrorWithScript() throws Exception {
  KieBase kbase = createKnowledgeBase("BPMN2-EventSubProcessErrorWithScript.bpmn2");
  ksession = createKnowledgeSession(kbase);
  ksession.getWorkItemManager().registerWorkItemHandler("Request Handler", new SignallingTaskHandlerDecorator(ExceptionOnPurposeHandler.class, "Error-90277"));
  ksession.getWorkItemManager().registerWorkItemHandler("Error Handler", new SystemOutWorkItemHandler());
  
  ProcessInstance processInstance = ksession.startProcess("com.sample.process");
  assertProcessInstanceAborted(processInstance);        
  assertEquals("90277", ((WorkflowProcessInstance) processInstance).getOutcome());
}

origin: org.jbpm/jbpm-examples

public static void runExample() {
  // load up the knowledge base
  RuntimeManager manager = createManager();
  KieSession ksession = manager.getRuntimeEngine(null).getKieSession();
  String eventType = "exception-signal";
  SignallingTaskHandlerDecorator signallingTaskWrapper = new SignallingTaskHandlerDecorator(ServiceTaskHandler.class, eventType);
  signallingTaskWrapper.setWorkItemExceptionParameterName(ExceptionService.exceptionParameterName);
  ksession.getWorkItemManager().registerWorkItemHandler("Service Task", signallingTaskWrapper);
  Map<String, Object> params = new HashMap<String, Object>();
  params.put("serviceInputItem", "Input to Original Service");
  ksession.startProcess("ProcessWithExceptionHandlingSignal", params);
  
  manager.close();
}
origin: org.jbpm/jbpm-examples

public static ProcessInstance runExample() {
  // load up the knowledge base
  RuntimeManager manager = createManager();
  KieSession ksession = manager.getRuntimeEngine(null).getKieSession();
  String eventType = "Error-code";
  SignallingTaskHandlerDecorator signallingTaskWrapper 
    = new SignallingTaskHandlerDecorator(ServiceTaskHandler.class, eventType);
  signallingTaskWrapper.setWorkItemExceptionParameterName(ExceptionService.exceptionParameterName);
  ksession.getWorkItemManager().registerWorkItemHandler("Service Task", signallingTaskWrapper);
  Map<String, Object> params = new HashMap<String, Object>();
  params.put("serviceInputItem", "Input to Original Service");
  ProcessInstance processInstance = ksession.startProcess("ProcessWithExceptionHandlingError", params);
  
  manager.close();
  
  return processInstance;
}
origin: org.jbpm/jbpm-bpmn2

public static void runTestSignallingExceptionServiceTask(KieSession ksession) throws Exception {
  SignallingTaskHandlerDecorator signallingTaskWrapper = new SignallingTaskHandlerDecorator(ServiceTaskHandler.class, eventType);
  signallingTaskWrapper.setWorkItemExceptionParameterName(ExceptionService.exceptionParameterName);
  ksession.getWorkItemManager().registerWorkItemHandler("Service Task", signallingTaskWrapper);
origin: org.jbpm/jbpm-bpmn2

SignallingTaskHandlerDecorator signallingTaskWrapper = new SignallingTaskHandlerDecorator(ServiceTaskHandler.class, eventType);
signallingTaskWrapper.setWorkItemExceptionParameterName(ExceptionService.exceptionParameterName);
ksession.getWorkItemManager().registerWorkItemHandler("Service Task", signallingTaskWrapper);
origin: org.jbpm/jbpm-bpmn2

@Test
public void testEventSubProcessErrorWithScript() throws Exception {
  KieBase kbase = createKnowledgeBase("BPMN2-EventSubProcessErrorWithScript.bpmn2");
  ksession = createKnowledgeSession(kbase);
  ksession.getWorkItemManager().registerWorkItemHandler("Request Handler", new SignallingTaskHandlerDecorator(ExceptionOnPurposeHandler.class, "Error-90277"));
  ksession.getWorkItemManager().registerWorkItemHandler("Error Handler", new SystemOutWorkItemHandler());
  
  ProcessInstance processInstance = ksession.startProcess("com.sample.process");
  assertProcessInstanceAborted(processInstance);        
  assertEquals("90277", ((WorkflowProcessInstance) processInstance).getOutcome());
}

org.jbpm.bpmn2.handlerSignallingTaskHandlerDecorator<init>

Javadoc

Constructs an instance that uses the given eventType parameter to signal the process instance using the given KieSession ksession parameter when an instance of the class specified by the originalTaskHandlerClass throws an exception upon WorkItemHandler#executeWorkItem(WorkItem,WorkItemManager)

Popular methods of SignallingTaskHandlerDecorator

  • setWorkItemExceptionParameterName
  • getAndIncreaseExceptionCount

Popular in Java

  • Parsing JSON documents to java classes using gson
  • setRequestProperty (URLConnection)
  • onRequestPermissionsResult (Fragment)
  • getContentResolver (Context)
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • BigDecimal (java.math)
    An immutable arbitrary-precision signed decimal.A value is represented by an arbitrary-precision "un
  • SortedMap (java.util)
    A map that has its keys ordered. The sorting is according to either the natural ordering of its keys
  • ConcurrentHashMap (java.util.concurrent)
    A hash table supporting full concurrency of retrievals and adjustable expected concurrency for updat
  • ReentrantLock (java.util.concurrent.locks)
    A reentrant mutual exclusion Lock with the same basic behavior and semantics as the implicit monitor
  • Loader (org.hibernate.loader)
    Abstract superclass of object loading (and querying) strategies. This class implements useful common
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now