|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.vfs.FileSystemConfigBuilder
org.apache.commons.vfs.provider.ftp.FtpFileSystemConfigBuilder
public class FtpFileSystemConfigBuilder
The config builder for various ftp configuration options
Field Summary | |
---|---|
private static FtpFileSystemConfigBuilder |
builder
|
private static java.lang.String |
DATA_TIMEOUT
|
private static java.lang.String |
DEFAULT_DATE_FORMAT
|
private static java.lang.String |
FACTORY_KEY
|
private static java.lang.String |
PASSIVE_MODE
|
private static java.lang.String |
RECENT_DATE_FORMAT
|
private static java.lang.String |
SERVER_LANGUAGE_CODE
|
private static java.lang.String |
SERVER_TIME_ZONE_ID
|
private static java.lang.String |
SHORT_MONTH_NAMES
|
private static java.lang.String |
USER_DIR_IS_ROOT
|
Constructor Summary | |
---|---|
private |
FtpFileSystemConfigBuilder()
|
Method Summary | |
---|---|
protected java.lang.Class |
getConfigClass()
|
java.lang.Integer |
getDataTimeout(FileSystemOptions opts)
|
java.lang.String |
getDefaultDateFormat(FileSystemOptions opts)
get the language code used by the server. |
java.lang.String |
getEntryParser(FileSystemOptions opts)
|
org.apache.commons.net.ftp.parser.FTPFileEntryParserFactory |
getEntryParserFactory(FileSystemOptions opts)
|
static FtpFileSystemConfigBuilder |
getInstance()
|
java.lang.Boolean |
getPassiveMode(FileSystemOptions opts)
|
java.lang.String |
getRecentDateFormat(FileSystemOptions opts)
see FTPClientConfig for details and examples. |
java.lang.String |
getServerLanguageCode(FileSystemOptions opts)
get the language code used by the server. |
java.lang.String |
getServerTimeZoneId(FileSystemOptions opts)
see FTPClientConfig for details and examples. |
java.lang.String[] |
getShortMonthNames(FileSystemOptions opts)
see FTPClientConfig for details and examples. |
java.lang.Boolean |
getUserDirIsRoot(FileSystemOptions opts)
|
void |
setDataTimeout(FileSystemOptions opts,
java.lang.Integer dataTimeout)
set the data timeout for the ftp client. If you set the dataTimeout to null no dataTimeout will be set on the
ftp client. |
void |
setDefaultDateFormat(FileSystemOptions opts,
java.lang.String defaultDateFormat)
set the language code used by the server. |
void |
setEntryParser(FileSystemOptions opts,
java.lang.String key)
set the FQCN of your FileEntryParser used to parse the directory listing from your server. If you do not use the default commons-net FTPFileEntryParserFactory e.g. |
void |
setEntryParserFactory(FileSystemOptions opts,
org.apache.commons.net.ftp.parser.FTPFileEntryParserFactory factory)
FTPFileEntryParserFactory which will be used for ftp-entry parsing |
void |
setPassiveMode(FileSystemOptions opts,
boolean passiveMode)
enter into passive mode |
void |
setRecentDateFormat(FileSystemOptions opts,
java.lang.String recentDateFormat)
see FTPClientConfig for details and examples. |
void |
setServerLanguageCode(FileSystemOptions opts,
java.lang.String serverLanguageCode)
set the language code used by the server. |
void |
setServerTimeZoneId(FileSystemOptions opts,
java.lang.String serverTimeZoneId)
see FTPClientConfig for details and examples. |
void |
setShortMonthNames(FileSystemOptions opts,
java.lang.String[] shortMonthNames)
see FTPClientConfig for details and examples. |
void |
setUserDirIsRoot(FileSystemOptions opts,
boolean userDirIsRoot)
use user directory as root (do not change to fs root) |
Methods inherited from class org.apache.commons.vfs.FileSystemConfigBuilder |
---|
getParam, hasParam, setParam |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final FtpFileSystemConfigBuilder builder
private static final java.lang.String FACTORY_KEY
private static final java.lang.String PASSIVE_MODE
private static final java.lang.String USER_DIR_IS_ROOT
private static final java.lang.String DATA_TIMEOUT
private static final java.lang.String SERVER_LANGUAGE_CODE
private static final java.lang.String DEFAULT_DATE_FORMAT
private static final java.lang.String RECENT_DATE_FORMAT
private static final java.lang.String SERVER_TIME_ZONE_ID
private static final java.lang.String SHORT_MONTH_NAMES
Constructor Detail |
---|
private FtpFileSystemConfigBuilder()
Method Detail |
---|
public static FtpFileSystemConfigBuilder getInstance()
public void setEntryParserFactory(FileSystemOptions opts, org.apache.commons.net.ftp.parser.FTPFileEntryParserFactory factory)
opts
- factory
- instance of your factorypublic org.apache.commons.net.ftp.parser.FTPFileEntryParserFactory getEntryParserFactory(FileSystemOptions opts)
opts
- setEntryParserFactory(org.apache.commons.vfs.FileSystemOptions, org.apache.commons.net.ftp.parser.FTPFileEntryParserFactory)
public void setEntryParser(FileSystemOptions opts, java.lang.String key)
setEntryParserFactory(org.apache.commons.vfs.FileSystemOptions, org.apache.commons.net.ftp.parser.FTPFileEntryParserFactory)
this is the "key" parameter passed as argument into your custom factory
opts
- key
- public java.lang.String getEntryParser(FileSystemOptions opts)
opts
- setEntryParser(org.apache.commons.vfs.FileSystemOptions, java.lang.String)
protected java.lang.Class getConfigClass()
getConfigClass
in class FileSystemConfigBuilder
public void setPassiveMode(FileSystemOptions opts, boolean passiveMode)
opts
- passiveMode
- public java.lang.Boolean getPassiveMode(FileSystemOptions opts)
opts
- setPassiveMode(org.apache.commons.vfs.FileSystemOptions, boolean)
public void setUserDirIsRoot(FileSystemOptions opts, boolean userDirIsRoot)
opts
- userDirIsRoot
- public java.lang.Boolean getUserDirIsRoot(FileSystemOptions opts)
opts
- setUserDirIsRoot(org.apache.commons.vfs.FileSystemOptions, boolean)
public java.lang.Integer getDataTimeout(FileSystemOptions opts)
opts
- setDataTimeout(org.apache.commons.vfs.FileSystemOptions, java.lang.Integer)
public void setDataTimeout(FileSystemOptions opts, java.lang.Integer dataTimeout)
null
no dataTimeout will be set on the
ftp client.
opts
- dataTimeout
- public java.lang.String getServerLanguageCode(FileSystemOptions opts)
FTPClientConfig
for details and examples.
public void setServerLanguageCode(FileSystemOptions opts, java.lang.String serverLanguageCode)
FTPClientConfig
for details and examples.
public java.lang.String getDefaultDateFormat(FileSystemOptions opts)
FTPClientConfig
for details and examples.
public void setDefaultDateFormat(FileSystemOptions opts, java.lang.String defaultDateFormat)
FTPClientConfig
for details and examples.
public java.lang.String getRecentDateFormat(FileSystemOptions opts)
FTPClientConfig
for details and examples.
public void setRecentDateFormat(FileSystemOptions opts, java.lang.String recentDateFormat)
FTPClientConfig
for details and examples.
public java.lang.String getServerTimeZoneId(FileSystemOptions opts)
FTPClientConfig
for details and examples.
public void setServerTimeZoneId(FileSystemOptions opts, java.lang.String serverTimeZoneId)
FTPClientConfig
for details and examples.
public java.lang.String[] getShortMonthNames(FileSystemOptions opts)
FTPClientConfig
for details and examples.
public void setShortMonthNames(FileSystemOptions opts, java.lang.String[] shortMonthNames)
FTPClientConfig
for details and examples.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |