public final class OpennmsServerConfigFactory extends OpennmsServerConfigManager
Constructor and Description |
---|
OpennmsServerConfigFactory(InputStream is)
Constructor for OpennmsServerConfigFactory.
|
Modifier and Type | Method and Description |
---|---|
static OpennmsServerConfigFactory |
getInstance()
Return the singleton instance of this factory.
|
static void |
init()
Load the config from the default config file and create the singleton
instance of this factory.
|
static void |
reload()
Reload the config from the default config file
|
static void |
setInstance(OpennmsServerConfigFactory instance)
setInstance
|
getDefaultCriticalPathIp, getDefaultCriticalPathRetries, getDefaultCriticalPathService, getDefaultCriticalPathTimeout, getServerName, verifyServer
public OpennmsServerConfigFactory(InputStream is) throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
Constructor for OpennmsServerConfigFactory.
is
- a InputStream
object.org.exolab.castor.xml.MarshalException
- if any.org.exolab.castor.xml.ValidationException
- if any.public static void init() throws IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
IOException
- Thrown if the specified config file cannot be readorg.exolab.castor.xml.MarshalException
- Thrown if the file does not conform to the schema.org.exolab.castor.xml.ValidationException
- Thrown if the contents do not match the required schema.IOException
- if any.org.exolab.castor.xml.MarshalException
- if any.org.exolab.castor.xml.ValidationException
- if any.public static void reload() throws IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
IOException
- Thrown if the specified config file cannot be read/loadedorg.exolab.castor.xml.MarshalException
- Thrown if the file does not conform to the schema.org.exolab.castor.xml.ValidationException
- Thrown if the contents do not match the required schema.IOException
- if any.org.exolab.castor.xml.MarshalException
- if any.org.exolab.castor.xml.ValidationException
- if any.public static OpennmsServerConfigFactory getInstance()
IllegalStateException
- Thrown if the factory has not yet been initialized.public static void setInstance(OpennmsServerConfigFactory instance)
setInstance
instance
- a OpennmsServerConfigFactory
object.Copyright © 2015. All Rights Reserved.