|
OpenNMS API 1.2.3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Thread
org.opennms.netmgt.notifd.NotificationTask
This class holds all the data and logic for sending out a notification Each notification that is sent will be accompanied by a row in the notifications table. All notifications in a group will be identified with a common groupId number.
Field Summary | |
private Command[] |
m_commands
The console command that will be issued to send the actual notification. |
private Notifd |
m_notifd
|
private java.util.SortedMap |
m_notifTree
|
private int |
m_notifyId
The row id that will be used for the row inserted into the notifications table |
private java.util.Map |
m_params
|
private long |
m_sendTime
|
private java.util.List |
m_siblings
|
private User |
m_user
The User object the notification needs to go out to |
Fields inherited from class java.lang.Thread |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
NotificationTask(Notifd notifd,
long sendTime,
java.util.Map someParams,
java.util.List siblings)
Constructor, initializes some information |
Method Summary | |
private java.util.List |
getArgumentList(Command command)
|
private java.lang.String |
getArgumentValue(java.lang.String aSwitch)
|
int |
getNotifyId()
Returns the unique id used to insert the row in the database for this notification task. |
long |
getSendTime()
|
void |
run()
|
void |
setCommands(Command[] commands)
This method will construct the command that will be issued to send the actual page. |
void |
setNoticeId(int anId)
Sets the group id that will be inserted into the row in notifications table |
void |
setUser(User aUser)
Sets the user that the page needs to be sent to. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Thread |
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, yield |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
private User m_user
private int m_notifyId
private Command[] m_commands
private java.util.Map m_params
private long m_sendTime
private java.util.List m_siblings
private java.util.SortedMap m_notifTree
private Notifd m_notifd
Constructor Detail |
public NotificationTask(Notifd notifd, long sendTime, java.util.Map someParams, java.util.List siblings) throws java.sql.SQLException
someParams
- the parameters from NotifyMethod Detail |
public java.lang.String toString()
public long getSendTime()
public int getNotifyId()
public void setUser(User aUser)
aUser
- the user infopublic void setNoticeId(int anId)
anId
- the group id to set for the rowpublic void setCommands(Command[] commands)
commands
- the commands to call at the console.public void run()
private java.util.List getArgumentList(Command command)
private java.lang.String getArgumentValue(java.lang.String aSwitch)
|
OpenNMS API 1.2.3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |