org.gudy.azureus2.plugins
Interface PluginConfig

All Known Implementing Classes:
PluginConfigImpl, RPPluginConfig

public interface PluginConfig

This class provides a way for a plugin to get and set configuration settings - both for the plugin itself and for core settings as well.

This class interface contains four different variations of get and set parameter methods:

The first set of methods are deprecated and should not be used in general - this is because the method names were ambiguous and it wasn't always obvious what data you were trying to get or set.

The second set of methods do what the first set of methods were primarily intended for - you can use these methods to get or set some core parameters. You should use the parameter names defined as constants in this interface (the ones labelled CORE_PARAM). These parameters will be properly supported by Azureus, even if the way these values are stored or handled differently in the Azureus core itself.

Attempting to set or get parameters not mentioned here should raise an error (in some cases in the past, this wasn't always enforced by the first set of methods.

The third set of methods allow you to modify configuration settings which are stored directly inside Azureus. These settings may change (without warning) between versions, so there is no guarantee that plugins that use these values will behave properly in different versions of Azureus.

The last set of methods are used to store and retrieve data intended exclusively for the use of the plugin itself, which is what you will be using most of the time.


Field Summary
static String CORE_PARAM_BOOLEAN_AUTO_SPEED_ON
           
static String CORE_PARAM_BOOLEAN_AUTO_SPEED_SEEDING_ON
           
static String CORE_PARAM_BOOLEAN_FRIENDLY_HASH_CHECKING
           
static String CORE_PARAM_BOOLEAN_MAX_ACTIVE_SEEDING
           
static String CORE_PARAM_BOOLEAN_MAX_UPLOAD_SPEED_SEEDING
           
static String CORE_PARAM_BOOLEAN_NEW_SEEDS_START_AT_TOP
           
static String CORE_PARAM_BOOLEAN_NEW_TORRENTS_START_AS_STOPPED
           
static String CORE_PARAM_BOOLEAN_SOCKS_PROXY_NO_INWARD_CONNECTION
           
static String CORE_PARAM_INT_INCOMING_TCP_PORT
           
static String CORE_PARAM_INT_INCOMING_UDP_PORT
           
static String CORE_PARAM_INT_MAX_ACTIVE
           
static String CORE_PARAM_INT_MAX_ACTIVE_SEEDING
           
static String CORE_PARAM_INT_MAX_CONNECTIONS_GLOBAL
           
static String CORE_PARAM_INT_MAX_CONNECTIONS_PER_TORRENT
           
static String CORE_PARAM_INT_MAX_DOWNLOAD_SPEED_KBYTES_PER_SEC
           
static String CORE_PARAM_INT_MAX_DOWNLOADS
           
static String CORE_PARAM_INT_MAX_UPLOAD_SPEED_KBYTES_PER_SEC
           
static String CORE_PARAM_INT_MAX_UPLOAD_SPEED_SEEDING_KBYTES_PER_SEC
           
static String CORE_PARAM_INT_MAX_UPLOADS
           
static String CORE_PARAM_INT_MAX_UPLOADS_SEEDING
           
static String CORE_PARAM_STRING_DEFAULT_SAVE_PATH
           
static String CORE_PARAM_STRING_LOCAL_BIND_IP
          Semicolon seperated list containing: IP
NetworkInterface name (ex.
static String GUI_PARAM_INT_SWT_REFRESH_IN_MS
           
 
Method Summary
 void addListener(PluginConfigListener l)
           
 PluginConfigSource enableExternalConfigSource()
          Enable the plugin to store configuration parameters into a separate external configuration file.
 boolean getBooleanParameter(String key)
          Deprecated. Use getUnsafeBooleanParameter(String) for internal core parameters, or getCoreBooleanParameter(String) for core parameters defined here.
 boolean getBooleanParameter(String key, boolean default_value)
          Deprecated. Use getUnsafeBooleanParameter(String, boolean) for internal core parameters, or getCoreBooleanParameter(String, boolean) for core parameters defined here.
 byte[] getByteParameter(String key)
          Deprecated. Use getUnsafeByteParameter(String) for internal core parameters, or getCoreByteParameter(String) for core parameters defined here.
 byte[] getByteParameter(String key, byte[] default_value)
          Deprecated. Use getUnsafeByteParameter(String, byte[]) for internal core parameters, or getCoreByteParameter(String, byte[]) for core parameters defined here.
 boolean getCoreBooleanParameter(String key)
          Returns the value of a core boolean parameter.
 boolean getCoreBooleanParameter(String key, boolean default_value)
          Returns the value of a core boolean parameter.
 byte[] getCoreByteParameter(String key)
          Returns the value of a core byte array parameter.
 byte[] getCoreByteParameter(String key, byte[] default_value)
          Returns the value of a core byte array parameter.
 int[] getCoreColorParameter(String key)
          Returns the value of a core color parameter.
 int[] getCoreColorParameter(String key, int[] default_value)
          Returns the value of a core color parameter.
 float getCoreFloatParameter(String key)
          Returns the value of a core float parameter.
 float getCoreFloatParameter(String key, float default_value)
          Returns the value of a core float parameter.
 int getCoreIntParameter(String key)
          Returns the value of a core int parameter.
 int getCoreIntParameter(String key, int default_value)
          Returns the value of a core int parameter.
 long getCoreLongParameter(String key)
          Returns the value of a core long parameter.
 long getCoreLongParameter(String key, long default_value)
          Returns the value of a core long parameter.
 String getCoreStringParameter(String key)
          Returns the value of a core string parameter.
 String getCoreStringParameter(String key, String default_value)
          Returns the value of a core string parameter.
 float getFloatParameter(String key)
          Deprecated. Use getUnsafeFloatParameter(String) for internal core parameters, or getCoreFloatParameter(String) for core parameters defined here.
 float getFloatParameter(String key, float default_value)
          Deprecated. Use getUnsafeFloatParameter(String, float) for internal core parameters, or getCoreFloatParameter(String, float) for core parameters defined here.
 int getIntParameter(String key)
          Deprecated. Use getUnsafeIntParameter(String) for internal core parameters, or getCoreIntParameter(String) for core parameters defined here.
 int getIntParameter(String key, int default_value)
          Deprecated. Use getUnsafeIntParameter(String, int) for internal core parameters, or getCoreIntParameter(String, int) for core parameters defined here.
 long getLongParameter(String key)
          Deprecated. Use getUnsafeLongParameter(String) for internal core parameters, or getCoreLongParameter(String) for core parameters defined here.
 long getLongParameter(String key, long default_value)
          Deprecated. Use getUnsafeLongParameter(String, long) for internal core parameters, or getCoreLongParameter(String, long) for core parameters defined here.
 ConfigParameter getParameter(String key)
           
 boolean getPluginBooleanParameter(String key)
          Returns the value of a plugin boolean parameter.
 boolean getPluginBooleanParameter(String key, boolean default_value)
          Returns the value of a plugin boolean parameter.
 byte[] getPluginByteParameter(String key)
          Returns the value of a plugin byte array parameter.
 byte[] getPluginByteParameter(String key, byte[] default_value)
          Returns the value of a plugin byte array parameter.
 int[] getPluginColorParameter(String key)
          Returns the value of a plugin color parameter.
 int[] getPluginColorParameter(String key, int[] default_value)
          Returns the value of a plugin color parameter.
 String getPluginConfigKeyPrefix()
           
 PluginConfigSource getPluginConfigSource()
          Returns the PluginConfigSource object used for this plugin configuration (or null if an external configuration object isn't used).
 float getPluginFloatParameter(String key)
          Returns the value of a plugin float parameter.
 float getPluginFloatParameter(String key, float default_value)
          Returns the value of a plugin float parameter.
 int getPluginIntParameter(String key)
          Returns the value of a plugin int parameter.
 int getPluginIntParameter(String key, int default_value)
          Returns the value of a plugin int parameter.
 List getPluginListParameter(String key, List default_value)
          Returns the value of a plugin list parameter.
 long getPluginLongParameter(String key)
          Returns the value of a plugin long parameter.
 long getPluginLongParameter(String key, long default_value)
          Returns the value of a plugin long parameter.
 Map getPluginMapParameter(String key, Map default_value)
          Returns the value of a plugin map parameter.
 ConfigParameter getPluginParameter(String key)
           
 String[] getPluginStringListParameter(String key)
          Returns the value of a plugin string-list parameter.
 String getPluginStringParameter(String key)
          Returns the value of a plugin string parameter.
 String getPluginStringParameter(String key, String default_value)
          Returns the value of a plugin string parameter.
 File getPluginUserFile(String name)
          Returns a file that can be used by the plugin to save user-specific state.
 String getStringParameter(String key)
          Deprecated. Use getUnsafeStringParameter(String) for internal core parameters, or getCoreStringParameter(String) for core parameters defined here.
 String getStringParameter(String key, String default_value)
          Deprecated. Use getUnsafeStringParameter(String, String) for internal core parameters, or getCoreStringParameter(String, String) for core parameters defined here.
 boolean getUnsafeBooleanParameter(String key)
          Returns the value of a core boolean parameter.
 boolean getUnsafeBooleanParameter(String key, boolean default_value)
          Returns the value of a core boolean parameter.
 byte[] getUnsafeByteParameter(String key)
          Returns the value of a core byte array parameter.
 byte[] getUnsafeByteParameter(String key, byte[] default_value)
          Returns the value of a core byte array parameter.
 int[] getUnsafeColorParameter(String key)
          Returns the value of a core color parameter.
 int[] getUnsafeColorParameter(String key, int[] default_value)
          Returns the value of a core color parameter.
 float getUnsafeFloatParameter(String key)
          Returns the value of a core float parameter.
 float getUnsafeFloatParameter(String key, float default_value)
          Returns the value of a core float parameter.
 int getUnsafeIntParameter(String key)
          Returns the value of a core int parameter.
 int getUnsafeIntParameter(String key, int default_value)
          Returns the value of a core int parameter.
 long getUnsafeLongParameter(String key)
          Returns the value of a core long parameter.
 long getUnsafeLongParameter(String key, long default_value)
          Returns the value of a core long parameter.
 Map getUnsafeParameterList()
          Returns a map giving parameter names -> parameter values.
 String getUnsafeStringParameter(String key)
          Returns the value of a core string parameter.
 String getUnsafeStringParameter(String key, String default_value)
          Returns the value of a core string parameter.
 boolean hasParameter(String param_name)
          Returns true if a core parameter with the given name exists.
 boolean hasPluginParameter(String param_name)
          Returns true if a plugin parameter with the given name exists.
 boolean isNewInstall()
           
 boolean removePluginColorParameter(String key)
          Removes the plugin color parameter with the given name.
 boolean removePluginParameter(String key)
          Removes the plugin parameter with the given name.
 void save()
          make sure you save it after making changes!
 void setBooleanParameter(String key, boolean value)
          Deprecated. Use setUnsafeBooleanParameter(String, boolean) for internal core parameters, or setCoreBooleanParameter(String, boolean) for core parameters defined here.
 void setByteParameter(String key, byte[] value)
          Deprecated. Use setUnsafeByteParameter(String, byte[]) for internal core parameters, or setCoreByteParameter(String, byte[]) for core parameters defined here.
 void setCoreBooleanParameter(String key, boolean value)
          Sets the value of a core boolean parameter.
 void setCoreByteParameter(String key, byte[] value)
          Sets the value of a core byte array parameter.
 void setCoreColorParameter(String key, int[] value)
          Sets the value of a core byte array parameter.
 void setCoreColorParameter(String key, int[] value, boolean override)
          Sets the value of a core byte array parameter.
 void setCoreFloatParameter(String key, float value)
          Sets the value of a core float parameter.
 void setCoreIntParameter(String key, int value)
          Sets the value of a core int parameter.
 void setCoreLongParameter(String key, long value)
          Sets the value of a core long parameter.
 void setCoreStringParameter(String key, String value)
          Sets the value of a core string parameter.
 void setFloatParameter(String key, float value)
          Deprecated. Use setUnsafeFloatParameter(String, float) for internal core parameters, or setCoreFloatParameter(String, float) for core parameters defined here.
 void setIntParameter(String key, int value)
          Deprecated. Use setUnsafeIntParameter(String, int) for internal core parameters, or setCoreIntParameter(String, int) for core parameters defined here.
 void setLongParameter(String key, long value)
          Deprecated. Use setUnsafeLongParameter(String, long) for internal core parameters, or setCoreLongParameter(String, long) for core parameters defined here.
 void setPluginColorParameter(String key, int[] value)
          Sets the value of a plugin color parameter.
 void setPluginColorParameter(String key, int[] value, boolean override)
          Sets the value of a plugin color parameter.
 void setPluginConfigKeyPrefix(String _key)
           
 void setPluginConfigSource(PluginConfigSource source)
          Sets the plugin configuration source object to use for storing parameters for this plugin config object.
 void setPluginListParameter(String key, List value)
          Sets the value of a plugin list parameter.
 void setPluginMapParameter(String key, Map value)
          Sets the value of a plugin map parameter.
 void setPluginParameter(String key, boolean value)
          Sets the value of a plugin boolean parameter.
 void setPluginParameter(String key, byte[] value)
          Sets the value of a plugin byte array parameter.
 void setPluginParameter(String key, float value)
          Sets the value of a plugin float parameter.
 void setPluginParameter(String key, int value)
          Sets the value of a plugin int parameter.
 void setPluginParameter(String key, int value, boolean global)
          Sets the value of a plugin int parameter.
 void setPluginParameter(String key, long value)
          Sets the value of a plugin long parameter.
 void setPluginParameter(String key, String value)
          Sets the value of a plugin string parameter.
 void setPluginStringListParameter(String key, String[] value)
          Sets the value of a plugin string-list parameter.
 void setStringParameter(String key, String value)
          Deprecated. Use setUnsafeStringParameter(String, String) for internal core parameters, or setCoreStringParameter(String, String) for core parameters defined here.
 void setUnsafeBooleanParameter(String key, boolean value)
          Sets the value of a core boolean parameter.
 void setUnsafeByteParameter(String key, byte[] value)
          Sets the value of a core byte array parameter.
 void setUnsafeColorParameter(String key, int[] value)
          Returns the value of a core color parameter.
 void setUnsafeColorParameter(String key, int[] value, boolean override)
          Returns the value of a core color parameter.
 void setUnsafeFloatParameter(String key, float value)
          Sets the value of a core float parameter.
 void setUnsafeIntParameter(String key, int value)
          Sets the value of a core int parameter.
 void setUnsafeLongParameter(String key, long value)
          Sets the value of a core long parameter.
 void setUnsafeStringParameter(String key, String value)
          Sets the value of a core string parameter.
 

Field Detail

CORE_PARAM_INT_MAX_UPLOAD_SPEED_KBYTES_PER_SEC

static final String CORE_PARAM_INT_MAX_UPLOAD_SPEED_KBYTES_PER_SEC
See Also:
Constant Field Values

CORE_PARAM_INT_MAX_UPLOAD_SPEED_SEEDING_KBYTES_PER_SEC

static final String CORE_PARAM_INT_MAX_UPLOAD_SPEED_SEEDING_KBYTES_PER_SEC
See Also:
Constant Field Values

CORE_PARAM_INT_MAX_DOWNLOAD_SPEED_KBYTES_PER_SEC

static final String CORE_PARAM_INT_MAX_DOWNLOAD_SPEED_KBYTES_PER_SEC
See Also:
Constant Field Values

CORE_PARAM_INT_MAX_CONNECTIONS_PER_TORRENT

static final String CORE_PARAM_INT_MAX_CONNECTIONS_PER_TORRENT
See Also:
Constant Field Values

CORE_PARAM_INT_MAX_CONNECTIONS_GLOBAL

static final String CORE_PARAM_INT_MAX_CONNECTIONS_GLOBAL
See Also:
Constant Field Values

CORE_PARAM_INT_MAX_DOWNLOADS

static final String CORE_PARAM_INT_MAX_DOWNLOADS
See Also:
Constant Field Values

CORE_PARAM_INT_MAX_ACTIVE

static final String CORE_PARAM_INT_MAX_ACTIVE
See Also:
Constant Field Values

CORE_PARAM_INT_MAX_ACTIVE_SEEDING

static final String CORE_PARAM_INT_MAX_ACTIVE_SEEDING
See Also:
Constant Field Values

CORE_PARAM_INT_MAX_UPLOADS

static final String CORE_PARAM_INT_MAX_UPLOADS
See Also:
Constant Field Values

CORE_PARAM_INT_MAX_UPLOADS_SEEDING

static final String CORE_PARAM_INT_MAX_UPLOADS_SEEDING
See Also:
Constant Field Values

CORE_PARAM_BOOLEAN_AUTO_SPEED_ON

static final String CORE_PARAM_BOOLEAN_AUTO_SPEED_ON
See Also:
Constant Field Values

CORE_PARAM_BOOLEAN_AUTO_SPEED_SEEDING_ON

static final String CORE_PARAM_BOOLEAN_AUTO_SPEED_SEEDING_ON
See Also:
Constant Field Values

CORE_PARAM_BOOLEAN_MAX_UPLOAD_SPEED_SEEDING

static final String CORE_PARAM_BOOLEAN_MAX_UPLOAD_SPEED_SEEDING
See Also:
Constant Field Values

CORE_PARAM_BOOLEAN_MAX_ACTIVE_SEEDING

static final String CORE_PARAM_BOOLEAN_MAX_ACTIVE_SEEDING
See Also:
Constant Field Values

CORE_PARAM_BOOLEAN_SOCKS_PROXY_NO_INWARD_CONNECTION

static final String CORE_PARAM_BOOLEAN_SOCKS_PROXY_NO_INWARD_CONNECTION
See Also:
Constant Field Values

CORE_PARAM_BOOLEAN_NEW_SEEDS_START_AT_TOP

static final String CORE_PARAM_BOOLEAN_NEW_SEEDS_START_AT_TOP
See Also:
Constant Field Values

CORE_PARAM_STRING_LOCAL_BIND_IP

static final String CORE_PARAM_STRING_LOCAL_BIND_IP
Semicolon seperated list containing: IP
NetworkInterface name (ex. eth10)
NetworkInterface name with IP index in square brackets (ex. eth6[0])

Since:
2.3.0.5
See Also:
Constant Field Values

CORE_PARAM_BOOLEAN_FRIENDLY_HASH_CHECKING

static final String CORE_PARAM_BOOLEAN_FRIENDLY_HASH_CHECKING
See Also:
Constant Field Values

GUI_PARAM_INT_SWT_REFRESH_IN_MS

static final String GUI_PARAM_INT_SWT_REFRESH_IN_MS
Since:
3.0.4.3
See Also:
Constant Field Values

CORE_PARAM_BOOLEAN_NEW_TORRENTS_START_AS_STOPPED

static final String CORE_PARAM_BOOLEAN_NEW_TORRENTS_START_AS_STOPPED
Since:
3.0.4.3
See Also:
Constant Field Values

CORE_PARAM_INT_INCOMING_TCP_PORT

static final String CORE_PARAM_INT_INCOMING_TCP_PORT
Since:
3.0.5.3
See Also:
Constant Field Values

CORE_PARAM_INT_INCOMING_UDP_PORT

static final String CORE_PARAM_INT_INCOMING_UDP_PORT
Since:
3.0.5.3
See Also:
Constant Field Values

CORE_PARAM_STRING_DEFAULT_SAVE_PATH

static final String CORE_PARAM_STRING_DEFAULT_SAVE_PATH
Since:
3.1.1.1
See Also:
Constant Field Values
Method Detail

getBooleanParameter

boolean getBooleanParameter(String key)
Deprecated. Use getUnsafeBooleanParameter(String) for internal core parameters, or getCoreBooleanParameter(String) for core parameters defined here.

Returns the value of a core boolean parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
2.0.4.2

getBooleanParameter

boolean getBooleanParameter(String key,
                            boolean default_value)
Deprecated. Use getUnsafeBooleanParameter(String, boolean) for internal core parameters, or getCoreBooleanParameter(String, boolean) for core parameters defined here.

Returns the value of a core boolean parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.0.6.0

getByteParameter

byte[] getByteParameter(String key)
Deprecated. Use getUnsafeByteParameter(String) for internal core parameters, or getCoreByteParameter(String) for core parameters defined here.

Returns the value of a core byte array parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getByteParameter

byte[] getByteParameter(String key,
                        byte[] default_value)
Deprecated. Use getUnsafeByteParameter(String, byte[]) for internal core parameters, or getCoreByteParameter(String, byte[]) for core parameters defined here.

Returns the value of a core byte array parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.1.0.2

getFloatParameter

float getFloatParameter(String key)
Deprecated. Use getUnsafeFloatParameter(String) for internal core parameters, or getCoreFloatParameter(String) for core parameters defined here.

Returns the value of a core float parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
2.1.0.0

getFloatParameter

float getFloatParameter(String key,
                        float default_value)
Deprecated. Use getUnsafeFloatParameter(String, float) for internal core parameters, or getCoreFloatParameter(String, float) for core parameters defined here.

Returns the value of a core float parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.7

getIntParameter

int getIntParameter(String key)
Deprecated. Use getUnsafeIntParameter(String) for internal core parameters, or getCoreIntParameter(String) for core parameters defined here.

Returns the value of a core int parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
2.0.4.2

getIntParameter

int getIntParameter(String key,
                    int default_value)
Deprecated. Use getUnsafeIntParameter(String, int) for internal core parameters, or getCoreIntParameter(String, int) for core parameters defined here.

Returns the value of a core int parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.0.7.0

getLongParameter

long getLongParameter(String key)
Deprecated. Use getUnsafeLongParameter(String) for internal core parameters, or getCoreLongParameter(String) for core parameters defined here.

Returns the value of a core long parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getLongParameter

long getLongParameter(String key,
                      long default_value)
Deprecated. Use getUnsafeLongParameter(String, long) for internal core parameters, or getCoreLongParameter(String, long) for core parameters defined here.

Returns the value of a core long parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.7

getStringParameter

String getStringParameter(String key)
Deprecated. Use getUnsafeStringParameter(String) for internal core parameters, or getCoreStringParameter(String) for core parameters defined here.

Returns the value of a core string parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
2.0.4.2

getStringParameter

String getStringParameter(String key,
                          String default_value)
Deprecated. Use getUnsafeStringParameter(String, String) for internal core parameters, or getCoreStringParameter(String, String) for core parameters defined here.

Returns the value of a core string parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.1.0.0

setBooleanParameter

void setBooleanParameter(String key,
                         boolean value)
Deprecated. Use setUnsafeBooleanParameter(String, boolean) for internal core parameters, or setCoreBooleanParameter(String, boolean) for core parameters defined here.

Sets the value of a core boolean parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.

setByteParameter

void setByteParameter(String key,
                      byte[] value)
Deprecated. Use setUnsafeByteParameter(String, byte[]) for internal core parameters, or setCoreByteParameter(String, byte[]) for core parameters defined here.

Sets the value of a core byte array parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.7

setFloatParameter

void setFloatParameter(String key,
                       float value)
Deprecated. Use setUnsafeFloatParameter(String, float) for internal core parameters, or setCoreFloatParameter(String, float) for core parameters defined here.

Sets the value of a core float parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.7

setIntParameter

void setIntParameter(String key,
                     int value)
Deprecated. Use setUnsafeIntParameter(String, int) for internal core parameters, or setCoreIntParameter(String, int) for core parameters defined here.

Sets the value of a core int parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
2.0.8.0

setLongParameter

void setLongParameter(String key,
                      long value)
Deprecated. Use setUnsafeLongParameter(String, long) for internal core parameters, or setCoreLongParameter(String, long) for core parameters defined here.

Sets the value of a core long parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.7

setStringParameter

void setStringParameter(String key,
                        String value)
Deprecated. Use setUnsafeStringParameter(String, String) for internal core parameters, or setCoreStringParameter(String, String) for core parameters defined here.

Sets the value of a core string parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.7

getCoreBooleanParameter

boolean getCoreBooleanParameter(String key)
Returns the value of a core boolean parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreBooleanParameter

boolean getCoreBooleanParameter(String key,
                                boolean default_value)
Returns the value of a core boolean parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreByteParameter

byte[] getCoreByteParameter(String key)
Returns the value of a core byte array parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreByteParameter

byte[] getCoreByteParameter(String key,
                            byte[] default_value)
Returns the value of a core byte array parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.5.3

getCoreColorParameter

int[] getCoreColorParameter(String key)
Returns the value of a core color parameter.

It will return null if no color parameter is stored, or an integer array of size 4 representing the red, green and blue values, and a flag indicating if the color is an override of the default or not (0 indicates no override, 1 means it is overridden).

In many cases, the override flag can just be ignored.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.5.3

getCoreColorParameter

int[] getCoreColorParameter(String key,
                            int[] default_value)
Returns the value of a core color parameter.

It will return null if no color parameter is stored, or an integer array of size 4 representing the red, green and blue values, and a flag indicating if the color is an override of the default or not (0 indicates no override, 1 means it is overridden).

In many cases, the override flag can just be ignored.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.5.3

getCoreFloatParameter

float getCoreFloatParameter(String key)
Returns the value of a core float parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreFloatParameter

float getCoreFloatParameter(String key,
                            float default_value)
Returns the value of a core float parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreIntParameter

int getCoreIntParameter(String key)
Returns the value of a core int parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreIntParameter

int getCoreIntParameter(String key,
                        int default_value)
Returns the value of a core int parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreLongParameter

long getCoreLongParameter(String key)
Returns the value of a core long parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreLongParameter

long getCoreLongParameter(String key,
                          long default_value)
Returns the value of a core long parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreStringParameter

String getCoreStringParameter(String key)
Returns the value of a core string parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.4.3

getCoreStringParameter

String getCoreStringParameter(String key,
                              String default_value)
Returns the value of a core string parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.4.3

setCoreBooleanParameter

void setCoreBooleanParameter(String key,
                             boolean value)
Sets the value of a core boolean parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.4.2

setCoreByteParameter

void setCoreByteParameter(String key,
                          byte[] value)
Sets the value of a core byte array parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.4.2

setCoreColorParameter

void setCoreColorParameter(String key,
                           int[] value)
Sets the value of a core byte array parameter.

The value should be an integer array of size 3 representing the red, green and blue values - or null to disable it.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.5.3

setCoreColorParameter

void setCoreColorParameter(String key,
                           int[] value,
                           boolean override)
Sets the value of a core byte array parameter.

The value should be an integer array of size 3 representing the red, green and blue values - or null to disable it.

The override flag is used to indicate if the value being set is overriding the default value. This is mainly used for interface purposes.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
override - true if the value is overridden from the default.
Since:
3.0.5.3

setCoreFloatParameter

void setCoreFloatParameter(String key,
                           float value)
Sets the value of a core float parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.4.2

setCoreIntParameter

void setCoreIntParameter(String key,
                         int value)
Sets the value of a core int parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.4.2

setCoreLongParameter

void setCoreLongParameter(String key,
                          long value)
Sets the value of a core long parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.4.2

setCoreStringParameter

void setCoreStringParameter(String key,
                            String value)
Sets the value of a core string parameter.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.4.2

getPluginBooleanParameter

boolean getPluginBooleanParameter(String key)
Returns the value of a plugin boolean parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
2.0.4.2

getPluginBooleanParameter

boolean getPluginBooleanParameter(String key,
                                  boolean default_value)
Returns the value of a plugin boolean parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.0.4.2

getPluginByteParameter

byte[] getPluginByteParameter(String key)
Returns the value of a plugin byte array parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getPluginByteParameter

byte[] getPluginByteParameter(String key,
                              byte[] default_value)
Returns the value of a plugin byte array parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.2.0.3

getPluginColorParameter

int[] getPluginColorParameter(String key)
Returns the value of a plugin color parameter.

It will return null if no color parameter is stored, or an integer array of size 4 representing the red, green and blue values, and a flag indicating if the color is an override of the default or not (0 indicates no override, 1 means it is overridden).

In many cases, the override flag can just be ignored.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.5.3

getPluginColorParameter

int[] getPluginColorParameter(String key,
                              int[] default_value)
Returns the value of a plugin color parameter.

It will return null if no color parameter is stored, or an integer array of size 4 representing the red, green and blue values, and a flag indicating if the color is an override of the default or not (0 indicates no override, 1 means it is overridden).

In many cases, the override flag can just be ignored.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.5.3

getPluginFloatParameter

float getPluginFloatParameter(String key)
Returns the value of a plugin float parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getPluginFloatParameter

float getPluginFloatParameter(String key,
                              float default_value)
Returns the value of a plugin float parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.7

getPluginIntParameter

int getPluginIntParameter(String key)
Returns the value of a plugin int parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
2.0.4.2

getPluginIntParameter

int getPluginIntParameter(String key,
                          int default_value)
Returns the value of a plugin int parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.0.4.2

getPluginListParameter

List getPluginListParameter(String key,
                            List default_value)
Returns the value of a plugin list parameter. The contents of the list must conform to bencodable rules (e.g. Map, Long, byte[], List)

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.3.0.1

getPluginLongParameter

long getPluginLongParameter(String key)
Returns the value of a plugin long parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getPluginLongParameter

long getPluginLongParameter(String key,
                            long default_value)
Returns the value of a plugin long parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.7

getPluginMapParameter

Map getPluginMapParameter(String key,
                          Map default_value)
Returns the value of a plugin map parameter. The contents of the map must conform to bencodable rules (e.g. Map, Long, byte[], List)

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.3.0.1

getPluginStringParameter

String getPluginStringParameter(String key)
Returns the value of a plugin string parameter.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
2.0.4.2

getPluginStringParameter

String getPluginStringParameter(String key,
                                String default_value)
Returns the value of a plugin string parameter.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
2.0.4.2

getPluginStringListParameter

String[] getPluginStringListParameter(String key)
Returns the value of a plugin string-list parameter. If no value is set, an empty string array will be returned.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.5.3

setPluginParameter

void setPluginParameter(String key,
                        boolean value)
Sets the value of a plugin boolean parameter.

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
2.0.4.2

setPluginParameter

void setPluginParameter(String key,
                        byte[] value)
Sets the value of a plugin byte array parameter.

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
2.1.0.2

setPluginParameter

void setPluginParameter(String key,
                        float value)
Sets the value of a plugin float parameter.

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
3.0.0.7

setPluginParameter

void setPluginParameter(String key,
                        int value)
Sets the value of a plugin int parameter.

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
2.0.4.2

setPluginParameter

void setPluginParameter(String key,
                        int value,
                        boolean global)
Sets the value of a plugin int parameter.

Parameters:
key - The parameter name.
value - The new value for the parameter.
global - Whether or not this parameter should be made externally accessible.
Since:
2.5.0.1

setPluginParameter

void setPluginParameter(String key,
                        long value)
Sets the value of a plugin long parameter.

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
3.0.0.7

setPluginParameter

void setPluginParameter(String key,
                        String value)
Sets the value of a plugin string parameter.

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
2.0.4.2

setPluginStringListParameter

void setPluginStringListParameter(String key,
                                  String[] value)
Sets the value of a plugin string-list parameter.

Parameters:
key - The parameter name.
value - The new value of the parameter.
Since:
3.0.5.3

setPluginColorParameter

void setPluginColorParameter(String key,
                             int[] value)
Sets the value of a plugin color parameter.

The value should be an integer array of size 3 representing the red, green and blue values - or null to disable it.

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
3.0.5.3

setPluginColorParameter

void setPluginColorParameter(String key,
                             int[] value,
                             boolean override)
Sets the value of a plugin color parameter.

The value should be an integer array of size 3 representing the red, green and blue values - or null to disable it.

The override flag is used to indicate if the value being set is overriding the default value. This is mainly used for interface purposes.

Parameters:
key - The parameter name.
value - The new value for the parameter.
override - true if the value is overridden from the default.
Since:
3.0.5.3

setPluginListParameter

void setPluginListParameter(String key,
                            List value)
Sets the value of a plugin list parameter. The contents of the list must conform to bencodable rules (e.g. Map, Long, byte[], List)

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
2.3.0.1

setPluginMapParameter

void setPluginMapParameter(String key,
                           Map value)
Sets the value of a plugin map parameter. The contents of the map must conform to bencodable rules (e.g. Map, Long, byte[], List)

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
2.3.0.1

getUnsafeBooleanParameter

boolean getUnsafeBooleanParameter(String key)
Returns the value of a core boolean parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.7

getUnsafeBooleanParameter

boolean getUnsafeBooleanParameter(String key,
                                  boolean default_value)
Returns the value of a core boolean parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.5

getUnsafeByteParameter

byte[] getUnsafeByteParameter(String key)
Returns the value of a core byte array parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getUnsafeByteParameter

byte[] getUnsafeByteParameter(String key,
                              byte[] default_value)
Returns the value of a core byte array parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.7

getUnsafeColorParameter

int[] getUnsafeColorParameter(String key)
Returns the value of a core color parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

It will return null if no color parameter is stored, or an integer array of size 4 representing the red, green and blue values, and a flag indicating if the color is an override of the default or not (0 indicates no override, 1 means it is overridden).

In many cases, the override flag can just be ignored.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.5.3

getUnsafeColorParameter

int[] getUnsafeColorParameter(String key,
                              int[] default_value)
Returns the value of a core color parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

It will return null if no color parameter is stored, or an integer array of size 4 representing the red, green and blue values, and a flag indicating if the color is an override of the default or not (0 indicates no override, 1 means it is overridden).

In many cases, the override flag can just be ignored.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.5.3

getUnsafeFloatParameter

float getUnsafeFloatParameter(String key)
Returns the value of a core float parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getUnsafeFloatParameter

float getUnsafeFloatParameter(String key,
                              float default_value)
Returns the value of a core float parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.5

getUnsafeIntParameter

int getUnsafeIntParameter(String key)
Returns the value of a core int parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getUnsafeIntParameter

int getUnsafeIntParameter(String key,
                          int default_value)
Returns the value of a core int parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.5

getUnsafeLongParameter

long getUnsafeLongParameter(String key)
Returns the value of a core long parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getUnsafeLongParameter

long getUnsafeLongParameter(String key,
                            long default_value)
Returns the value of a core long parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.5

getUnsafeStringParameter

String getUnsafeStringParameter(String key)
Returns the value of a core string parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
Returns:
The value of the parameter.
Since:
3.0.0.7

getUnsafeStringParameter

String getUnsafeStringParameter(String key,
                                String default_value)
Returns the value of a core string parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name.
default_value - The default value to return if one is not defined.
Returns:
The value of the parameter.
Since:
3.0.0.5

setUnsafeBooleanParameter

void setUnsafeBooleanParameter(String key,
                               boolean value)
Sets the value of a core boolean parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.5

setUnsafeByteParameter

void setUnsafeByteParameter(String key,
                            byte[] value)
Sets the value of a core byte array parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.7

setUnsafeColorParameter

void setUnsafeColorParameter(String key,
                             int[] value)
Returns the value of a core color parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

The value should be an integer array of size 3 representing the red, green and blue values - or null to disable it.

Parameters:
key - The parameter name.
value - The new value for the parameter.
Since:
3.0.5.3

setUnsafeColorParameter

void setUnsafeColorParameter(String key,
                             int[] value,
                             boolean override)
Returns the value of a core color parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

The value should be an integer array of size 3 representing the red, green and blue values - or null to disable it.

The override flag is used to indicate if the value being set is overriding the default value. This is mainly used for interface purposes.

Parameters:
key - The parameter name.
value - The default value to return if one is not defined.
override - true if the value is overridden from the default.
Since:
3.0.5.3

setUnsafeFloatParameter

void setUnsafeFloatParameter(String key,
                             float value)
Sets the value of a core float parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.5

setUnsafeIntParameter

void setUnsafeIntParameter(String key,
                           int value)
Sets the value of a core int parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.5

setUnsafeLongParameter

void setUnsafeLongParameter(String key,
                            long value)
Sets the value of a core long parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.5

setUnsafeStringParameter

void setUnsafeStringParameter(String key,
                              String value)
Sets the value of a core string parameter. Note: the semantics of this method will not be guaranteed - core parameter names may change in the future, and this method will not do any parameter name mapping for you, so take care when using this method.

Parameters:
key - The parameter name, which must be one defined from the above core constants.
value - The new value for the parameter.
Since:
3.0.0.5

removePluginParameter

boolean removePluginParameter(String key)
Removes the plugin parameter with the given name.

Parameters:
key - Name of the parameter.
Returns:
true if the parameter was found and removed.

removePluginColorParameter

boolean removePluginColorParameter(String key)
Removes the plugin color parameter with the given name.

Parameters:
key - Name of the parameter.
Returns:
true if the parameter was found and removed.
Since:
3.0.5.3

getPluginConfigKeyPrefix

String getPluginConfigKeyPrefix()
Returns:
the prefix used when storing configuration values in the config file for this plugin's config parameters
Since:
2.1.0.0

getParameter

ConfigParameter getParameter(String key)

getPluginParameter

ConfigParameter getPluginParameter(String key)

isNewInstall

boolean isNewInstall()

getUnsafeParameterList

Map getUnsafeParameterList()
Returns a map giving parameter names -> parameter values. Value can be Long or String as the type is actually not known by the core (might fix one day). Therefore, float values are actually represented by their String format: boolean - Long 0 or 1 int - Long.intValue float - String value String - String Unsafe methods - existence/semantics of parameters not guaranteed to be maintained across versions If something changes and breaks your plugin, don't come complaining to me

Since:
2.5.0.3

save

void save()
          throws PluginException
make sure you save it after making changes!

Throws:
PluginException
Since:
2.0.8.0

getPluginUserFile

File getPluginUserFile(String name)
Returns a file that can be used by the plugin to save user-specific state.

This will be azureus-user-dir/plugins/plugin-name/name.

Parameters:
name -
Returns:

hasParameter

boolean hasParameter(String param_name)
Returns true if a core parameter with the given name exists.

Parameters:
key - The name of the parameter to check.
Since:
2.5.0.2

hasPluginParameter

boolean hasPluginParameter(String param_name)
Returns true if a plugin parameter with the given name exists.

Parameters:
key - The name of the parameter to check.
Since:
2.5.0.2

addListener

void addListener(PluginConfigListener l)

setPluginConfigKeyPrefix

void setPluginConfigKeyPrefix(String _key)
Parameters:
_key -
Since:
2.5.0.1

enableExternalConfigSource

PluginConfigSource enableExternalConfigSource()
Enable the plugin to store configuration parameters into a separate external configuration file. Note: once this method is called, you need to invoke PluginConfigSource.initialize() for the external configuration file to be properly integrated with Azureus.

When a plugin is first initialised, it should call this method as soon as possible during the initialization stage. This then configures the PluginConfig object to store any parameter values into an external configuration file (rather than storing it directly with the main configuration file used by Azureus).

When this method is invoked, it will return an object which allows the filename to be chosen - it allows a limited amount of manipulation of the configuration file. This method only needs to be invoked once.

All methods which get and set plugin parameters on this object will store data in the external configuration file. The use of classes like BasicPluginConfigModel will automatically integrate parameters to the external configuration source.

However, if you use any other mechanism to store parameter data, you may need to call the registerParameter to integrate the parameter properly.

Returns:
The PluginConfigSource object representing the external configuration file.
Since:
3.0.5.3

getPluginConfigSource

PluginConfigSource getPluginConfigSource()
Returns the PluginConfigSource object used for this plugin configuration (or null if an external configuration object isn't used).

Returns:
The PluginConfigSource object.
Since:
3.0.5.3

setPluginConfigSource

void setPluginConfigSource(PluginConfigSource source)
Sets the plugin configuration source object to use for storing parameters for this plugin config object.

This method should only be used as an alternative to enableExternalConfigSource(). You will only need to use this method if you use the getLocalPluginInterface method to store data in a separate namespace, but want to use the same configuration file to store data in.

Parameters:
source - The PluginConfigSource object to use.
Since:
3.0.5.3