@Test public void testBuildTaskEventSummary() { final TaskEventInstance event = TaskEventInstance.builder(). id(1l). taskId(2l). type("UPDATED"). user("admin"). date(new Date()). workItemId(3l). message("message").build(); final TaskEventSummary summary = remoteTaskService.build(event); assertNotNull(summary); assertEquals(event.getId(), summary.getEventId()); assertEquals(event.getTaskId(), summary.getTaskId()); assertEquals(event.getType(), summary.getType()); assertEquals(event.getUserId(), summary.getUserId()); assertEquals(event.getLogTime(), summary.getLogTime()); assertEquals(event.getWorkItemId(), summary.getWorkItemId()); assertEquals(event.getMessage(), summary.getMessage()); }
protected CommentSummary build(TaskComment comment) { CommentSummary summary = new CommentSummary( comment.getId(), comment.getText(), comment.getAddedBy(), comment.getAddedAt() ); return summary; }
RemoteTaskServiceImpl extends AbstractKieServerService implements TaskService { protected CommentSummary build(TaskComment comment) { CommentSummary summary = new CommentSummary( comment.getId(), comment.getText(), comment.getAddedBy(), comment.getAddedAt() ); return summary; } }
RemoteTaskServiceImpl extends AbstractKieServerService implements TaskService { protected CommentSummary build(TaskComment comment) { CommentSummary summary = new CommentSummary( comment.getId(), comment.getText(), comment.getAddedBy(), comment.getAddedAt() ); return summary; }  }
RemoteTaskServiceImpl extends AbstractKieServerService implements TaskService { protected CommentSummary build(TaskComment comment) { CommentSummary summary = new CommentSummary( comment.getId(), comment.getText(), comment.getAddedBy(), comment.getAddedAt() ); return summary; }  @Override TaskSummary getTask(String serverTemplateId, String containerId, Long taskId); @Override TaskSummary getTaskWithSLA(String serverTemplateId, String containerId, Long taskId); @Override void updateTask(String serverTemplateId,
                           String containerId,
                           Long taskId,
                           Integer priority,
                           String description,
                           Date dueDate); @Override void claimTask(String serverTemplateId,
                          String containerId,
                          Long taskId); @Override void releaseTask(String serverTemplateId,
                            String containerId,
                            Long taskId); @Override void startTask(String serverTemplateId,
                          String containerId,
                          Long taskId); @Override void completeTask(final String serverTemplateId,
                             final String containerId,
                             final Long taskId,
                             final Map<String, Object> output); @Override void resumeTask(String serverTemplateId,
                           String containerId,
                           Long taskId); @Override void suspendTask(String serverTemplateId,
                            String containerId,
                            Long taskId); @Override void saveTaskContent(String serverTemplateId,
                                String containerId,
                                Long taskId,
                                Map<String, Object> output); @Override void addTaskComment(String serverTemplateId,
                               String containerId,
                               Long taskId,
                               String text,
                               Date addedOn); @Override void deleteTaskComment(String serverTemplateId,
                                  String containerId,
                                  Long taskId,
                                  Long commentId); @Override List<CommentSummary> getTaskComments(String serverTemplateId,
                                                String containerId,
                                                Long taskId); @Override List<TaskEventSummary> getTaskEvents(String serverTemplateId,
                                                String containerId,
                                                Long taskId,
                                                Integer page,
                                                Integer pageSize); @Override void delegate(String serverTemplateId, String containerId, Long taskId, String entity); @Override List<TaskAssignmentSummary> delegateTasks(String serverTemplateId, List<TaskKey> tasksKeyToReassign, String entity); @Override void forward(String serverTemplateId,
                        String containerId,
                        Long taskId,
                        String entity); @Override TaskAssignmentSummary getTaskAssignmentDetails(String serverTemplateId,
                                                          String containerId,
                                                          Long taskId); @Override void executeReminderForTask(String serverTemplateId,
                                       String containerId,
                                       Long taskId,
                                       String fromUser); @Override TaskSummary getTaskByWorkItemId(String serverTemplateId,
                                           String containerId,
                                           Long workItemId); }
RemoteTaskServiceImpl extends AbstractKieServerService implements TaskService { protected CommentSummary build(TaskComment comment) { CommentSummary summary = new CommentSummary( comment.getId(), comment.getText(), comment.getAddedBy(), comment.getAddedAt() ); return summary; }  @Override TaskSummary getTask(String serverTemplateId, String containerId, Long taskId); @Override TaskSummary getTaskWithSLA(String serverTemplateId, String containerId, Long taskId); @Override void updateTask(String serverTemplateId,
                           String containerId,
                           Long taskId,
                           Integer priority,
                           String description,
                           Date dueDate); @Override void claimTask(String serverTemplateId,
                          String containerId,
                          Long taskId); @Override void releaseTask(String serverTemplateId,
                            String containerId,
                            Long taskId); @Override void startTask(String serverTemplateId,
                          String containerId,
                          Long taskId); @Override void completeTask(final String serverTemplateId,
                             final String containerId,
                             final Long taskId,
                             final Map<String, Object> output); @Override void resumeTask(String serverTemplateId,
                           String containerId,
                           Long taskId); @Override void suspendTask(String serverTemplateId,
                            String containerId,
                            Long taskId); @Override void saveTaskContent(String serverTemplateId,
                                String containerId,
                                Long taskId,
                                Map<String, Object> output); @Override void addTaskComment(String serverTemplateId,
                               String containerId,
                               Long taskId,
                               String text,
                               Date addedOn); @Override void deleteTaskComment(String serverTemplateId,
                                  String containerId,
                                  Long taskId,
                                  Long commentId); @Override List<CommentSummary> getTaskComments(String serverTemplateId,
                                                String containerId,
                                                Long taskId); @Override List<TaskEventSummary> getTaskEvents(String serverTemplateId,
                                                String containerId,
                                                Long taskId,
                                                Integer page,
                                                Integer pageSize); @Override void delegate(String serverTemplateId, String containerId, Long taskId, String entity); @Override List<TaskAssignmentSummary> delegateTasks(String serverTemplateId, List<TaskKey> tasksKeyToReassign, String entity); @Override void forward(String serverTemplateId,
                        String containerId,
                        Long taskId,
                        String entity); @Override TaskAssignmentSummary getTaskAssignmentDetails(String serverTemplateId,
                                                          String containerId,
                                                          Long taskId); @Override void executeReminderForTask(String serverTemplateId,
                                       String containerId,
                                       Long taskId,
                                       String fromUser); @Override TaskSummary getTaskByWorkItemId(String serverTemplateId,
                                           String containerId,
                                           Long workItemId); static int NOT_FOUND_ERROR_CODE; }