本文整理匯總了Java中org.kie.services.client.api.command.RemoteRuntimeEngine類的典型用法代碼示例。如果您正苦於以下問題:Java RemoteRuntimeEngine類的具體用法?Java RemoteRuntimeEngine怎麽用?Java RemoteRuntimeEngine使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
RemoteRuntimeEngine類屬於org.kie.services.client.api.command包,在下文中一共展示了RemoteRuntimeEngine類的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: getTasks
import org.kie.services.client.api.command.RemoteRuntimeEngine; //導入依賴的package包/類
private void getTasks() {
RemoteRuntimeEngine engine = remoteRestSessionFactory.newRuntimeEngine();
// The TaskService class allows we to access the server tasks
TaskService taskService = engine.getTaskService();
String USER = "erics";
List<TaskSummary> tasks = taskService.getTasksAssignedAsPotentialOwner(USER, "en-US");
if (tasks.size() == 0) {
System.out.printf("No tasks for user \"%s\" as owner...\n", USER);
} else {
System.out.printf("Tasks where user \"%s\" is a an owner...\n", USER);
for (TaskSummary t : tasks) {
System.out.printf("ID: %d\n", t.getId());
System.out.printf("Name: %s\n", t.getName());
System.out.printf("Actual Owner: %s\n", t.getActualOwner());
System.out.printf("Created by: %s\n", t.getCreatedBy());
System.out.printf("Created on: %s\n", t.getCreatedOn());
System.out.printf("Status: %s\n", t.getStatus());
System.out.printf("Description: %s\n", t.getDescription());
// LoanApplication la = (LoanApplication)t.getClass();
System.out.println("---------------");
Task userTask = taskService.getTaskById(t.getId());
TaskData taskData = userTask.getTaskData();
Map<String, Object> m = taskService.getTaskContent(t.getId());
StringBuilder sb = new StringBuilder();
Iterator<Entry<String, Object>> iter = m.entrySet().iterator();
while (iter.hasNext()) {
Entry<String, Object> entry = iter.next();
sb.append(entry.getKey());
sb.append('=').append('"');
sb.append(entry.getValue());
sb.append('"');
if (iter.hasNext()) {
sb.append(',').append(' ');
}
}
System.out.println(sb);
}
}
}
示例2: isRemote
import org.kie.services.client.api.command.RemoteRuntimeEngine; //導入依賴的package包/類
/** If the wrapped KieSession is remote.
*
* @return if so */
public boolean isRemote() {
return _wrapped instanceof RemoteRuntimeEngine;
}
示例3: isRemote
import org.kie.services.client.api.command.RemoteRuntimeEngine; //導入依賴的package包/類
/**
* If the wrapped KieSession is remote.
* @return if so
*/
public boolean isRemote() {
return _wrapped instanceof RemoteRuntimeEngine;
}