SDX Network Information Collector SDK

net.juniper.smgt.gateway.gal
Class NicFactory

java.lang.Object
  |
  +--net.juniper.smgt.gateway.gal.NicFactory

public class NicFactory
extends java.lang.Object

The NicFactory is used to access all the NIC components that are configured in the current gateway.


Field Summary
static java.lang.String DEFAULT_PROXY_CLASS
          The default NicProxy implementation classname to be instantiated if no property is specified.
static java.lang.String NIC_PROXY_PROPERTY_NAME
          The NicProxy classname property name
 
Constructor Summary
protected NicFactory(java.util.Properties props)
          Constructs NicFactory based on the privided properties.
 
Method Summary
 void destroy()
          Cleanup method
 void destroyNicComponent(java.lang.String nicNamespace)
          Destroys nic component based on its name space provided.
static net.juniper.smgt.gateway.gal.NicFactory getInstance()
          Returns the sole instance of the NicFactory.
 net.juniper.smgt.gateway.gal.NIC getNicComponent(java.lang.String nicNamespace, net.juniper.smgt.lib.config.ConfigMgr confMgr)
          Returns the NIC component that was configured with the specified name space.
 net.juniper.smgt.gateway.gal.SaeLocator getSaeLocator(java.lang.String locName, net.juniper.smgt.lib.config.ConfigMgr confMgr)
          Returns the SaeLocator component that was configured with the specified name.
static void initialize(java.util.Properties props)
          Initializes the sole instance of NicFactory using ORB properties passed in.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_PROXY_CLASS

public static final java.lang.String DEFAULT_PROXY_CLASS
The default NicProxy implementation classname to be instantiated if no property is specified.

See Also:
Constant Field Values

NIC_PROXY_PROPERTY_NAME

public static final java.lang.String NIC_PROXY_PROPERTY_NAME
The NicProxy classname property name

See Also:
Constant Field Values
Constructor Detail

NicFactory

protected NicFactory(java.util.Properties props)
Constructs NicFactory based on the privided properties.

Parameters:
props - Properties
Method Detail

getInstance

public static net.juniper.smgt.gateway.gal.NicFactory getInstance()
Returns the sole instance of the NicFactory. The default ORB is used in the system.


initialize

public static void initialize(java.util.Properties props)
Initializes the sole instance of NicFactory using ORB properties passed in. This method is optional and should be called before getInstance() only if ORB configuration properties different from the default system ones need to be used.


getNicComponent

public net.juniper.smgt.gateway.gal.NIC getNicComponent(java.lang.String nicNamespace,
                                                        net.juniper.smgt.lib.config.ConfigMgr confMgr)
                                                 throws java.lang.IllegalArgumentException
Returns the NIC component that was configured with the specified name space.

Parameters:
nicNamespace - String the name space of the required NIC component
confMgr - ConfigMgr configuration manager
Returns:
the requested NIC component
Throws:
java.lang.IllegalArgumentException - runtime exception on instantiation failure - thrown when nicNamespace is invalid or directory connection is unavailable.

getSaeLocator

public net.juniper.smgt.gateway.gal.SaeLocator getSaeLocator(java.lang.String locName,
                                                             net.juniper.smgt.lib.config.ConfigMgr confMgr)
                                                      throws java.lang.IllegalArgumentException
Returns the SaeLocator component that was configured with the specified name.

Parameters:
locName - the name of the required SaeLocator component
confMgr - configuration manager
Returns:
the requested SaeLocator component
Throws:
java.lang.IllegalArgumentException - if no SaeLocator component with the specified name is found.

destroy

public void destroy()
Cleanup method


destroyNicComponent

public void destroyNicComponent(java.lang.String nicNamespace)
Destroys nic component based on its name space provided.

Parameters:
nicNamespace - java.lang.String

SDX Network Information Collector SDK