[jboss-cvs] jboss-seam/src/main/org/jboss/seam/annotations ...

Gavin King gavin.king at jboss.com
Sun Jun 17 18:51:00 EDT 2007


  User: gavin   
  Date: 07/06/17 18:51:00

  Modified:    src/main/org/jboss/seam/annotations      BeginTask.java
                        CreateProcess.java EndTask.java ResumeProcess.java
                        StartTask.java
  Log:
  JBSEAM-1094, JBSEAM-256
  
  Revision  Changes    Path
  1.11      +6 -4      jboss-seam/src/main/org/jboss/seam/annotations/BeginTask.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BeginTask.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/annotations/BeginTask.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- BeginTask.java	29 Mar 2007 16:00:49 -0000	1.10
  +++ BeginTask.java	17 Jun 2007 22:51:00 -0000	1.11
  @@ -14,20 +14,22 @@
   import java.lang.annotation.Target;
   
   /**
  - * Marks a method as causing jBPM {@link org.jbpm.taskmgmt.exe.TaskInstance task}
  + * Marks a method as causing a jBPM {@link org.jbpm.taskmgmt.exe.TaskInstance task}
    * to be resumed. The jBPM {@link org.jbpm.context.exe.ContextInstance} 
    * is associated with the BUSINESS_PROCESS scope and the 
    * {@link org.jbpm.taskmgmt.exe.TaskInstance} is associated with a new
  - * conversation.
  + * conversation, unless the annotated method returns a null outcome.
    * <p/>
    * Note that both {@link BeginTask} and {@link StartTask} have effect
    * before invocation of the intercepted method in that they are both
    * about setting up appropriate {@link org.jbpm.context.exe.ContextInstance}
    * for the current {@link org.jboss.seam.contexts.BusinessProcessContext}.
  + * <p/>
    *
  + * @author Steve Ebersole
    */
  - at Target( METHOD )
  - at Retention( RUNTIME )
  + at Target(METHOD)
  + at Retention(RUNTIME)
   @Documented
   public @interface BeginTask
   {
  
  
  
  1.4       +19 -9     jboss-seam/src/main/org/jboss/seam/annotations/CreateProcess.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CreateProcess.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/annotations/CreateProcess.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- CreateProcess.java	20 Dec 2005 14:57:33 -0000	1.3
  +++ CreateProcess.java	17 Jun 2007 22:51:00 -0000	1.4
  @@ -1,9 +1,9 @@
   /*
  - * JBoss, Home of Professional Open Source
  - *
  - * Distributable under LGPL license.
  - * See terms of license at gnu.org.
  - */
  + * JBoss, Home of Professional Open Source
  + *
  + * Distributable under LGPL license.
  + * See terms of license at gnu.org.
  + */
   package org.jboss.seam.annotations;
   
   import static java.lang.annotation.ElementType.METHOD;
  @@ -14,11 +14,14 @@
   import java.lang.annotation.Target;
   
   /**
  - * Marks a method creating a jBPM {@link org.jbpm.graph.exe.ProcessInstance process}
  - * so long as the method does not throw an exception.
  + * Marks a method creating a jBPM 
  + * {@link org.jbpm.graph.exe.ProcessInstance process instance}
  + * unless the method throws an exception or returns a null outcome.
  + * 
  + * @author Steve Ebersole
    */
  - at Target( METHOD )
  - at Retention( RUNTIME )
  + at Target(METHOD)
  + at Retention(RUNTIME)
   @Documented
   public @interface CreateProcess
   {
  @@ -27,4 +30,11 @@
       * to create the {@link org.jbpm.graph.exe.ProcessInstance}
       */
      String definition();
  +   /**
  +    * An EL expression that evaluates to the process 
  +    * business key.
  +    * 
  +    * @return an EL expression or an empty string to indicate a null key
  +    */
  +   String processKey() default "";
   }
  
  
  
  1.6       +3 -1      jboss-seam/src/main/org/jboss/seam/annotations/EndTask.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EndTask.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/annotations/EndTask.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- EndTask.java	15 May 2007 20:39:52 -0000	1.5
  +++ EndTask.java	17 Jun 2007 22:51:00 -0000	1.6
  @@ -14,12 +14,14 @@
   import java.lang.annotation.Target;
   
   /**
  - * Marks a method as causing jBPM {@link org.jbpm.taskmgmt.exe.TaskInstance task}
  + * Marks a method as causing a jBPM 
  + * {@link org.jbpm.taskmgmt.exe.TaskInstance task instance}
    * to be ended. The current conversation also ends. If a list of outcomes 
    * is specified, the task ends only if the outcome is in the list. A null
    * outcome never ends the task.
    *
    * @see org.jbpm.taskmgmt.exe.TaskInstance#end(String)
  + * @author Gavin King
    */
   @Target(METHOD)
   @Retention(RUNTIME)
  
  
  
  1.8       +31 -11    jboss-seam/src/main/org/jboss/seam/annotations/ResumeProcess.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ResumeProcess.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/annotations/ResumeProcess.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ResumeProcess.java	29 Mar 2007 16:00:50 -0000	1.7
  +++ ResumeProcess.java	17 Jun 2007 22:51:00 -0000	1.8
  @@ -1,9 +1,9 @@
   /*
  - * JBoss, Home of Professional Open Source
  - *
  - * Distributable under LGPL license.
  - * See terms of license at gnu.org.
  - */
  + * JBoss, Home of Professional Open Source
  + *
  + * Distributable under LGPL license.
  + * See terms of license at gnu.org.
  + */
   package org.jboss.seam.annotations;
   
   import static java.lang.annotation.ElementType.METHOD;
  @@ -14,24 +14,44 @@
   import java.lang.annotation.Target;
   
   /**
  - * Marks a method as causing jBPM {@link org.jbpm.graph.exe.ProcessInstance process}
  - * to be resumed. Essentially this simply re-associates the jBPM
  - * {@link org.jbpm.context.exe.ContextInstance} with the current
  - * {@link org.jboss.seam.contexts.BusinessProcessContext}.
  + * Marks a method as causing an existing jBPM 
  + * {@link org.jbpm.graph.exe.ProcessInstance process instance}
  + * to be associated with the current conversation, unless the 
  + * annotated method returns a null outcome.
  + * 
  + * @author Steve Ebersole
    */
  - at Target( METHOD )
  - at Retention( RUNTIME )
  + at Target(METHOD)
  + at Retention(RUNTIME)
   @Documented
   public @interface ResumeProcess
   {
      /**
       * The name of the request parameter under which we should locate the
       * the id of process to be resumed.
  +    * (not required for lookup by business key)
  +    * 
  +    * @return a request parameter name
       */
      String processIdParameter() default "";
      /**
       * An EL expression that evaluates to the process id.
  +    * (not required for lookup by business key)
  +    * 
       * @return an EL expression
       */
      String processId() default "#{param.processId}";
  +   /**
  +    * An EL expression that evaluates to the process 
  +    * business key.
  +    * (optional, only required for lookup by business key)
  +    * 
  +    * @return an EL expression
  +    */
  +   String processKey() default "";
  +   /**
  +    * The name of the {@link org.jbpm.graph.def.ProcessDefinition}
  +    * (optional, only required for lookup by business key)
  +    */
  +   String definition() default "";
   }
  
  
  
  1.19      +2 -1      jboss-seam/src/main/org/jboss/seam/annotations/StartTask.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StartTask.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/annotations/StartTask.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- StartTask.java	29 Mar 2007 16:00:50 -0000	1.18
  +++ StartTask.java	17 Jun 2007 22:51:00 -0000	1.19
  @@ -18,7 +18,7 @@
    * to be started. The jBPM {@link org.jbpm.context.exe.ContextInstance} 
    * is associated with the BUSINESS_PROCESS scope and the 
    * {@link org.jbpm.taskmgmt.exe.TaskInstance} is associated with a new
  - * conversation.
  + * conversation, unless the annotated method returns a null outcome.
    * <p/>
    * Note that both {@link BeginTask} and {@link StartTask} have effect
    * before invocation of the intercepted method in that they are both
  @@ -28,6 +28,7 @@
    * as that is the time it actually marks the task as started.
    *
    * @see org.jbpm.taskmgmt.exe.TaskInstance#start()
  + * @author Steve Ebersole
    */
   @Target( METHOD )
   @Retention( RUNTIME )
  
  
  



More information about the jboss-cvs-commits mailing list