OpenNMS API 1.2.3

org.opennms.netmgt.config
Class NotifdConfigFactory

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

public class NotifdConfigFactory
extends NotifdConfigManager


Field Summary
private static boolean initialized
          Boolean indicating if the init() method has been called
private static NotifdConfigFactory instance
          Singleton instance
private  long m_lastModified
           
private  java.io.File m_notifdConfFile
           
 
Fields inherited from class org.opennms.netmgt.config.NotifdConfigManager
configuration
 
Constructor Summary
private NotifdConfigFactory()
           
 
Method Summary
static NotifdConfigFactory getInstance()
           
static java.lang.String getPrettyStatus()
          Gets a nicely formatted string for the Web UI to display
static void init()
           
 void reload()
           
protected  void saveXml(java.lang.String xml)
           
 void turnNotifdOff()
          Turns the notifd service off TODO: this was pulled up into the base class but is still here because of a reference from the webapp.
 void turnNotifdOn()
          Turns the notifd service on TODO: this was pulled up into the base class but is still here because of a reference from the webapp.
protected  void update()
           
 
Methods inherited from class org.opennms.netmgt.config.NotifdConfigManager
getConfiguration, getNextNotifIdSql, getNotificationMatch, getNotificationStatus, matchNotificationParameters, parseXml, saveCurrent, sendEvent
 
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


initialized

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


m_notifdConfFile

private java.io.File m_notifdConfFile

m_lastModified

private 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 void reload()
            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

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 TODO: Pull up into base class but keep this reference for the webapp until singleton is removed.
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 TODO: this was pulled up into the base class but is still here because of a reference from the webapp. Fix up by renaming the method in the base class can calling that method from here.

Overrides:
turnNotifdOn in class NotifdConfigManager
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 TODO: this was pulled up into the base class but is still here because of a reference from the webapp. Fix up by renaming the method in the base class can calling that method from here.

Overrides:
turnNotifdOff in class NotifdConfigManager
Throws:
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException
java.io.IOException

saveXml

protected void saveXml(java.lang.String xml)
                throws java.io.IOException
Specified by:
saveXml in class NotifdConfigManager
Parameters:
xml -
Throws:
java.io.IOException

update

protected void update()
               throws java.io.IOException,
                      org.exolab.castor.xml.MarshalException,
                      org.exolab.castor.xml.ValidationException
Specified by:
update in class NotifdConfigManager
Throws:
java.io.IOException
org.exolab.castor.xml.MarshalException
org.exolab.castor.xml.ValidationException

OpenNMS API 1.2.3

Generated by eevans on May 29 2005 2015.