Tabnine Logo
TaskReassignmentList
Code IndexAdd Tabnine to your IDE (free)

How to use
TaskReassignmentList
in
org.kie.server.api.model.admin

Best Java code snippets using org.kie.server.api.model.admin.TaskReassignmentList (Showing top 2 results out of 315)

origin: org.kie.server/kie-server-services-jbpm

public TaskReassignmentList getTaskReassignments(String containerId, Number taskId, boolean activeOnly) {
  containerId = context.getContainerId(containerId, new ByTaskIdContainerLocator(taskId.longValue()));
  Collection<TaskReassignment> reassignments = userTaskAdminService.getTaskReassignments(containerId, taskId.longValue(), activeOnly);
  List<org.kie.server.api.model.admin.TaskReassignment> converted = reassignments.stream().map(r -> org.kie.server.api.model.admin.TaskReassignment.builder().id(r.getId()).active(r.isActive()).name(r.getName()).reassignAt(r.getDate()).users(r.getPotentialOwners().stream().filter(oe -> oe instanceof User).map(oe -> oe.getId()).collect(toList())).groups(r.getPotentialOwners().stream().filter(oe -> oe instanceof Group).map(oe -> oe.getId()).collect(toList())).build()).collect(toList());
  return new TaskReassignmentList(converted);
}
origin: org.kie.server/kie-server-client

@Override
public List<TaskReassignment> getTaskReassignments(String containerId, Long taskId, boolean activeOnly) {
  TaskReassignmentList result = null;
  if( config.isRest() ) {
    Map<String, Object> valuesMap = new HashMap<String, Object>();
    valuesMap.put(CONTAINER_ID, containerId);
    valuesMap.put(TASK_INSTANCE_ID, taskId);
    String queryString = "?activeOnly=" + activeOnly;
    result = makeHttpGetRequestAndCreateCustomResponse(
        build(loadBalancer.getUrl(), ADMIN_TASK_URI + "/" + TASK_INSTANCE_REASSIGNMENTS_URI, valuesMap) + queryString, TaskReassignmentList.class);
  } else {
    CommandScript script = new CommandScript( Collections.singletonList( (KieServerCommand)
        new DescriptorCommand( "UserTaskAdminService", "getTaskReassignments", new Object[]{containerId, taskId, activeOnly}) ) );
    ServiceResponse<TaskReassignmentList> response = (ServiceResponse<TaskReassignmentList>) executeJmsCommand( script, DescriptorCommand.class.getName(), "BPM" ).getResponses().get(0);
    throwExceptionOnFailure(response);
    if (shouldReturnWithNullResponse(response)) {
      return null;
    }
    result = response.getResult();
  }
  if (result != null && result.getItems() != null) {
    return result.getItems();
  }
  return Collections.emptyList();
}
org.kie.server.api.model.adminTaskReassignmentList

Most used methods

  • <init>
  • getItems

Popular in Java

  • Reactive rest calls using spring rest template
  • startActivity (Activity)
  • onRequestPermissionsResult (Fragment)
  • addToBackStack (FragmentTransaction)
  • FileNotFoundException (java.io)
    Thrown when a file specified by a program cannot be found.
  • ArrayList (java.util)
    ArrayList is an implementation of List, backed by an array. All optional operations including adding
  • SSLHandshakeException (javax.net.ssl)
    The exception that is thrown when a handshake could not be completed successfully.
  • Filter (javax.servlet)
    A filter is an object that performs filtering tasks on either the request to a resource (a servlet o
  • JFrame (javax.swing)
  • Response (javax.ws.rs.core)
    Defines the contract between a returned instance and the runtime when an application needs to provid
  • Top plugins for Android Studio
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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