com.glub.secureftp.bean
Class FTP

java.lang.Object
  extended by com.glub.secureftp.bean.FTP
Direct Known Subclasses:
SSLFTP

public class FTP
extends Object

The FTP class is responsible for handling the basic operations of the File Transfer Protocol.

Since:
2.5.10
Version:
$Revision: 48 $, $Date: 2010-12-23 22:24:36 -0800 (Thu, 23 Dec 2010) $

Field Summary
static short ACTIVE_CONNECTION_TYPE
          Used to set the data connection type to active.
static short ASCII_TRANSFER_MODE
          Used to set the data transfer mode to ascii.
static short AUTO_TRANSFER_MODE
          Used to set the data transfer mode to auto.
static short BINARY_TRANSFER_MODE
          Used to set the data transfer mode to binary; also known as image.
protected  FTPCommand command
          This handles the FTP commands.
static short EBCDIC_TRANSFER_MODE
          Used to set the data transfer mode to ebcdic.
protected  boolean isConnected
          If we are connected, this is true.
protected  boolean isLoggedIn
          If we are logged in, this is true.
protected  int lastPortFromRange
          These values are used if an active port range is specifed
protected  int maxPortInRange
           
protected  int minPortInRange
           
protected  boolean modeZEnabled
          If mode z is enabled, this is true.
static short PASSIVE_CONNECTION_TYPE
          Used to set the data connection type to passive.
static short PASV_CONNECTION_TYPE
          Used to set the data connection type to passive.
protected  OutputStream recvCmdStream
          This stream is used to print the responses returned from the server.
protected  OutputStream sendCmdStream
          This stream is used to print the commands sent to the server.
 
Constructor Summary
FTP(HostInfo hostInfo)
          Create a new FTP object without response notification.
FTP(HostInfo hostInfo, OutputStream sendCmdStream, OutputStream recvCmdStream)
          Create a new FTP object with response notification.
FTP(String host, int port)
          Create a new FTP object without response notification.
FTP(String host, int port, OutputStream sendCmdStream, OutputStream recvCmdStream)
          Create a new FTP object with response notification.
 
Method Summary
 void abort(FTPAbortableTransfer abort)
          Abort a data transfer from the FTP server.
protected  void aboutToTransferData()
          Called before data transfers begin.
 void append(File file, RemoteFile appendTo)
          Append to a file on the FTP server.
 void append(File file, RemoteFile appendTo, FTPAbortableTransfer abort)
          Append to a file on the FTP server with the ability to abort the data transfer.
 void append(File file, RemoteFile appendTo, Progress progress)
          Append to a file on the FTP server with progress information.
 void append(File file, RemoteFile appendTo, Progress progress, FTPAbortableTransfer abort)
          Append to a file on the FTP server with progress information and the ability to abort the data transfer.
 void append(File file, String appendTo)
          Append to a file on the FTP server.
 void append(File file, String appendTo, FTPAbortableTransfer abort)
          Append to a file on the FTP server with the ability to abort the data transfer.
 void append(File file, String appendTo, Progress progress)
          Append to a file on the FTP server with progress information.
 void append(File file, String appendTo, Progress progress, FTPAbortableTransfer abort)
          Append to a file on the FTP server with progress information and the ability to abort the data transfer.
 void append(InputStream inputStream, long localFileSize, RemoteFile appendTo, Progress progress)
          Append to a file on the FTP server with progress information.
 void append(InputStream inputStream, long localFileSize, RemoteFile appendTo, Progress progress, FTPAbortableTransfer abort)
          Append to a file on the FTP server with progress information and the ability to abort the data transfer.
 void append(InputStream inputStream, long localFileSize, String appendTo, Progress progress)
          Append to a file on the FTP server with progress information.
 void append(InputStream inputStream, long localFileSize, String appendTo, Progress progress, FTPAbortableTransfer abort)
          Append to a file on the FTP server with progress information and the ability to abort the data transfer.
 void append(InputStream inputStream, RemoteFile appendTo)
          Append to a file on the FTP server.
 void append(InputStream inputStream, RemoteFile appendTo, FTPAbortableTransfer abort)
          Append to a file on the FTP server with the ability to abort the data transfer.
 void append(InputStream inputStream, String appendTo)
          Append to a file on the FTP server.
 void append(InputStream inputStream, String appendTo, FTPAbortableTransfer abort)
          Append to a file on the FTP server with the ability to abort the data transfer.
 void ascii()
          Set the data transfer mode to ascii.
 void auto()
          Set the data transfer mode to auto.
 void binary()
          Set the data transfer mode to binary (or image).
 void cdup()
          Change up one directory on the FTP server.
 void chdir(RemoteFile dir)
          Change to a remote directory on the FTP server.
 void chdir(String dir)
          Change to a remote directory on the FTP server.
 void connect()
          Connect to the FTP host and port.
 void delete(RemoteFile fileName)
          Delete a file from the FTP server.
 void delete(String fileName)
          Delete a file from the FTP server.
 void ebcdic()
          Set the data transfer mode to ebcdic.
 void forcePasvToUseControlIP(boolean on)
          Forces passive data transfers to use the control socket IP address.
 String getAccount()
          Get the account name.
 int getConnectionType()
          The data connection type is either passive or active.
 Socket getControlSocket()
          Get the control socket.
static String getDateStamp()
          The datestamp of the bean.
 FTPCommand getFTPCommand()
          Get the FTPCommand object.
 String getHostName()
          Get the hostname of the FTP server.
 short getListStyle()
          Get the server listing style of the FTP server.
 String getPassword()
          Get the password.
 int getPort()
          Get the port of the FTP server.
protected  int getPortFromRange()
           
 short getTransferMode()
          The data transfer mode is either auto, ascii, or binary (image).
 String getUser()
          Get the username.
static String getVersion()
          The version of the bean.
 String help(String item)
          Get the server's remote help.
 boolean isConnected()
          Whether or not currently connected.
 boolean isLoggedIn()
          Whether or not currently logged in.
 boolean isTransferRestartable()
          Whether or not the server supports restarting broken data transfers.
 RemoteFileList list()
          List the current remote directory.
 RemoteFileList list(FTPAbortableTransfer abort)
          List the current remote directory with the ability to abort the listing.
 RemoteFileList list(RemoteFile file)
          List items on the remote FTP server.
 RemoteFileList list(RemoteFile file, FTPAbortableTransfer abort, boolean showHidden)
          List items on the remote FTP server with the ability to abort the listing.
 RemoteFileList list(String itemsToList)
          List items on the remote FTP server.
 RemoteFileList list(String itemsToList, FTPAbortableTransfer abort, boolean showHidden)
          List items on the remote FTP server with the ability to abort the listing.
 RemoteFileList listAll()
          List the current remote directory, including hidden files.
 RemoteFileList listAll(FTPAbortableTransfer abort)
          List the current remote directory including hidden files with the ability to abort the listing.
 void login(String user, String pass)
          Login to the FTP server.
 void login(String user, String pass, String acct)
          Login to the FTP server.
 void logout()
          Logout from the FTP server.
protected  Socket makeControlSocket(HostInfo hostInfo)
          Make a new control socket.
protected  ServerSocket makeDataServerSocket(HostInfo hostInfo)
          Make a new data server socket.
protected  Socket makeDataSocket(HostInfo hostInfo)
          Make a new data socket.
protected  FTPCommand makeFTPCommand(BufferedReader inputReader, PrintWriter outputWriter)
          Set the FTPCommand object.
 void mkdir(String newDir)
          Make a new directory on the FTP server.
 void modeZ()
          Set mode z (on-the-fly compression) data transfer.
 void noop()
          Send a noop command to the FTP server.
protected  HostInfo pasv()
          Setup a pasv data connection.
protected  void port(HostInfo hostInfo)
          Setup an active data connection.
 String pwd()
          Get the current directory on the FTP server.
 void raw(String rawCmd)
          Send a raw command to the FTP server.
 void rename(String from, String to)
          Rename a file on the FTP server.
 void retrieve(RemoteFile remoteFile, File outputFile, boolean restartXfer)
          Retrieve a file from the FTP server.
 void retrieve(RemoteFile remoteFile, File outputFile, boolean restartXfer, FTPAbortableTransfer abort)
          Retrieve a file from the FTP server with the ability to abort the transfer.
 void retrieve(RemoteFile remoteFile, File outputFile, boolean restartXfer, Progress progress)
          Retrieve a file from the FTP server with progress information.
 void retrieve(RemoteFile remoteFile, File outputFile, boolean restartXfer, Progress progress, FTPAbortableTransfer abort)
          Retrieve a file from the FTP server with progress information and the ability to abort the transfer.
 void retrieve(RemoteFile remoteFile, OutputStream outputStream)
          Retrieve a file from the FTP server.
 void retrieve(RemoteFile remoteFile, OutputStream outputStream, FTPAbortableTransfer abort)
          Retrieve a file from the FTP server with the ability to abort the transfer.
 void retrieve(RemoteFile remoteFile, OutputStream outputStream, Progress progress)
          Retrieve a file from the FTP server with progress information.
 void retrieve(RemoteFile remoteFile, OutputStream outputStream, Progress progress, FTPAbortableTransfer abort)
          Retrieve a file from the FTP server with progress information and the ability to abort the transfer.
 void retrieve(String remoteFile, File outputFile, boolean restartXfer)
          Retrieve a file from the FTP server.
 void retrieve(String remoteFile, File outputFile, boolean restartXfer, FTPAbortableTransfer abort)
          Retrieve a file from the FTP server with the ability to abort the transfer.
 void retrieve(String remoteFile, File outputFile, boolean restartXfer, Progress progress)
          Retrieve a file from the FTP server with progress information.
 void retrieve(String remoteFile, File outputFile, boolean restartXfer, Progress progress, FTPAbortableTransfer abort)
          Retrieve a file from the FTP server with progress information and the ability to abort the transfer.
 void retrieve(String remoteFile, OutputStream outputStream)
          Retrieve a file from the FTP server.
 void retrieve(String remoteFile, OutputStream outputStream, FTPAbortableTransfer abort)
          Retrieve a file from the FTP server with the ability to abort the transfer.
 void retrieve(String remoteFile, OutputStream outputStream, Progress progress)
          Retrieve a file from the FTP server with progress information.
 void retrieve(String remoteFile, OutputStream outputStream, Progress progress, FTPAbortableTransfer abort)
          Retrieve a file from the FTP server with progress information and the ability to abort the transfer.
 void rmdir(RemoteFile dir)
          Remote a directory from the FTP server.
 void rmdir(String dir)
          Remote a directory from the FTP server.
 void sendAccount(String acct)
          Sends the account to the FTP server.
 void sendPassword(String pass)
          Sends the password to the FTP server.
 void sendUserName(String user)
          Sends the username to the FTP server.
 void setAccount(String account)
          Set the account name.
 void setActivePortRange(int minPort, int maxPort)
          Set a range of ports to use during active (port) data connections.
 void setConnectionType(short type)
          Set the data connection type.
protected  void setControlSocket(Socket controlSocket)
          Set the control socket.
 void setHostName(String hostName)
          Set the hostname of the FTP server.
 void setListStyle(short listStyle)
          Set the server type to help with the listing style of the FTP server.
 void setPassword(String password)
          Set the password.
 void setPort(int port)
          Set the port of the FTP server.
 void setRecvCmdStream(OutputStream recvCmdStream)
          Set the stream responsible for handling respones from the FTP server.
 void setSendCmdStream(OutputStream sendCmdStream)
          Set the stream responsible for handling commands sent to the FTP server.
 void setSocksIVProxy(String host, int port)
          Set the Socks IV server proxy.
 void setSocksVProxy(String host, int port, String username, String password)
          Set the Socks V server proxy.
 void setStringDataAsUTF8(boolean on)
          Set server to treat string data in UTF8 format
 void setUser(String user)
          Set the username.
 long size(RemoteFile file)
          Get the size of a file on the FTP server.
 long size(String file)
          Get the size of a file on the FTP server.
 void store(File file, boolean restartXfer)
          Store a file to the FTP server.
 void store(File file, boolean restartXfer, FTPAbortableTransfer abort)
          Store a file to the FTP server with the ability to abort the data transfer.
 void store(File file, boolean restartXfer, Progress progress)
          Store a file to the FTP server with progress information.
 void store(File file, boolean restartXfer, Progress progress, FTPAbortableTransfer abort)
          Store a file to the FTP server with progress information and the ability to abort the data transfer.
 void store(File file, String name, boolean restartXfer)
          Store a file to the FTP server with a specific filename.
 void store(File file, String name, boolean restartXfer, FTPAbortableTransfer abort)
          Store a file to the FTP server with a specific filename and with the ability to abort the data transfer.
 void store(File file, String name, boolean restartXfer, Progress progress)
          Store a file to the FTP server with a specific filename and with progress information.
 void store(File file, String name, boolean restartXfer, Progress progress, FTPAbortableTransfer abort)
          Store a file to the FTP server with a specific filename and progress information and the ability to abort the data transfer.
 void store(InputStream inputStream)
          Store a file to the FTP server.
 void store(InputStream inputStream, FTPAbortableTransfer abort)
          Store a file to the FTP server with the ability to abort the data transfer.
 void store(InputStream inputStream, long localFileSize, Progress progress)
          Store a file to the FTP server with progress information.
 void store(InputStream inputStream, long localFileSize, Progress progress, FTPAbortableTransfer abort)
          Store a file to the FTP server with progress information and the ability to abort the data transfer.
 void store(InputStream inputStream, long localFileSize, String name, Progress progress)
          Store a file to the FTP server with a specific filename and with progress information.
 void store(InputStream inputStream, long localFileSize, String name, Progress progress, FTPAbortableTransfer abort)
          Store a file to the FTP server with a specific filename and progress information and the ability to abort the data transfer.
 void store(InputStream inputStream, String name)
          Store a file to the FTP server with a specific filename.
 void store(InputStream inputStream, String name, FTPAbortableTransfer abort)
          Store a file to the FTP server with a specific filename and with the ability to abort the data transfer.
 boolean stringDataAsUTF8()
          Whether or not the server is treating the string data as UTF8
 Date time(RemoteFile file)
          Get the modification time of a file on the FTP server.
 Date time(String file)
          Get the modification time of a file on the FTP server.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ASCII_TRANSFER_MODE

public static final short ASCII_TRANSFER_MODE
Used to set the data transfer mode to ascii.

See Also:
Constant Field Values

BINARY_TRANSFER_MODE

public static final short BINARY_TRANSFER_MODE
Used to set the data transfer mode to binary; also known as image.

See Also:
Constant Field Values

AUTO_TRANSFER_MODE

public static final short AUTO_TRANSFER_MODE
Used to set the data transfer mode to auto. This mode attempts to guess which transfer mode (ascii or binary) to set based on file type.

See Also:
Constant Field Values

EBCDIC_TRANSFER_MODE

public static final short EBCDIC_TRANSFER_MODE
Used to set the data transfer mode to ebcdic.

See Also:
Constant Field Values

PASV_CONNECTION_TYPE

public static final short PASV_CONNECTION_TYPE
Used to set the data connection type to passive.

See Also:
Constant Field Values

PASSIVE_CONNECTION_TYPE

public static final short PASSIVE_CONNECTION_TYPE
Used to set the data connection type to passive.

See Also:
Constant Field Values

ACTIVE_CONNECTION_TYPE

public static final short ACTIVE_CONNECTION_TYPE
Used to set the data connection type to active.

See Also:
Constant Field Values

modeZEnabled

protected boolean modeZEnabled
If mode z is enabled, this is true.


isConnected

protected boolean isConnected
If we are connected, this is true.


isLoggedIn

protected boolean isLoggedIn
If we are logged in, this is true.


lastPortFromRange

protected int lastPortFromRange
These values are used if an active port range is specifed


minPortInRange

protected int minPortInRange

maxPortInRange

protected int maxPortInRange

recvCmdStream

protected OutputStream recvCmdStream
This stream is used to print the responses returned from the server.


sendCmdStream

protected OutputStream sendCmdStream
This stream is used to print the commands sent to the server.


command

protected FTPCommand command
This handles the FTP commands.

Constructor Detail

FTP

public FTP(HostInfo hostInfo)
Create a new FTP object without response notification.

Parameters:
hostInfo - the HostInfo to connect to.

FTP

public FTP(String host,
           int port)
Create a new FTP object without response notification.

Parameters:
host - the hostname to connect to.
port - the port to connect to.

FTP

public FTP(HostInfo hostInfo,
           OutputStream sendCmdStream,
           OutputStream recvCmdStream)
Create a new FTP object with response notification.

Parameters:
hostInfo - the HostInfo to connect to.
sendCmdStream - the commands sent to the server. Pass null if not interested in this data.
recvCmdStream - the responses returned from the server. Pass null if not interested in this data.

FTP

public FTP(String host,
           int port,
           OutputStream sendCmdStream,
           OutputStream recvCmdStream)
Create a new FTP object with response notification.

Parameters:
host - the hostname to connect to.
port - the port to connect to.
sendCmdStream - the commands sent to the server. Pass null if not interested in this data.
recvCmdStream - the responses returned from the server. Pass null if not interested in this data.
Method Detail

connect

public void connect()
             throws FTPConnectException,
                    FTPException,
                    IOException,
                    UnknownHostException,
                    IllegalArgumentException
Connect to the FTP host and port. If the port was not set, we default to 21.

Throws:
FTPConnectException - if the connection fails.
FTPException - if the FTP server returns an error code.
IOException - if there are socket problems.
UnknownHostException - if the host could not be found.
IllegalArgumentException - if hostName is null.

login

public void login(String user,
                  String pass)
           throws IOException,
                  FTPBadLoginException,
                  FTPConnectException,
                  FTPException,
                  IllegalArgumentException
Login to the FTP server.

Parameters:
user - the username to login as.
pass - the password to login as.
Throws:
IOException - if there is a socket problem.
FTPBadLoginException - if there is a problem logging in.
FTPConnectException - if this is called prior to connect
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with any of the passed in args.
See Also:
connect()

login

public void login(String user,
                  String pass,
                  String acct)
           throws IOException,
                  FTPBadLoginException,
                  FTPConnectException,
                  FTPException,
                  IllegalArgumentException
Login to the FTP server.

Parameters:
user - the username to login as.
pass - the password to login as.
acct - the account to use.
Throws:
IOException - if there is a socket problem.
FTPBadLoginException - if there is a problem logging in.
FTPConnectException - if this is called prior to connect
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with any of the passed in args.
See Also:
connect()

logout

public void logout()
            throws IOException,
                   FTPException
Logout from the FTP server.

Throws:
IOException - if there is a socket problem.
FTPException - if the FTP server returns an error code.

sendUserName

public void sendUserName(String user)
                  throws FTPNeedPasswordException,
                         FTPNeedAccountException,
                         FTPBadLoginException,
                         FTPException,
                         IllegalArgumentException
Sends the username to the FTP server.

Parameters:
user - the username.
Throws:
FTPNeedPasswordException - if a password is required.
FTPNeedAccountException - if an accound is required.
FTPBadLoginException - if there is a problem logging in.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the username.

sendPassword

public void sendPassword(String pass)
                  throws FTPNeedAccountException,
                         FTPBadLoginException,
                         FTPException,
                         IllegalArgumentException
Sends the password to the FTP server.

Parameters:
pass - the password.
Throws:
FTPNeedAccountException - if an accound is required.
FTPBadLoginException - if there is a problem logging in.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the password.

sendAccount

public void sendAccount(String acct)
                 throws FTPBadLoginException,
                        FTPException,
                        IllegalArgumentException
Sends the account to the FTP server.

Parameters:
acct - the account.
Throws:
FTPBadLoginException - if there is a problem logging in.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the account.

listAll

public RemoteFileList listAll()
                       throws FTPException,
                              IOException
List the current remote directory, including hidden files. Subject to availiblity on certain servers.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Returns:
a list of RemoteFile objects as a RemoteFileList.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket problem.
See Also:
RemoteFile, getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

list

public RemoteFileList list()
                    throws FTPException,
                           IOException
List the current remote directory.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Returns:
a list of RemoteFile objects as a RemoteFileList.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket problem.
See Also:
RemoteFile, getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

list

public RemoteFileList list(FTPAbortableTransfer abort)
                    throws FTPException,
                           IOException
List the current remote directory with the ability to abort the listing.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
abort - an Object that allows for the abortion of the list.
Returns:
a list of RemoteFile objects as a RemoteFileList.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket problem.
See Also:
RemoteFile, getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

listAll

public RemoteFileList listAll(FTPAbortableTransfer abort)
                       throws FTPException,
                              IOException
List the current remote directory including hidden files with the ability to abort the listing.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
abort - an Object that allows for the abortion of the list.
Returns:
a list of RemoteFile objects as a RemoteFileList.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket problem.
See Also:
RemoteFile, getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

list

public RemoteFileList list(RemoteFile file)
                    throws FTPException,
                           IOException
List items on the remote FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - a RemoteFile you want to to list from the FTP server. Pass null to list the current directory.
Returns:
a list of RemoteFile objects as a RemoteFileList.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket problem.
See Also:
RemoteFile, getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

list

public RemoteFileList list(String itemsToList)
                    throws FTPException,
                           IOException
List items on the remote FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
itemsToList - a space-delimited String of items you want to to list from the FTP server. Pass null to list the current directory.
Returns:
a list of RemoteFile objects as a RemoteFileList.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket problem.
See Also:
RemoteFile, getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

list

public RemoteFileList list(RemoteFile file,
                           FTPAbortableTransfer abort,
                           boolean showHidden)
                    throws FTPException,
                           IOException
List items on the remote FTP server with the ability to abort the listing.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - a RemoteFile want to to list from the FTP server.
abort - an Object that allows for the abortion of the list.
showHidden - flag to show hidden files (only useful for empty list)
Returns:
a list of RemoteFile objects as a RemoteFileList.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket problem.
See Also:
RemoteFile, getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

list

public RemoteFileList list(String itemsToList,
                           FTPAbortableTransfer abort,
                           boolean showHidden)
                    throws FTPException,
                           IOException
List items on the remote FTP server with the ability to abort the listing.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
itemsToList - a space-delimited String of items you want to to list from the FTP server. Pass null to list the current directory.
abort - an Object that allows for the abortion of the list.
showHidden - flag to show hidden files (only useful for empty list)
Returns:
a list of RemoteFile objects as a RemoteFileList.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket problem.
See Also:
RemoteFile, getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(String remoteFile,
                     File outputFile,
                     boolean restartXfer)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the name of the remote file that exists on the FTP server.
outputFile - a local file that will act as storage for the downloaded file. If this parameter is null, a local file will be created with the remote file's name in the current local directory as specified by user.dir.
restartXfer - restart an interrupted transfer (if available).
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(RemoteFile remoteFile,
                     File outputFile,
                     boolean restartXfer)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the RemoteFile that exists on the FTP server.
outputFile - a local file that will act as storage for the downloaded file. If this parameter is null, a local file will be created with the remote file's name in the current local directory as specified by user.dir.
restartXfer - restart an interrupted transfer (if available).
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(String remoteFile,
                     OutputStream outputStream)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the name of the remote file that exists on the FTP server.
outputStream - an output stream that will act as storage for the downloaded file.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(RemoteFile remoteFile,
                     OutputStream outputStream)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the RemoteFile that exists on the FTP server.
outputStream - an output stream that will act as storage for the downloaded file.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(String remoteFile,
                     File outputFile,
                     boolean restartXfer,
                     FTPAbortableTransfer abort)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with the ability to abort the transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the name of the remote file that exists on the FTP server.
outputFile - a local file that will act as storage for the downloaded file. If this parameter is null, a local file will be created with the remote file's name in the current local directory as specified by user.dir.
restartXfer - restart an interrupted transfer (if available).
abort - an Object that allows for the abortion of the retrieve.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(RemoteFile remoteFile,
                     File outputFile,
                     boolean restartXfer,
                     FTPAbortableTransfer abort)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with the ability to abort the transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the RemoteFile that exists on the FTP server.
outputFile - a local file that will act as storage for the downloaded file. If this parameter is null, a local file will be created with the remote file's name in the current local directory as specified by user.dir.
restartXfer - restart an interrupted transfer (if available).
abort - an Object that allows for the abortion of the retrieve.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(String remoteFile,
                     OutputStream outputStream,
                     FTPAbortableTransfer abort)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with the ability to abort the transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the name of the remote file that exists on the FTP server.
outputStream - an output stream that will act as storage for the downloaded file.
abort - an Object that allows for the abortion of the retrieve.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(RemoteFile remoteFile,
                     OutputStream outputStream,
                     FTPAbortableTransfer abort)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with the ability to abort the transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the RemoteFile that exists on the FTP server.
outputStream - an output stream that will act as storage for the downloaded file.
abort - an Object that allows for the abortion of the retrieve.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(String remoteFile,
                     File outputFile,
                     boolean restartXfer,
                     Progress progress)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the name of the remote file that exists on the FTP server.
outputFile - a local file that will act as storage for the downloaded file. If this parameter is null, a local file will be created with the remote file's name in the current local directory as specified by user.dir.
restartXfer - restart an interrupted transfer (if available).
progress - a Progress object which is used to update download status.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(RemoteFile remoteFile,
                     File outputFile,
                     boolean restartXfer,
                     Progress progress)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the RemoteFile that exists on the FTP server.
outputFile - a local file that will act as storage for the downloaded file. If this parameter is null, a local file will be created with the remote file's name in the current local directory as specified by user.dir.
restartXfer - restart an interrupted transfer (if available).
progress - a Progress object which is used to update download status.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(String remoteFile,
                     OutputStream outputStream,
                     Progress progress)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the name of the remote file that exists on the FTP server.
outputStream - an output stream that will act as storage for the downloaded file.
progress - a Progress object which is used to update download status.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(RemoteFile remoteFile,
                     OutputStream outputStream,
                     Progress progress)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the RemoteFile that exists on the FTP server.
outputStream - an output stream that will act as storage for the downloaded file.
progress - a Progress object which is used to update download status.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(String remoteFile,
                     File outputFile,
                     boolean restartXfer,
                     Progress progress,
                     FTPAbortableTransfer abort)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with progress information and the ability to abort the transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the name of the remote file that exists on the FTP server.
outputFile - a local file that will act as storage for the downloaded file. If this parameter is null, a local file will be created with the remote file's name in the current local directory as specified by user.dir.
restartXfer - restart an interrupted transfer (if available).
progress - a Progress object which is used to update download status.
abort - an Object that allows for the abortion of the retrieve.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(RemoteFile remoteFile,
                     File outputFile,
                     boolean restartXfer,
                     Progress progress,
                     FTPAbortableTransfer abort)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with progress information and the ability to abort the transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the RemoteFile that exists on the FTP server.
outputFile - a local file that will act as storage for the downloaded file. If this parameter is null, a local file will be created with the remote file's name in the current local directory as specified by user.dir.
restartXfer - restart an interrupted transfer (if available).
progress - a Progress object which is used to update download status.
abort - an Object that allows for the abortion of the retrieve.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(String remoteFile,
                     OutputStream outputStream,
                     Progress progress,
                     FTPAbortableTransfer abort)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with progress information and the ability to abort the transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the name of the remote file that exists on the FTP server.
outputStream - an output stream that will act as storage for the downloaded file.
progress - a Progress object which is used to update download status.
abort - an Object that allows for the abortion of the retrieve.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

retrieve

public void retrieve(RemoteFile remoteFile,
                     OutputStream outputStream,
                     Progress progress,
                     FTPAbortableTransfer abort)
              throws FTPRestartNotSupportedException,
                     FTPException,
                     IOException
Retrieve a file from the FTP server with progress information and the ability to abort the transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
remoteFile - the RemoteFile that exists on the FTP server.
outputStream - an output stream that will act as storage for the downloaded file.
progress - a Progress object which is used to update download status.
abort - an Object that allows for the abortion of the retrieve.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(File file,
                  boolean restartXfer)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
restartXfer - restart an interrupted transfer (if available).
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(File file,
                  String name,
                  boolean restartXfer)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with a specific filename.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
name - the name you want to save the file as.
restartXfer - restart an interrupted transfer (if available).
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(InputStream inputStream)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" input stream you want to upload.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(InputStream inputStream,
                  String name)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with a specific filename.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" input stream you want to upload.
name - the name you want to save the file as.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(File file,
                  boolean restartXfer,
                  FTPAbortableTransfer abort)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
restartXfer - restart an interrupted transfer (if available).
abort - an Object that allows for the abortion of the store.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(File file,
                  String name,
                  boolean restartXfer,
                  FTPAbortableTransfer abort)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with a specific filename and with the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
name - the name you want to save the file as.
restartXfer - restart an interrupted transfer (if available).
abort - an Object that allows for the abortion of the store.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(InputStream inputStream,
                  FTPAbortableTransfer abort)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" input stream you want to upload.
abort - an Object that allows for the abortion of the store.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(InputStream inputStream,
                  String name,
                  FTPAbortableTransfer abort)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with a specific filename and with the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" input stream you want to upload.
name - the name you want to save the file as.
abort - an Object that allows for the abortion of the store.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(File file,
                  boolean restartXfer,
                  Progress progress)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
restartXfer - restart an interrupted transfer (if available).
progress - a Progress object which is used to update upload status.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(File file,
                  String name,
                  boolean restartXfer,
                  Progress progress)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with a specific filename and with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
name - the name you want to save the file as.
restartXfer - restart an interrupted transfer (if available).
progress - a Progress object which is used to update upload status.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(InputStream inputStream,
                  long localFileSize,
                  Progress progress)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" input stream you want to upload.
localFileSize - the size of the "local file".
progress - a Progress object which is used to update upload status.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(InputStream inputStream,
                  long localFileSize,
                  String name,
                  Progress progress)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with a specific filename and with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" input stream you want to upload.
localFileSize - the size of the "local file".
name - the name you want to save the file as.
progress - a Progress object which is used to update upload status.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(File file,
                  boolean restartXfer,
                  Progress progress,
                  FTPAbortableTransfer abort)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with progress information and the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
restartXfer - restart an interrupted transfer (if available).
progress - a Progress object which is used to update upload status.
abort - an Object that allows for the abortion of the store.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(File file,
                  String name,
                  boolean restartXfer,
                  Progress progress,
                  FTPAbortableTransfer abort)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with a specific filename and progress information and the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
name - the name you want to save the file as.
restartXfer - restart an interrupted transfer (if available).
progress - a Progress object which is used to update upload status.
abort - an Object that allows for the abortion of the store.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(InputStream inputStream,
                  long localFileSize,
                  Progress progress,
                  FTPAbortableTransfer abort)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with progress information and the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" input stream you want to upload.
localFileSize - the size of the "local file".
progress - a Progress object which is used to update upload status.
abort - an Object that allows for the abortion of the store.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

store

public void store(InputStream inputStream,
                  long localFileSize,
                  String name,
                  Progress progress,
                  FTPAbortableTransfer abort)
           throws FTPRestartNotSupportedException,
                  FTPException,
                  IOException,
                  IllegalArgumentException
Store a file to the FTP server with a specific filename and progress information and the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" input stream you want to upload.
localFileSize - the size of the "local file".
name - the name you want to save the file as.
progress - a Progress object which is used to update upload status.
abort - an Object that allows for the abortion of the store.
Throws:
FTPRestartNotSupportedException - if the FTP server doesn't support restarting incomplete file xfer.
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(File file,
                   String appendTo)
            throws FTPException,
                   IOException
Append to a file on the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
appendTo - the remote file name you want to append to.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(File file,
                   RemoteFile appendTo)
            throws FTPException,
                   IOException
Append to a file on the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
appendTo - the RemoteFile you want to append to.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(InputStream inputStream,
                   String appendTo)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" stream you want to upload.
appendTo - the remote file name you want to append to.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(InputStream inputStream,
                   RemoteFile appendTo)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" stream you want to upload.
appendTo - the RemoteFile you want to append to.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(File file,
                   String appendTo,
                   FTPAbortableTransfer abort)
            throws FTPException,
                   IOException
Append to a file on the FTP server with the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
appendTo - the remote file name you want to append to.
abort - an Object that allows for the abortion of the append.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(File file,
                   RemoteFile appendTo,
                   FTPAbortableTransfer abort)
            throws FTPException,
                   IOException
Append to a file on the FTP server with the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
appendTo - the RemoteFile you want to append to.
abort - an Object that allows for the abortion of the append.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(InputStream inputStream,
                   String appendTo,
                   FTPAbortableTransfer abort)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" stream you want to upload.
appendTo - the remote file name you want to append to.
abort - an Object that allows for the abortion of the append.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(InputStream inputStream,
                   RemoteFile appendTo,
                   FTPAbortableTransfer abort)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" stream you want to upload.
appendTo - the RemoteFile you want to append to.
abort - an Object that allows for the abortion of the append.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(File file,
                   String appendTo,
                   Progress progress)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
appendTo - the remote file name you want to append to.
progress - a Progress object which is used to update upload status.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(File file,
                   RemoteFile appendTo,
                   Progress progress)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
appendTo - the RemoteFile you want to append to.
progress - a Progress object which is used to update upload status.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(InputStream inputStream,
                   long localFileSize,
                   String appendTo,
                   Progress progress)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" stream you want to upload.
localFileSize - the size of the "local file"
appendTo - the remote file name you want to append to.
progress - a Progress object which is used to update upload status.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(InputStream inputStream,
                   long localFileSize,
                   RemoteFile appendTo,
                   Progress progress)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with progress information.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" stream you want to upload.
localFileSize - the size of the "local file"
appendTo - the RemoteFile you want to append to.
progress - a Progress object which is used to update upload status.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(File file,
                   String appendTo,
                   Progress progress,
                   FTPAbortableTransfer abort)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with progress information and the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
appendTo - the remote file name you want to append to.
progress - a Progress object which is used to update upload status.
abort - an Object that allows for the abortion of the append.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(File file,
                   RemoteFile appendTo,
                   Progress progress,
                   FTPAbortableTransfer abort)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with progress information and the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
file - the local file you want to upload.
appendTo - the RemoteFile you want to append to.
progress - a Progress object which is used to update upload status.
abort - an Object that allows for the abortion of the append.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(InputStream inputStream,
                   long localFileSize,
                   String appendTo,
                   Progress progress,
                   FTPAbortableTransfer abort)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with progress information and the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" stream you want to upload.
localFileSize - the size of the "local file"
appendTo - the remote file name you want to append to.
progress - a Progress object which is used to update upload status.
abort - an Object that allows for the abortion of the append.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

append

public void append(InputStream inputStream,
                   long localFileSize,
                   RemoteFile appendTo,
                   Progress progress,
                   FTPAbortableTransfer abort)
            throws FTPException,
                   IOException,
                   IllegalArgumentException
Append to a file on the FTP server with progress information and the ability to abort the data transfer.

Based on what getConnectionType returns, either pasv or port will be sent in this routine.

Parameters:
inputStream - the "local file" stream you want to upload.
localFileSize - the size of the "local file"
appendTo - the RemoteFile you want to append to.
progress - a Progress object which is used to update upload status.
abort - an Object that allows for the abortion of the append.
Throws:
FTPException - if the FTP server returns an error code.
IOException - if there is a socket or file problem.
IllegalArgumentException - if there are argument related problems.
See Also:
getConnectionType(), setConnectionType(short), pasv(), port(HostInfo)

raw

public void raw(String rawCmd)
         throws FTPException
Send a raw command to the FTP server.

Parameters:
rawCmd - the command sent to the FTP server.
Throws:
FTPException - if the FTP server returns an error code.

noop

public void noop()
          throws FTPException
Send a noop command to the FTP server.

Throws:
FTPException - if the FTP server returns an error code.

abort

public void abort(FTPAbortableTransfer abort)
           throws FTPException,
                  IllegalArgumentException
Abort a data transfer from the FTP server.

Parameters:
abort - an Object that will has information that will allow for the abortion of a transfer.
Throws:
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the abort argument.

setStringDataAsUTF8

public void setStringDataAsUTF8(boolean on)
                         throws FTPException
Set server to treat string data in UTF8 format

Parameters:
on - enable UTF8 support.
Throws:
FTPException - if the FTP server returns an error code.

stringDataAsUTF8

public boolean stringDataAsUTF8()
Whether or not the server is treating the string data as UTF8

Returns:
true if server treats string as UTF8

pasv

protected HostInfo pasv()
                 throws FTPException
Setup a pasv data connection.

Returns:
a HostInfo object that is used for the data transfer.
Throws:
FTPException - if the FTP server returns an error code.

port

protected void port(HostInfo hostInfo)
             throws FTPException
Setup an active data connection.

Parameters:
hostInfo - a HostInfo object that describes the host information used for the data transfer.
Throws:
FTPException - if the FTP server returns an error code.

chdir

public void chdir(String dir)
           throws FTPNotADirectoryException,
                  FTPNoSuchFileException,
                  FTPException,
                  IllegalArgumentException
Change to a remote directory on the FTP server.

Parameters:
dir - the name of the remote directory to change to.
Throws:
FTPNotADirectoryException - if the dir arg is not a directory.
FTPNoSuchFileException - if the dir arg could not be found on the server.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the dir argument.

chdir

public void chdir(RemoteFile dir)
           throws FTPNotADirectoryException,
                  FTPNoSuchFileException,
                  FTPException,
                  IllegalArgumentException
Change to a remote directory on the FTP server.

Parameters:
dir - the remote directory to change to.
Throws:
FTPNotADirectoryException - if the dir arg is not a directory.
FTPNoSuchFileException - if the dir arg could not be found on the server.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the dir argument.

help

public String help(String item)
            throws FTPException
Get the server's remote help.

Parameters:
item - a space-delimited String of items to get help on.
Throws:
FTPException - if the FTP server returns an error code.

pwd

public String pwd()
           throws FTPException
Get the current directory on the FTP server.

Returns:
the path of the current working directory.
Throws:
FTPException - if the FTP server returns an error code.

ascii

public void ascii()
           throws FTPException
Set the data transfer mode to ascii.

Throws:
FTPException - if the FTP server returns an error code.

ebcdic

public void ebcdic()
            throws FTPException
Set the data transfer mode to ebcdic.

Throws:
FTPException - if the FTP server returns an error code.

auto

public void auto()
Set the data transfer mode to auto.


binary

public void binary()
            throws FTPException
Set the data transfer mode to binary (or image).

Throws:
FTPException - if the FTP server returns an error code.

modeZ

public void modeZ()
           throws FTPException
Set mode z (on-the-fly compression) data transfer.

Throws:
FTPException - if the FTP server returns an error code.

delete

public void delete(String fileName)
            throws FTPException,
                   IllegalArgumentException
Delete a file from the FTP server.

Parameters:
fileName - the file to delete on the server.
Throws:
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the fileName argument.

delete

public void delete(RemoteFile fileName)
            throws FTPException,
                   IllegalArgumentException
Delete a file from the FTP server.

Parameters:
fileName - the file to delete on the server.
Throws:
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the fileName argument.

rename

public void rename(String from,
                   String to)
            throws FTPException,
                   IllegalArgumentException
Rename a file on the FTP server.

Parameters:
from - the old name of the file.
to - the new name of the file.
Throws:
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the from or to arguments.

size

public long size(String file)
          throws FTPNoSuchFileException,
                 FTPException,
                 IllegalArgumentException
Get the size of a file on the FTP server.

Parameters:
file - the name of the file.
Returns:
the size or -1 if the size could not be determined.
Throws:
FTPNoSuchFileException - if file is not found.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if file is missing.

size

public long size(RemoteFile file)
          throws FTPNoSuchFileException,
                 FTPException,
                 IllegalArgumentException
Get the size of a file on the FTP server.

Parameters:
file - the name of the file.
Returns:
the size or -1 if the size could not be determined.
Throws:
FTPNoSuchFileException - if file is not found.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if file is missing.

time

public Date time(String file)
          throws FTPNoSuchFileException,
                 FTPException,
                 IllegalArgumentException
Get the modification time of a file on the FTP server.

Parameters:
file - the name of the file.
Returns:
the file time or null if the time could not be determined.
Throws:
FTPNoSuchFileException - if file is not found.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if file is missing.

time

public Date time(RemoteFile file)
          throws FTPNoSuchFileException,
                 FTPException,
                 IllegalArgumentException
Get the modification time of a file on the FTP server.

Parameters:
file - the name of the file.
Returns:
the file time or null if the time could not be determined.
Throws:
FTPNoSuchFileException - if file is not found.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if file is missing.

mkdir

public void mkdir(String newDir)
           throws FTPException,
                  FTPAccessDeniedException,
                  IllegalArgumentException
Make a new directory on the FTP server.

Parameters:
newDir - the name of the new directory.
Throws:
FTPAccessDeniedException - if the directory couldn't be created due to access restrictions.
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the newDir argument.

rmdir

public void rmdir(String dir)
           throws FTPException,
                  IllegalArgumentException
Remote a directory from the FTP server.

Parameters:
dir - the directory to delete on the server.
Throws:
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the dir argument.

rmdir

public void rmdir(RemoteFile dir)
           throws FTPException,
                  IllegalArgumentException
Remote a directory from the FTP server.

Parameters:
dir - the directory to delete on the server.
Throws:
FTPException - if the FTP server returns an error code.
IllegalArgumentException - if there is a problem with the dir argument.

cdup

public void cdup()
          throws FTPException
Change up one directory on the FTP server.

Throws:
FTPException - if the FTP server returns an error code.

makeControlSocket

protected Socket makeControlSocket(HostInfo hostInfo)
                            throws IOException
Make a new control socket.

Parameters:
hostInfo - a HostInfo object that describes where to make the socket.
Returns:
a new instance of a socket.
Throws:
IOException - if there is a socket problem.

makeDataSocket

protected Socket makeDataSocket(HostInfo hostInfo)
                         throws IOException
Make a new data socket.

Parameters:
hostInfo - a HostInfo object that describes where to make the socket.
Returns:
a new instance of a socket.
Throws:
IOException - if there is a socket problem.

makeDataServerSocket

protected ServerSocket makeDataServerSocket(HostInfo hostInfo)
                                     throws IOException
Make a new data server socket.

Parameters:
hostInfo - a HostInfo object that describes where to make the socket.
Returns:
a new instance of a server socket.
Throws:
IOException - if there is a socket problem.

setActivePortRange

public void setActivePortRange(int minPort,
                               int maxPort)
                        throws Exception
Set a range of ports to use during active (port) data connections.

Parameters:
minPort - the minPort specifies the minimum port used for active transfers
maxPort - the maxPort specifies the maximum port used for active transfers
Throws:
Exception - if the min/max ports are invalid

getPortFromRange

protected int getPortFromRange()

getTransferMode

public short getTransferMode()
The data transfer mode is either auto, ascii, or binary (image).

Returns:
the transfer mode
See Also:
AUTO_TRANSFER_MODE, ASCII_TRANSFER_MODE, BINARY_TRANSFER_MODE, EBCDIC_TRANSFER_MODE

getConnectionType

public int getConnectionType()
The data connection type is either passive or active.

Returns:
the connection type
See Also:
PASV_CONNECTION_TYPE, ACTIVE_CONNECTION_TYPE

setConnectionType

public void setConnectionType(short type)
Set the data connection type.

Parameters:
type - the connection type.
See Also:
PASV_CONNECTION_TYPE, ACTIVE_CONNECTION_TYPE

isConnected

public boolean isConnected()
Whether or not currently connected.

Returns:
true if connected.

isLoggedIn

public boolean isLoggedIn()
Whether or not currently logged in.

Returns:
true if logged in.

isTransferRestartable

public boolean isTransferRestartable()
Whether or not the server supports restarting broken data transfers.

Returns:
true if supported by server.

getHostName

public String getHostName()
Get the hostname of the FTP server.

Returns:
the hostname.

setHostName

public void setHostName(String hostName)
Set the hostname of the FTP server.

Parameters:
hostName - the hostname of the FTP server.

getPort

public int getPort()
Get the port of the FTP server.

Returns:
the port.

setPort

public void setPort(int port)
Set the port of the FTP server.

Parameters:
port - the port of the FTP server.

getUser

public String getUser()
Get the username.

Returns:
the username.

setUser

public void setUser(String user)
Set the username.

Parameters:
user - the username.

getPassword

public String getPassword()
Get the password.

Returns:
the password.

setPassword

public void setPassword(String password)
Set the password.

Parameters:
password - the password.

getAccount

public String getAccount()
Get the account name.

Returns:
the account name.

setAccount

public void setAccount(String account)
Set the account name.

Parameters:
account - the account name.

getControlSocket

public Socket getControlSocket()
Get the control socket.

Returns:
the control socket.

setControlSocket

protected void setControlSocket(Socket controlSocket)
                         throws IOException
Set the control socket.

Parameters:
controlSocket - the control socket.
Throws:
IOException

setRecvCmdStream

public void setRecvCmdStream(OutputStream recvCmdStream)
Set the stream responsible for handling respones from the FTP server.

Parameters:
recvCmdStream - the server response stream. Pass null to unset this stream.

setSendCmdStream

public void setSendCmdStream(OutputStream sendCmdStream)
Set the stream responsible for handling commands sent to the FTP server.

Parameters:
sendCmdStream - the commands sent stream. Pass null to unset this stream.

getListStyle

public short getListStyle()
Get the server listing style of the FTP server.

Returns:
the list style for the server type
See Also:
FTPServerInfo.LIST_STYLE_UNKNOWN, FTPServerInfo.LIST_STYLE_UNIX, FTPServerInfo.LIST_STYLE_WINDOWS, FTPServerInfo.LIST_STYLE_NETWARE

setListStyle

public void setListStyle(short listStyle)
Set the server type to help with the listing style of the FTP server.

Parameters:
listStyle - the list style for the server type (UNIX, NETWARE, Windows, Unknown)
See Also:
FTPServerInfo.LIST_STYLE_UNKNOWN, FTPServerInfo.LIST_STYLE_UNIX, FTPServerInfo.LIST_STYLE_WINDOWS, FTPServerInfo.LIST_STYLE_NETWARE

setSocksIVProxy

public void setSocksIVProxy(String host,
                            int port)
Set the Socks IV server proxy.

Parameters:
host - the hostname of the proxy. Pass null to unset the proxy.
port - the port of the proxy.

setSocksVProxy

public void setSocksVProxy(String host,
                           int port,
                           String username,
                           String password)
Set the Socks V server proxy.

Parameters:
host - the hostname of the proxy. Pass null to unset the proxy.
port - the port of the proxy.
username - the socks username (can be null for no auth)
password - the socks password (can be null for no auth)

getFTPCommand

public FTPCommand getFTPCommand()
Get the FTPCommand object.

Returns:
an FTPCommand object.

makeFTPCommand

protected FTPCommand makeFTPCommand(BufferedReader inputReader,
                                    PrintWriter outputWriter)
Set the FTPCommand object.

Parameters:
inputReader - the BufferedReader comes from the input stream of the control socket.
outputWriter - the PrintWriter comes from the output stream of the control socket.
Returns:
a new instance of an FTPCommand object.

getVersion

public static String getVersion()
The version of the bean.


getDateStamp

public static String getDateStamp()
The datestamp of the bean.


forcePasvToUseControlIP

public void forcePasvToUseControlIP(boolean on)
Forces passive data transfers to use the control socket IP address.

Parameters:
on - true if to use control socket IP, false if off.

aboutToTransferData

protected void aboutToTransferData()
Called before data transfers begin.



Copyright © 2000-12 Glub Tech, Inc. All Rights Reserved.