Class ConfigurationDefaults
java.lang.Object
com.biglybt.core.config.impl.ConfigurationDefaults
Some (proposed) option naming conventions:
- Starts with a general identifier
General_ for, well, general things =)
Server_ for webinterface specific things
GUI_ (eventually) for GUI specific things
Core_ (eventually) for core specific things
- Second is some identifing term. It starts with a small letter denoting
the variable type.
b Boolean
i Integer
s String
- Directory options should end with _Directory. This activates some
special validity checks in the webinterface option parsing code.
(Namely they are created if they don't exist and the option isn't changed
with a logged error if a normal file of the same name exists)
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringprivate static final AEMonitorprivate static ConfigurationDefaultsprivate ConcurrentHashMapWrapper<String, Object> static final intstatic final byte[]static final floatstatic final intstatic final longstatic final Stringstatic final Stringprivate static final Longprivate static final Longprivate final Hashtableprivate static final Longprivate static final Longprivate static final Long -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCreates a new instance of DefaultsprotectedConfigurationDefaults(Map _def) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddParameter(String sKey, boolean bParameter) voidaddParameter(String sKey, byte[] bParameter) voidaddParameter(String sKey, float fParameter) voidaddParameter(String sKey, int iParameter) voidaddParameter(String sKey, long lParameter) voidaddParameter(String sKey, String sParameter) private voidprotected voiddef_put(String key, String key_def, COConfigurationManager.ParameterVerifier verifier) booleanbooleanbyte[]Returns the default value as an object (String, Long, Float, Boolean)floatstatic ConfigurationDefaultsintlonggetParameter(String key) getVerifiers(String key) booleanvoidregisterExternalDefaults(Map addmap) protected void
-
Field Details
-
ZERO
-
ONE
-
SIXTY
-
FALSE
-
TRUE
-
configdefaults
-
class_mon
-
def
-
def_int
public static final int def_int- See Also:
-
def_long
public static final long def_long- See Also:
-
def_float
public static final float def_float- See Also:
-
def_boolean
public static final int def_boolean- See Also:
-
def_String
- See Also:
-
def_bytes
public static final byte[] def_bytes -
DEFAULT_FILE_CONVERSION_CHARS
- See Also:
-
parameter_verifiers
-
CFG_TORRENTADD_OPENOPTIONS_MANY
- See Also:
-
CFG_TORRENTADD_OPENOPTIONS_ALWAYS
- See Also:
-
CFG_TORRENTADD_OPENOPTIONS_NEVER
- See Also:
-
CFG_TORRENTADD_OPENOPTIONS
- See Also:
-
CFG_TORRENTADD_OPENOPTIONS_SEP
- See Also:
-
-
Constructor Details
-
ConfigurationDefaults
protected ConfigurationDefaults()Creates a new instance of Defaults -
ConfigurationDefaults
-
-
Method Details
-
getInstance
-
def_put
protected void def_put(String key, String key_def, COConfigurationManager.ParameterVerifier verifier) -
checkParameterExists
-
getStringParameter
-
getIntParameter
-
getLongParameter
-
getFloatParameter
-
getByteParameter
-
getBooleanParameter
-
hasParameter
-
getDefaultValueAsObject
-
getAllowedParameters
-
addParameter
-
addParameter
-
addParameter
-
addParameter
-
addParameter
-
addParameter
-
registerExternalDefaults
-
doesParameterDefaultExist
-
getParameter
-
getVerifiers
-
runVerifiers
protected void runVerifiers()
-