|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object toolbox.allegato.FTPConfig
public class FTPConfig
Encapsulates the configuration of a FTPClient connection. The class provides access to all FTP parameters specified in a XML element or set using the set methods.
The class also provides a method to establish the connection.
Constructor Summary | |
---|---|
FTPConfig()
Default constructor |
|
FTPConfig(java.lang.String name,
XMLProperties xmlProps)
Initialises this config object with the given XML configuration |
Method Summary | |
---|---|
org.apache.commons.net.ftp.FTPClient |
createFTPClient()
Creates a FTPClient using the configuration properties of this configuration object and returns the reference. |
java.lang.String |
getConnectionMode()
Returns the connection mode string for this config object. |
java.lang.String |
getPassword()
Returns the password for this config object. |
java.lang.String |
getPort()
Returns the port string for this config object. |
java.lang.String |
getServer()
Returns the server string for this config object. |
java.lang.String |
getTransferMode()
Returns the transfer mode string for this config object. |
java.lang.String |
getUserName()
Returns the user name for this config object. |
void |
setConnectionMode(java.lang.String connection)
Set the connection mode string for this config object. |
void |
setPassword(java.lang.String password)
Set the password for this config object. |
void |
setPort(java.lang.String port)
Set the port string for this config object. |
void |
setServer(java.lang.String server)
Set the the server string for this config object. |
void |
setTransferMode(java.lang.String transfer)
Set the transfer mode string for this config object. |
void |
setUserName(java.lang.String userName)
Set the user name for this config object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FTPConfig()
public FTPConfig(java.lang.String name, XMLProperties xmlProps) throws ConfException
name
- The name of the FTP configurationxmlProps
- XML configuration properties containing a valid
FTPConfig element.
ConfException
- if this object cannot be initialised.Method Detail |
---|
public void setServer(java.lang.String server)
server
- Server name.public java.lang.String getServer()
public void setPort(java.lang.String port)
port
- Port number.public java.lang.String getPort()
public void setTransferMode(java.lang.String transfer)
transfer
- Transfer mode.public java.lang.String getTransferMode()
public void setConnectionMode(java.lang.String connection)
connection
- Connection mode.public java.lang.String getConnectionMode()
public void setUserName(java.lang.String userName)
userName
- User name used to establish database connection.public java.lang.String getUserName()
public void setPassword(java.lang.String password)
password
- Password used by this object to establish a database
connection.public java.lang.String getPassword()
public org.apache.commons.net.ftp.FTPClient createFTPClient() throws java.io.IOException
java.io.IOException
- if a connection cannot be established.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |