You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by pe...@apache.org on 2005/07/08 15:40:20 UTC

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh ScpFromMessage.java

peterreilly    2005/07/08 06:40:20

  Modified:    src/main/org/apache/tools/ant/taskdefs/optional/ssh
                        ScpFromMessage.java
  Log:
  javadoc
  
  Revision  Changes    Path
  1.14      +21 -0     ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/ScpFromMessage.java
  
  Index: ScpFromMessage.java
  ===================================================================
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/ScpFromMessage.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- ScpFromMessage.java	12 Jun 2005 17:55:14 -0000	1.13
  +++ ScpFromMessage.java	8 Jul 2005 13:40:20 -0000	1.14
  @@ -28,6 +28,9 @@
   import com.jcraft.jsch.Session;
   import com.jcraft.jsch.Channel;
   
  +/**
  + * A helper object representing an scp download.
  + */
   public class ScpFromMessage extends AbstractSshMessage {
   
       private static final byte LINE_FEED = 0x0a;
  @@ -38,6 +41,12 @@
       private boolean isRecursive = false;
   
       /**
  +     * Constructor for ScpFromMessage.
  +     * @param verbose if true log extra information
  +     * @param session the Scp session to use
  +     * @param aRemoteFile the remote file name
  +     * @param aLocalFile  the local file
  +     * @param recursive   if true use recursion (-r option to scp)
        * @since Ant 1.6.2
        */
       public ScpFromMessage(boolean verbose,
  @@ -51,6 +60,13 @@
           this.isRecursive = recursive;
       }
   
  +    /**
  +     * Constructor for ScpFromMessage.
  +     * @param session the Scp session to use
  +     * @param aRemoteFile the remote file name
  +     * @param aLocalFile  the local file
  +     * @param recursive   if true use recursion (-r option to scp)
  +     */
       public ScpFromMessage(Session session,
                              String aRemoteFile,
                              File aLocalFile,
  @@ -58,6 +74,11 @@
           this(false, session, aRemoteFile, aLocalFile, recursive);
       }
   
  +    /**
  +     * Carry out the transfer.
  +     * @throws IOException on i/o errors
  +     * @throws JSchException on errors detected by scp
  +     */
       public void execute() throws IOException, JSchException {
           String command = "scp -f ";
           if (isRecursive) {
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org