OpenNMS API 1.1.4

org.opennms.netmgt.config
Class NotifdConfigFactory

java.lang.Object
  extended byorg.opennms.netmgt.config.NotifdConfigFactory

public class NotifdConfigFactory
extends java.lang.Object


Field Summary
protected static java.io.InputStream configIn
          Input stream for the general Notifd configuration xml
private static NotifdConfiguration configuration
           
private static boolean initialized
          Boolean indicating if the init() method has been called
private static NotifdConfigFactory instance
          Singleton instance
private static long m_lastModified
           
private static java.io.File m_notifdConfFile
           
 
Constructor Summary
private NotifdConfigFactory()
           
 
Method Summary
static NotifdConfiguration getConfiguration()
           
static NotifdConfigFactory getInstance()
           
static boolean getNotificationMatch()
           
static java.lang.String getNotificationStatus()
           
static java.lang.String getPrettyStatus()
          Gets a nicely formatted string for the Web UI to display
static void init()
           
static void reload()
           
 void saveCurrent()
           
private  void sendEvent(java.lang.String uei)
           
 void turnNotifdOff()
          Turns the notifd service off
 void turnNotifdOn()
          Turns the notifd service on
private static void updateFromFile()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

instance

private static NotifdConfigFactory instance
Singleton instance


configIn

protected static java.io.InputStream configIn
Input stream for the general Notifd configuration xml


initialized

private static boolean initialized
Boolean indicating if the init() method has been called


configuration

private static NotifdConfiguration configuration

m_notifdConfFile

private static java.io.File m_notifdConfFile

m_lastModified

private static long m_lastModified
Constructor Detail

NotifdConfigFactory

private NotifdConfigFactory()
Method Detail

getInstance

public static NotifdConfigFactory getInstance()

init

public static void init()
                 throws java.io.IOException,
                        java.io.FileNotFoundException,
                        org.exolab.castor.xml.MarshalException,
                        org.exolab.castor.xml.ValidationException
Throws:
java.io.IOException
java.io.FileNotFoundException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException

reload

public static void reload()
                   throws java.io.IOException,
                          org.exolab.castor.xml.MarshalException,
                          org.exolab.castor.xml.ValidationException
Throws:
java.io.IOException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException

getConfiguration

public static NotifdConfiguration getConfiguration()
                                            throws java.io.IOException,
                                                   org.exolab.castor.xml.MarshalException,
                                                   org.exolab.castor.xml.ValidationException
Throws:
java.io.IOException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException

getNotificationStatus

public static java.lang.String getNotificationStatus()
                                              throws java.io.IOException,
                                                     org.exolab.castor.xml.MarshalException,
                                                     org.exolab.castor.xml.ValidationException
Throws:
java.io.IOException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException

getNotificationMatch

public static boolean getNotificationMatch()
                                    throws java.io.IOException,
                                           org.exolab.castor.xml.MarshalException,
                                           org.exolab.castor.xml.ValidationException
Throws:
java.io.IOException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException

getPrettyStatus

public static java.lang.String getPrettyStatus()
                                        throws java.io.IOException,
                                               org.exolab.castor.xml.MarshalException,
                                               org.exolab.castor.xml.ValidationException
Gets a nicely formatted string for the Web UI to display

Returns:
On, Off, or Unknown depending on status
Throws:
java.io.IOException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException

turnNotifdOn

public void turnNotifdOn()
                  throws org.exolab.castor.xml.MarshalException,
                         org.exolab.castor.xml.ValidationException,
                         java.io.IOException
Turns the notifd service on

Throws:
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException
java.io.IOException

turnNotifdOff

public void turnNotifdOff()
                   throws org.exolab.castor.xml.MarshalException,
                          org.exolab.castor.xml.ValidationException,
                          java.io.IOException
Turns the notifd service off

Throws:
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException
java.io.IOException

sendEvent

private void sendEvent(java.lang.String uei)

saveCurrent

public void saveCurrent()
                 throws org.exolab.castor.xml.MarshalException,
                        org.exolab.castor.xml.ValidationException,
                        java.io.IOException
Throws:
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException
java.io.IOException

updateFromFile

private static void updateFromFile()
                            throws java.io.IOException,
                                   org.exolab.castor.xml.MarshalException,
                                   org.exolab.castor.xml.ValidationException
Throws:
java.io.IOException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException

OpenNMS API 1.1.4

Generated by eevans on November 11 2004 1600.