|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.myjavaworld.ftp.DataConnection
com.myjavaworld.ftp.SSLDataConnection
public class SSLDataConnection
A DataConnection object is used to transfer data over the data
connection in an FTP process. FTPClient object will initiate a
DataConnection based on the commands the send to the remote
host. For more details about data connection, refer to the FTP protocol
specification (RFC 959).
| Field Summary |
|---|
| Fields inherited from class com.myjavaworld.ftp.DataConnection |
|---|
abort, client, in, listenerList, out, server, socket |
| Fields inherited from interface com.myjavaworld.ftp.FTPConstants |
|---|
DEFAULT_BUFFER_SIZE, DEFAULT_IMPLICIT_SSL_PORT, DEFAULT_MODE, DEFAULT_PORT, DEFAULT_STRUCTURE, DEFAULT_TIMEOUT, DEFAULT_TYPE, EOL, MODE_BLOCK, MODE_COMPRESSED, MODE_STREAM, STRUCTURE_FILE, STRUCTURE_PAGE, STRUCTURE_RECORD, TYPE_ASCII, TYPE_BINARY, TYPE_EBCDIC, TYPE_IMAGE, TYPE_LOCAL, USE_EXPLICIT_SSL, USE_IMPLICIT_SSL, USE_NO_SSL, USE_SSL_IF_AVAILABLE |
| Constructor Summary | |
|---|---|
SSLDataConnection(FTPClient client)
Constructs a DataConnection object. |
|
| Method Summary | |
|---|---|
void |
accept()
Listenes for connections. |
int |
bind()
Binds a server socket on the local host on a free port. |
void |
connect(InetAddress address,
int port)
Connects to the specified InetAddress to the specified port
number. |
void |
connect(String ipAddress,
int port)
Connects to the specified IP address to the specified port number. |
| Methods inherited from class com.myjavaworld.ftp.DataConnection |
|---|
abort, close, download, fireDataTransferAborted, fireDataTransferFinished, fireDataTransferProgress, fireDataTransferStarted, isAborted, list, stdout, upload |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SSLDataConnection(FTPClient client)
DataConnection object.
client - FTPClient that created this data connection.| Method Detail |
|---|
public int bind()
throws ConnectionException
bind in class DataConnectionConnectionException - If could not bind a server.
public void accept()
throws ConnectionException
accept in class DataConnectionConnectionException - If a network or IO error occurs.
public void connect(String ipAddress,
int port)
throws ConnectionException
connect in class DataConnectionipAddress - IP address of the remote host in xxx.xxx.xxx.xxx format.port - Port number to connect to.
ConnectionException - if a network or IO error occurs.
public void connect(InetAddress address,
int port)
throws ConnectionException
InetAddress to the specified port
number. This method is called by the FTPClients if they prefer to
transfer data in passive mode.
connect in class DataConnectionaddress - Ineternet address of the remote host.port - Port number to connect to.
ConnectionException - if a network or IO error occurs.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||