|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.snmp4j.SNMP4JSettings
public final class SNMP4JSettings
The SNMP4JSettings
class implements a central configuration
class of the SNMP4J framework. As a rule of thumb, changes to the default
configuration should be made before any other classes of the SNMP4J API are
instantiated or referenced by the application code.
Constructor Summary | |
---|---|
SNMP4JSettings()
|
Method Summary | |
---|---|
static OIDTextFormat |
getOIDTextFormat()
Gets the OID text format for textual representation of OIDs. |
static ThreadFactory |
getThreadFactory()
Gets the thread factory. |
static long |
getThreadJoinTimeout()
Gets the Thread join timeout used to join threads if no explicit timeout is set. |
static TimerFactory |
getTimerFactory()
Gets the timer factory. |
static VariableTextFormat |
getVariableTextFormat()
Gets the variable text format for textual representation of variable bindings. |
static boolean |
isExtensibilityEnabled()
Tests if the extensibility feature is enabled. |
static boolean |
isFowardRuntimeExceptions()
Indicates whether runtime exceptions should be thrown on thread boundaries controlled by SNMP4J and related APIs. |
static void |
setExtensibilityEnabled(boolean enable)
Enables (or disables) the extensibility feature of SNMP4J. |
static void |
setForwardRuntimeExceptions(boolean forwardExceptions)
Enables or disables runtime exception forwarding. |
static void |
setOIDTextFormat(OIDTextFormat newOidTextFormat)
Sets the OID text format to be used by SNMP4J. |
static void |
setThreadFactory(ThreadFactory newThreadFactory)
Sets the thread factory for creating new threads of execution. |
static void |
setThreadJoinTimeout(long millis)
Sets the Thread join timeout used to join threads if no explicit timeout is set. |
static void |
setTimerFactory(TimerFactory newTimerFactory)
Sets the timer factory for creating new timer instances. |
static void |
setVariableTextFormat(VariableTextFormat newVariableTextFormat)
Sets the variable text format to be used by SNMP4J. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SNMP4JSettings()
Method Detail |
---|
public static void setExtensibilityEnabled(boolean enable)
By default, the extensibility feature is disabled which provides a faster startup and since no system properties are read, it ensures that SNMP4J can be used also in secure environments like applets.
enable
- if true
activates extensibility or if false
disables it. In the latter case, SNMP4J's default configuration will
be used with all available features.public static final boolean isExtensibilityEnabled()
true
the extensibility is enabled otherwise it is
disabled. In the latter case, SNMP4J's default configuration will
be used with all available features.public static void setForwardRuntimeExceptions(boolean forwardExceptions)
forwardExceptions
- true
runtime exceptions are thrown on thread boundaries
controlled by SNMP4J and related APIs. Default is false
.forwardRuntimeExceptions
public static final boolean isFowardRuntimeExceptions()
true
runtime exceptions are thrown on thread boundaries
controlled by SNMP4J and related APIs. Default is false
.public static final ThreadFactory getThreadFactory()
public static final void setThreadFactory(ThreadFactory newThreadFactory)
newThreadFactory
- a ThreadFactory (must not be null
).public static final TimerFactory getTimerFactory()
public static final void setTimerFactory(TimerFactory newTimerFactory)
newTimerFactory
- a TimerFactory (must not be null
).public static final OIDTextFormat getOIDTextFormat()
OIDTextFormat
instance.public static final void setOIDTextFormat(OIDTextFormat newOidTextFormat)
newOidTextFormat
- the new OIDTextFormat
(must not be null
).public static final VariableTextFormat getVariableTextFormat()
VariableTextFormat
instance.public static final void setVariableTextFormat(VariableTextFormat newVariableTextFormat)
newVariableTextFormat
- the new VariableTextFormat
(must not be null
).public static long getThreadJoinTimeout()
public static void setThreadJoinTimeout(long millis)
millis
- the maximum time in milli-seconds to wait for a Thread to join if no
explicit timeout has been set.
|
Copyright 2005-2010 Frank Fock (SNMP4J.org) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |