conor       2003/02/03 06:07:00

  Modified:    src/main/org/apache/tools/ant/taskdefs/optional/pvcs
                        Pvcs.java
  Log:
  Added a revision attribute, a synonym for label
  
  PR:   13847
  Submitted By: Steven Newton
  
  Revision  Changes    Path
  1.21      +27 -0     
jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/pvcs/Pvcs.java
  
  Index: Pvcs.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/pvcs/Pvcs.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -w -u -r1.20 -r1.21
  --- Pvcs.java 17 Jan 2003 02:14:39 -0000      1.20
  +++ Pvcs.java 3 Feb 2003 14:07:00 -0000       1.21
  @@ -99,6 +99,11 @@
    * update those files that have a modification time (in PVCS) that is newer
    * than the existing workfile.
    *
  + * <b>25-10-2002</b> <p>Added a revision attribute that currently is a
  + * synonym for label, but in a future release the behavior of the label
  + * attribute will change to use the -v option of GET.  See bug #13847 for
  + * discussion.
  + *
    * @author <a href="mailto:[EMAIL PROTECTED]">Thomas Christensen</a>
    * @author <a href="mailto:[EMAIL PROTECTED]">Don Jeffery</a>
    * @author <a href="mailto:[EMAIL PROTECTED]">Steven E. Newton</a>
  @@ -112,6 +117,7 @@
       private String force;
       private String promotiongroup;
       private String label;
  +    private String revision;
       private boolean ignorerc;
       private boolean updateOnly;
       private String filenameFormat;
  @@ -262,6 +268,11 @@
               } else {
                   if (getLabel() != null) {
                       commandLine.createArgument().setValue("-r" + getLabel());
  +                } else {
  +                    if (getRevision() != null) {
  +                        commandLine.createArgument().setValue("-r"
  +                            + getRevision());
  +                    }
                   }
               }
   
  @@ -570,6 +581,22 @@
        */
       public void setLabel(String l) {
           label = l;
  +    }
  +
  +    /**
  +     * Get value of revision
  +     * @return String
  +     */
  +    public String getRevision() {
  +        return revision;
  +    }
  +
  +    /**
  +     * Only files with this revision are extract; optional.
  +     * @param r String
  +     */
  +    public void setRevision(String r) {
  +        revision = r;
       }
   
       /**
  
  
  

Reply via email to