dk.netarkivet.monitor
Class Settings

java.lang.Object
  extended by dk.netarkivet.monitor.Settings

public class Settings
extends java.lang.Object

Provides access to monitor settings. The settings are retrieved from an monitor_settings.xml file.


Field Summary
(package private) static java.lang.String DEFAULT_FILEPATH
          The default place where the settings file can be found.
static java.util.List<java.lang.String> EXCLUDED_FIELDS
          The fields of this class that don't actually correspond to settings, or are pluggable settings not always present.
static java.lang.String JMX_HOST_NAME
          The name of a JMX host.
static java.lang.String JMX_HOST_PORT
          The port of a JMX host.
static java.lang.String JMX_HOSTS_NUMBER_SETTING
          The number of different hosts where MBeanservers reside.
static java.lang.String JMX_MONITOR_ROLE_PASSWORD_SETTING
          The password needed to connect as 'monitorRole' to the MBeanservers.
static java.lang.String SETTINGS_FILE_NAME_PROPERTY
          The property name specifying the file name of the settings file.
static SettingsStructure SETTINGS_STRUCTURE
          The singleton Settings object initialized at load time.
 
Constructor Summary
Settings()
           
 
Method Summary
static void conditionalReload()
          Utility method.
static void create(java.lang.String s, java.lang.String... values)
          Utility method.
static java.lang.String get(java.lang.String s)
          Utility method.
static java.lang.String[] getAll(java.lang.String s)
          Utility method.
static int getEdition()
          Utility method.
static int getInt(java.lang.String s)
          Utility method.
static long getLong(java.lang.String s)
          Utility method.
static java.io.File getSettingsFile()
          Utility method.
static void reload()
          Utility method.
static void set(java.lang.String s, java.lang.String... values)
          Utility method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SETTINGS_FILE_NAME_PROPERTY

public static final java.lang.String SETTINGS_FILE_NAME_PROPERTY
The property name specifying the file name of the settings file. If the property is unset, uses DEFAULT_FILEPATH.

See Also:
Constant Field Values

DEFAULT_FILEPATH

static final java.lang.String DEFAULT_FILEPATH
The default place where the settings file can be found.

See Also:
Constant Field Values

SETTINGS_STRUCTURE

public static final SettingsStructure SETTINGS_STRUCTURE
The singleton Settings object initialized at load time.


EXCLUDED_FIELDS

public static final java.util.List<java.lang.String> EXCLUDED_FIELDS
The fields of this class that don't actually correspond to settings, or are pluggable settings not always present.


JMX_MONITOR_ROLE_PASSWORD_SETTING

public static final java.lang.String JMX_MONITOR_ROLE_PASSWORD_SETTING
The password needed to connect as 'monitorRole' to the MBeanservers.

See Also:
Constant Field Values

JMX_HOSTS_NUMBER_SETTING

public static final java.lang.String JMX_HOSTS_NUMBER_SETTING
The number of different hosts where MBeanservers reside.

See Also:
Constant Field Values

JMX_HOST_NAME

public static final java.lang.String JMX_HOST_NAME
The name of a JMX host. %d should be replaced with a number between 1 and JMX_HOSTS_NUMBER_SETTING.

See Also:
Constant Field Values

JMX_HOST_PORT

public static final java.lang.String JMX_HOST_PORT
The port of a JMX host. %d should be replaced with a number between 1 and JMX_HOSTS_NUMBER_SETTING.

See Also:
Constant Field Values
Constructor Detail

Settings

public Settings()
Method Detail

get

public static java.lang.String get(java.lang.String s)
Utility method. Provides static access to getter in settingsStructure.

See Also:
SettingsStructure.get(String)

getInt

public static int getInt(java.lang.String s)
Utility method. Provides static access to getter in settingsStructure.

See Also:
SettingsStructure.getInt(String)

getLong

public static long getLong(java.lang.String s)
Utility method. Provides static access to getter in settingsStructure.

See Also:
SettingsStructure.getLong(String)

getAll

public static java.lang.String[] getAll(java.lang.String s)
Utility method. Provides static access to getter in settingsStructure.

See Also:
SettingsStructure.get(String)

getSettingsFile

public static java.io.File getSettingsFile()
Utility method. Provides static access to getter in settingsStructure.

See Also:
SettingsStructure.getSettingsFile()

getEdition

public static int getEdition()
Utility method. Provides static access to getter in settingsStructure.

See Also:
SettingsStructure.getEdition()

conditionalReload

public static void conditionalReload()
Utility method. Provides static access to conditionalReload in settingsStructure.

See Also:
SettingsStructure.conditionalReload()

reload

public static void reload()
Utility method. Provides static access to reload in settingsStructure.

See Also:
SettingsStructure.reload()

set

public static void set(java.lang.String s,
                       java.lang.String... values)
Utility method. Provides static access to setter in settingsStructure.

See Also:
SettingsStructure.set(String,String...)

create

public static void create(java.lang.String s,
                          java.lang.String... values)
Utility method. Provides static access to create in settingsStructure.

See Also:
SettingsStructure.create(String,String...)