com.neeve.root
Class RootConfig

java.lang.Object
  extended by com.neeve.root.RootConfig
Direct Known Subclasses:
AepConfig, ConfigConfig, DiscoveryConfig, EventConfig, OdsConfig, PktConfig, RogConfig, SmaConfig, SrvAppConfig, SrvConfigConfig, SrvControllerConfig

public class RootConfig
extends Object

Contains facilties to configure instantiated Neeve objects.

This class contains helper methods that enable the user to set information used to configure instantiated Neeve objects (e.g. single or multi-threaded mode of operation, trace level etc). This class also contains methods used to obtain deployment related information (e.g. installation root etc).


Nested Class Summary
static class RootConfig.ObjectConfig
          Class used to store information used to configure a Neeve object.
 
Constructor Summary
RootConfig()
           
 
Method Summary
static boolean getChecked(String name)
          Get checked operating mode for a named set of objects.
static String getLogger(String name)
          Get the trace logger for a named set of objects.
static boolean getThreaded(String name)
          Get threaded operating mode for a named set of objects.
static Tracer.Level getTraceLevel(String name)
          Get the trace level for a named set of objects.
static void setChecked(String name, boolean val)
          Set the checked operating mode for a named set of objects.
static void setLogger(String name, String val)
          Set the trace logger for a named set of objects.
static void setThreaded(String name, boolean val)
          Set the threaded operating mode for a named set of objects.
static void setTraceLevel(String name, Tracer.Level val)
          Set the trace level for a named set of objects.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RootConfig

public RootConfig()
Method Detail

setThreaded

public static void setThreaded(String name,
                               boolean val)
Set the threaded operating mode for a named set of objects.

Parameters:
name - The name idetifying the object set.
val - Indicates whethee the objects are to operate in a single or multi-threaded mode (true=multi-threaded)

This method sets whether objects identified by the specified name instanitiated subsequent to this call will operate in a single or multi-threaded mode. Specifying a null name will set the default threaded mode for all objects.

Each class in the system allows for single or multi-threaded mode of operation. This parameter only applies to those classes that permit concurrent multi-threaded access to their methods. Specifying the threaded mode to false causes such classes to switch off synchronization thus downgrading the services offered to operate only in the context of a single thread.

Threading:
This method is safe for concurrent access by multiple threads

getThreaded

public static boolean getThreaded(String name)
Get threaded operating mode for a named set of objects.

Parameters:
name - The name idetifying the object set.
See Also:
setThreaded(java.lang.String, boolean)
Threading:
This method is safe for concurrent access by multiple threads

setChecked

public static void setChecked(String name,
                              boolean val)
Set the checked operating mode for a named set of objects.

Parameters:
name - The name idetifying the object set.
val - Indicates the checked mode to be set

This method sets whether objects identified by the specified name initantiated subsequent to this call will operate in checked or unchecked mode. Specifying a null name will set the default checked mode for all objects. Checked mode operations perform extra parameter validation and internal state checking as compared to the unchecked state. Performance is the criteria used to decide whether to remove or keep a validation operation in the unchecked mode.

Threading:
This method is safe for concurrent access by multiple threads

getChecked

public static boolean getChecked(String name)
Get checked operating mode for a named set of objects.

Parameters:
name - The name idetifying the object set.
See Also:
setChecked(java.lang.String, boolean)
Threading:
This method is safe for concurrent access by multiple threads

setTraceLevel

public static void setTraceLevel(String name,
                                 Tracer.Level val)
Set the trace level for a named set of objects.

Parameters:
name - The name idetifying the object set.
val - The trace level to set.

This method sets the trace level for objects identified by the specified name initantiated subsequent to this call. Specifying a null name will set the default trace level for all objects.

Threading:
This method is safe for concurrent access by multiple threads

getTraceLevel

public static Tracer.Level getTraceLevel(String name)
Get the trace level for a named set of objects.

Parameters:
name - The name idetifying the object set.
See Also:
setTraceLevel(java.lang.String, com.neeve.trace.Tracer.Level)
Threading:
This method is safe for concurrent access by multiple threads

setLogger

public static void setLogger(String name,
                             String val)
Set the trace logger for a named set of objects.

Parameters:
name - The name idetifying the object set.
val - The name of the logger to use for the named set of objects.

This method sets the trace logger for objects identified by the specified name initantiated subsequent to this call. Specifying a null name will set the default trace logger for all objects.

Threading:
This method is safe for concurrent access by multiple threads

getLogger

public static String getLogger(String name)
Get the trace logger for a named set of objects.

Parameters:
name - The name idetifying the object set.
See Also:

This method returns the logger used for a named set of objects. The method returns the name of the logger set via {@link #setLogger}. If not set, the logger used for the named set of objects is the same as the objects set's name i.e. the name returned by this method is either the name set via {@link #setLogger} or name itself if not set via {@link #setLogger}

Threading:
This method is safe for concurrent access by multiple threads


Copyright © 2016 Neeve Research, LLC. All Rights Reserved.