Package org.opennms.netmgt.dao.mock
Class MockEventIpcManager.EmptyEventConfDao
- java.lang.Object
-
- org.opennms.netmgt.dao.mock.MockEventIpcManager.EmptyEventConfDao
-
- All Implemented Interfaces:
EventConfDao
- Enclosing class:
- MockEventIpcManager
public static class MockEventIpcManager.EmptyEventConfDao extends Object implements EventConfDao
This class implementsEventConfDaobut every call returns null.
-
-
Constructor Summary
Constructors Constructor Description EmptyEventConfDao()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddEvent(Event event)Adds the event to the root level event config storage (file).voidaddEventToProgrammaticStore(Event event)Adds the given event to the programmatic event store.EventfindByEvent(Event matchingEvent)findByEventEventfindByUei(String uei)findByUeiStringgetEventLabel(String uei)getEventLabelMap<String,String>getEventLabels()getEventLabelsList<Event>getEvents(String uei)getEventsList<Event>getEventsByLabel()getEventsByLabelList<String>getEventUEIs()getEventUEIsEventsgetRootEvents()getRootEventsbooleanisSecureTag(String tag)isSecureTagvoidreload()reloadbooleanremoveEventFromProgrammaticStore(Event event)Removes the given event from the programmatic event store.voidsaveCurrent()saveCurrent
-
-
-
Method Detail
-
addEvent
public void addEvent(Event event)
Description copied from interface:EventConfDaoAdds the event to the root level event config storage (file). Does not save (you must save independently with saveCurrent)- Specified by:
addEventin interfaceEventConfDao- Parameters:
event- The fully configured Event object to add.
-
addEventToProgrammaticStore
public void addEventToProgrammaticStore(Event event)
Description copied from interface:EventConfDaoAdds the given event to the programmatic event store. This store currently implemented as a file (referenced from eventconf.xml) The programmatic store is a separate storage area, so that incidental programmatic editing of events (e.g. custom UEIs for thresholds, edited through the Web-UI) does not clutter up the otherwise carefully maintained event files. This method does not save (persist) the changes- Specified by:
addEventToProgrammaticStorein interfaceEventConfDao- Parameters:
event- The fully configured Event object to add.
-
findByEvent
public Event findByEvent(Event matchingEvent)
Description copied from interface:EventConfDaofindByEvent
- Specified by:
findByEventin interfaceEventConfDao- Parameters:
matchingEvent- aEventobject.- Returns:
- a
Eventobject.
-
findByUei
public Event findByUei(String uei)
Description copied from interface:EventConfDaofindByUei
- Specified by:
findByUeiin interfaceEventConfDao- Parameters:
uei- aStringobject.- Returns:
- a
Eventobject.
-
getEventLabel
public String getEventLabel(String uei)
Description copied from interface:EventConfDaogetEventLabel
- Specified by:
getEventLabelin interfaceEventConfDao- Parameters:
uei- aStringobject.- Returns:
- a
Stringobject.
-
getEventLabels
public Map<String,String> getEventLabels()
Description copied from interface:EventConfDaogetEventLabels
- Specified by:
getEventLabelsin interfaceEventConfDao- Returns:
- a
Mapobject.
-
getEventUEIs
public List<String> getEventUEIs()
Description copied from interface:EventConfDaogetEventUEIs
- Specified by:
getEventUEIsin interfaceEventConfDao- Returns:
- a
Listobject.
-
getEvents
public List<Event> getEvents(String uei)
Description copied from interface:EventConfDaogetEvents
- Specified by:
getEventsin interfaceEventConfDao- Parameters:
uei- aStringobject.- Returns:
- a
Listobject.
-
getEventsByLabel
public List<Event> getEventsByLabel()
Description copied from interface:EventConfDaogetEventsByLabel
- Specified by:
getEventsByLabelin interfaceEventConfDao- Returns:
- a
Listobject.
-
isSecureTag
public boolean isSecureTag(String tag)
Description copied from interface:EventConfDaoisSecureTag
- Specified by:
isSecureTagin interfaceEventConfDao- Parameters:
tag- aStringobject.- Returns:
- a boolean.
-
reload
public void reload() throws org.springframework.dao.DataAccessExceptionDescription copied from interface:EventConfDaoreload
- Specified by:
reloadin interfaceEventConfDao- Throws:
org.springframework.dao.DataAccessException- if any.
-
removeEventFromProgrammaticStore
public boolean removeEventFromProgrammaticStore(Event event)
Description copied from interface:EventConfDaoRemoves the given event from the programmatic event store. This store currently implemented as a file (referenced from eventconf.xml) The programmatic store is a separate storage area, so that incidental programmatic editing of events (e.g. custom UEIs for thresholds, edited through the Web-UI) does not clutter up the otherwise carefully maintained event files. This method does not save (persist) the changes- Specified by:
removeEventFromProgrammaticStorein interfaceEventConfDao- Parameters:
event- The fully configured Event object to remove.- Returns:
- a boolean.
-
saveCurrent
public void saveCurrent()
Description copied from interface:EventConfDaosaveCurrent
- Specified by:
saveCurrentin interfaceEventConfDao
-
getRootEvents
public Events getRootEvents()
Description copied from interface:EventConfDaogetRootEvents
- Specified by:
getRootEventsin interfaceEventConfDao- Returns:
- a
Eventsobject.
-
-