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

How to use
org.jbpm.process.workitem.exec.ExecWorkItemHandler
constructor

Best Java code snippets using org.jbpm.process.workitem.exec.ExecWorkItemHandler.<init> (Showing top 4 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: org.jbpm.contrib/exec-workitem

  @Test
  public void testExecCommandInvalidParam() throws Exception {
    TestWorkItemManager manager = new TestWorkItemManager();
    WorkItemImpl workItem = new WorkItemImpl();

    ExecWorkItemHandler handler = new ExecWorkItemHandler();
    handler.setLogThrownException(true);

    handler.executeWorkItem(workItem,
                manager);

    assertNotNull(manager.getResults());
    assertEquals(0,
           manager.getResults().size());
  }
}
origin: org.jbpm.contrib/exec-workitem

@Test
public void testExecCommandWithArguments() throws Exception {
  TestWorkItemManager manager = new TestWorkItemManager();
  WorkItemImpl workItem = new WorkItemImpl();
  workItem.setParameter("Command",
             "java");
  List<String> argumentList = new ArrayList<>();
  argumentList.add("-version");
  workItem.setParameter("Arguments",
             argumentList);
  ExecWorkItemHandler handler = new ExecWorkItemHandler();
  handler.setLogThrownException(true);
  handler.executeWorkItem(workItem,
              manager);
  assertNotNull(manager.getResults());
  assertEquals(1,
         manager.getResults().size());
  assertTrue(manager.getResults().containsKey(workItem.getId()));
  Map<String, Object> results = ((TestWorkItemManager) manager).getResults(workItem.getId());
  String result = (String) results.get(ExecWorkItemHandler.RESULT);
  assertEquals("[java, -version]",
         handler.getParsedCommandStr());
  assertNotNull(result);
  assertTrue(result.contains("java version") || result.contains("jdk version"));
}
origin: org.jbpm.contrib/exec-workitem

@Test
public void testExecCommand() throws Exception {
  TestWorkItemManager manager = new TestWorkItemManager();
  WorkItemImpl workItem = new WorkItemImpl();
  workItem.setParameter("Command",
             "java -version");
  ExecWorkItemHandler handler = new ExecWorkItemHandler();
  handler.setLogThrownException(true);
  handler.executeWorkItem(workItem,
              manager);
  assertNotNull(manager.getResults());
  assertEquals(1,
         manager.getResults().size());
  assertTrue(manager.getResults().containsKey(workItem.getId()));
  Map<String, Object> results = ((TestWorkItemManager) manager).getResults(workItem.getId());
  String result = (String) results.get(ExecWorkItemHandler.RESULT);
  assertEquals("[java, -version]",
         handler.getParsedCommandStr());
  assertNotNull(result);
  assertTrue(result.contains("java version") || result.contains("jdk version"));
}
origin: org.jbpm/jbpm-workitems-exec

  @Test
  public void testExecCommand() throws Exception {
    TestWorkItemManager manager = new TestWorkItemManager();
    WorkItemImpl workItem = new WorkItemImpl();
    workItem.setParameter("Command",
               "java -version");
    ExecWorkItemHandler handler = new ExecWorkItemHandler();
    handler.setLogThrownException(true);

    handler.executeWorkItem(workItem,
                manager);

    assertNotNull(manager.getResults());
    assertEquals(1,
           manager.getResults().size());
    assertTrue(manager.getResults().containsKey(workItem.getId()));
  }
}
org.jbpm.process.workitem.execExecWorkItemHandler<init>

Popular methods of ExecWorkItemHandler

  • executeWorkItem
  • setLogThrownException
  • getParsedCommandStr
  • handleException

Popular in Java

  • Finding current android device location
  • scheduleAtFixedRate (ScheduledExecutorService)
  • getSupportFragmentManager (FragmentActivity)
    Return the FragmentManager for interacting with fragments associated with this activity.
  • getContentResolver (Context)
  • Table (com.google.common.collect)
    A collection that associates an ordered pair of keys, called a row key and a column key, with a sing
  • FlowLayout (java.awt)
    A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • Annotation (javassist.bytecode.annotation)
    The annotation structure.An instance of this class is returned bygetAnnotations() in AnnotationsAttr
  • DateTimeFormat (org.joda.time.format)
    Factory that creates instances of DateTimeFormatter from patterns and styles. Datetime formatting i
  • LoggerFactory (org.slf4j)
    The LoggerFactory is a utility class producing Loggers for various logging APIs, most notably for lo
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