net.sf.hermesftp.common
Interface FtpServerOptions

All Known Implementing Classes:
FtpServerOptionsImpl

public interface FtpServerOptions

Defines the contract for classes representing the static server options retrieved from the configuration file.

Author:
Lars Behnke

Method Summary
 java.lang.Integer[] getAllowedPorts()
          Returns a set of all allowed passive ports.
 java.lang.String getAppBuildInfo()
          Returns the application build info as defined in the POM file.
 java.lang.String getAppTitle()
          Returns the application title as defined in the POM file.
 java.lang.String getAppVersion()
          Returns the application version as defined in the POM file.
 boolean getBoolean(java.lang.String optionName, boolean defaultValue)
          Returns a an option as boolean value.
 int getBufferSize()
          Read the buffer size for downloading or uploading files.
 int getFtpPort()
          Returns the FTP port.
 int getImplicitSslPort()
          Returns the implicit SSL port.
 int getInt(java.lang.String optionName, int defaultValue)
          Returns a an option as integer value.
 int[] getIntArray(java.lang.String optionName, int[] defaultValues)
          Returns an array of integer options.
 java.util.Properties getProperties()
          Getter method for the java bean properties.
 java.lang.String getProperty(java.lang.String key)
          Convenience method for accessing the options.
 java.lang.String getRootDir()
          Getter method for the server side remote directory.
 javax.net.ssl.SSLContext getSslContext()
          Returns the SSL context to be used for creating SSL sockets.
 java.lang.String getString(java.lang.String optionName, java.lang.String defaultValue)
          Returns a an option as string value.
 java.lang.String[] getStringArray(java.lang.String optionName, java.lang.String[] defaultValues)
          Returns an array of options.
 java.util.Properties getSystemProperties()
          Getter method for the java bean systemProperties.
 void setProperties(java.util.Properties properties)
          Setter method for the java bean properties.
 

Method Detail

getProperties

java.util.Properties getProperties()
Getter method for the java bean properties.

Returns:
Returns the value of the java bean properties.

setProperties

void setProperties(java.util.Properties properties)
Setter method for the java bean properties.

Parameters:
properties - The value of properties to set.

getProperty

java.lang.String getProperty(java.lang.String key)
Convenience method for accessing the options.

Parameters:
key - The option key.
Returns:
The option value as string.

getBufferSize

int getBufferSize()
Read the buffer size for downloading or uploading files. The default buffer size is 1024 bytes.

Returns:
The buffer size;

getRootDir

java.lang.String getRootDir()
Getter method for the server side remote directory.

Returns:
The directory

getFtpPort

int getFtpPort()
Returns the FTP port.

Returns:
The port.

getImplicitSslPort

int getImplicitSslPort()
Returns the implicit SSL port.

Returns:
The port.

getBoolean

boolean getBoolean(java.lang.String optionName,
                   boolean defaultValue)
Returns a an option as boolean value.

Parameters:
optionName - The name of the option.
defaultValue - The default value.
Returns:
The boolean value.

getInt

int getInt(java.lang.String optionName,
           int defaultValue)
Returns a an option as integer value.

Parameters:
optionName - The name of the option.
defaultValue - The default value.
Returns:
The integer.

getString

java.lang.String getString(java.lang.String optionName,
                           java.lang.String defaultValue)
Returns a an option as string value.

Parameters:
optionName - The name of the option.
defaultValue - The default value.
Returns:
The string.

getStringArray

java.lang.String[] getStringArray(java.lang.String optionName,
                                  java.lang.String[] defaultValues)
Returns an array of options. The corresponding property value has to be a comma separated list.

Parameters:
optionName - The name of the option.
defaultValues - The default values.
Returns:
The array.

getIntArray

int[] getIntArray(java.lang.String optionName,
                  int[] defaultValues)
Returns an array of integer options. The corresponding property value has to be a comma separated list.

Parameters:
optionName - The name of the option.
defaultValues - The default values.
Returns:
The array.

getAllowedPorts

java.lang.Integer[] getAllowedPorts()
Returns a set of all allowed passive ports.

Returns:
The set.

getSslContext

javax.net.ssl.SSLContext getSslContext()
                                       throws FtpConfigException
Returns the SSL context to be used for creating SSL sockets.

Returns:
The SSL context.
Throws:
FtpConfigException - Error initializing SSL context or keystore.

getSystemProperties

java.util.Properties getSystemProperties()
Getter method for the java bean systemProperties.

Returns:
Returns the value of the java bean systemProperties.

getAppTitle

java.lang.String getAppTitle()
Returns the application title as defined in the POM file.

Returns:
The application title.

getAppVersion

java.lang.String getAppVersion()
Returns the application version as defined in the POM file.

Returns:
The application version.

getAppBuildInfo

java.lang.String getAppBuildInfo()
Returns the application build info as defined in the POM file.

Returns:
The application build info.


Copyright © 2005-2007 Lars Behnke. All Rights Reserved.