[jbpm-commits] JBoss JBPM SVN: r2651 - in projects/gwt-console/trunk: server/src/main/java/org/jboss/bpm/console/server/dao/internal and 1 other directories.

do-not-reply at jboss.org do-not-reply at jboss.org
Wed Oct 29 05:30:14 EDT 2008


Author: heiko.braun at jboss.com
Date: 2008-10-29 05:30:14 -0400 (Wed, 29 Oct 2008)
New Revision: 2651

Added:
   projects/gwt-console/trunk/rpc/src/main/java/org/jboss/bpm/console/client/model/TaskReference.java
Modified:
   projects/gwt-console/trunk/server/src/main/java/org/jboss/bpm/console/server/dao/internal/Transform.java
   projects/gwt-console/trunk/war/src/main/java/org/jboss/bpm/console/client/model/DTOParser.java
Log:
For some reason TaskReference was missing from previous commit

Added: projects/gwt-console/trunk/rpc/src/main/java/org/jboss/bpm/console/client/model/TaskReference.java
===================================================================
--- projects/gwt-console/trunk/rpc/src/main/java/org/jboss/bpm/console/client/model/TaskReference.java	                        (rev 0)
+++ projects/gwt-console/trunk/rpc/src/main/java/org/jboss/bpm/console/client/model/TaskReference.java	2008-10-29 09:30:14 UTC (rev 2651)
@@ -0,0 +1,135 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.bpm.console.client.model;
+
+import javax.xml.bind.annotation.XmlRootElement;
+import java.util.List;
+import java.util.ArrayList;
+
+/**
+ * @author Heiko.Braun <heiko.braun at jboss.com>
+ */
+ at XmlRootElement(name = "taskReference")
+public class TaskReference
+{
+   private long taskId;
+   private long tokenId;
+   private long processInstanceId;
+
+   private String taskName;
+   private String actorName;
+
+   private boolean isBlocking;
+   private boolean isSignalling = true;
+
+   private List<String> transitionNames = new ArrayList<String>();
+
+   public TaskReference()
+   {
+   }
+
+   public TaskReference(long taskId, long tokenId, long processInstanceId, String taskName, String actorName, boolean blocking, boolean signalling)
+   {
+      this.taskId = taskId;
+      this.tokenId = tokenId;
+      this.processInstanceId = processInstanceId;
+      this.taskName = taskName;
+      this.actorName = actorName;
+      isBlocking = blocking;
+      isSignalling = signalling;
+   }
+
+   public long getTaskId()
+   {
+      return taskId;
+   }
+
+   public void setTaskId(long taskId)
+   {
+      this.taskId = taskId;
+   }
+
+   public long getTokenId()
+   {
+      return tokenId;
+   }
+
+   public void setTokenId(long tokenId)
+   {
+      this.tokenId = tokenId;
+   }
+
+   public long getProcessInstanceId()
+   {
+      return processInstanceId;
+   }
+
+   public void setProcessInstanceId(long processInstanceId)
+   {
+      this.processInstanceId = processInstanceId;
+   }
+
+   public String getTaskName()
+   {
+      return taskName;
+   }
+
+   public void setTaskName(String taskName)
+   {
+      this.taskName = taskName;
+   }
+
+   public String getActorName()
+   {
+      return actorName;
+   }
+
+   public void setActorName(String actorName)
+   {
+      this.actorName = actorName;
+   }
+
+   public boolean isBlocking()
+   {
+      return isBlocking;
+   }
+
+   public void setBlocking(boolean blocking)
+   {
+      isBlocking = blocking;
+   }
+
+   public boolean isSignalling()
+   {
+      return isSignalling;
+   }
+
+   public void setSignalling(boolean signalling)
+   {
+      isSignalling = signalling;
+   }
+
+   public List<String> getTransitionNames()
+   {
+      return transitionNames;
+   }
+}

Modified: projects/gwt-console/trunk/server/src/main/java/org/jboss/bpm/console/server/dao/internal/Transform.java
===================================================================
--- projects/gwt-console/trunk/server/src/main/java/org/jboss/bpm/console/server/dao/internal/Transform.java	2008-10-29 09:22:50 UTC (rev 2650)
+++ projects/gwt-console/trunk/server/src/main/java/org/jboss/bpm/console/server/dao/internal/Transform.java	2008-10-29 09:30:14 UTC (rev 2651)
@@ -73,14 +73,11 @@
    public static TaskReference taskInstance(org.jbpm.taskmgmt.exe.TaskInstance t0)
    {
       TaskReference taskRef = new TaskReference(
-         t0.getId(),
-            t0.getName(),
-            t0.getDescription(),
-            t0.isSignalling(),
-            t0.isBlocking(),
+            t0.getId(),
             t0.getToken().getId(),
             t0.getProcessInstance().getId(),
-            t0.getActorId()
+            t0.getName(), t0.getActorId(),
+            t0.isBlocking(), t0.isSignalling()            
       );
 
       List<Transition> transitionList =  (List<Transition>)

Modified: projects/gwt-console/trunk/war/src/main/java/org/jboss/bpm/console/client/model/DTOParser.java
===================================================================
--- projects/gwt-console/trunk/war/src/main/java/org/jboss/bpm/console/client/model/DTOParser.java	2008-10-29 09:22:50 UTC (rev 2650)
+++ projects/gwt-console/trunk/war/src/main/java/org/jboss/bpm/console/client/model/DTOParser.java	2008-10-29 09:30:14 UTC (rev 2651)
@@ -82,10 +82,9 @@
          boolean isSignalling = JSONWalk.on(item).next("isSignalling").asBool();
                                                         
          TaskReference ref = new TaskReference(
-               id, name, "",  // TODO: description, deal with optional values in JSONWalk
-               isSignalling, isBlocking,
-               tokenId, instanceId,
-               actor
+               id, tokenId, instanceId,
+               name, actor,
+               isSignalling, isBlocking
          );
 
          if(isSignalling)




More information about the jbpm-commits mailing list