|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnl.toolforge.karma.core.cmd.event.CommandResponseEvent
nl.toolforge.karma.core.cmd.event.MessageEvent
An event generated as a result of something ordinary. Commands can generate these events, but
Field Summary |
Fields inherited from interface nl.toolforge.karma.core.cmd.event.Event |
LEVEL_DEBUG, LEVEL_INFO, LEVEL_VERBOSE |
Constructor Summary | |
MessageEvent(Command command,
int priority)
Creates a MessageEvent not linked to any command with a priority of priority . |
|
MessageEvent(Command command,
int priority,
SimpleMessage message)
Creates the event for command . |
|
MessageEvent(Command command,
SimpleMessage message)
Creates the event for command . |
|
MessageEvent(SimpleMessage message)
Creates a MessageEvent not linked to any command. |
Method Summary | |
Message |
getEventMessage()
Returns a SimpleMessage formatted as [ <command-name> ] <message-text> if
this message was constructed with a Command object, otherwise it returns the
SimpleMessgae as-is. |
Methods inherited from class nl.toolforge.karma.core.cmd.event.CommandResponseEvent |
getCommand, getPriority |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public MessageEvent(Command command, int priority)
MessageEvent
not linked to any command with a priority of priority
.
command
- The command generated this event.priority
- The priority of the event.public MessageEvent(Command command, int priority, SimpleMessage message)
command
.
command
- The command generated this event.priority
- The priority of the event.message
- The message for the event.public MessageEvent(Command command, SimpleMessage message)
command
.
command
- The command generated this event.public MessageEvent(SimpleMessage message)
MessageEvent
not linked to any command.
message
- Some message.Method Detail |
public Message getEventMessage()
SimpleMessage
formatted as [ <command-name> ] <message-text>
if
this message was constructed with a Command
object, otherwise it returns the
SimpleMessgae
as-is.
getEventMessage
in class CommandResponseEvent
SimpleMessage
object optionally prefixed with the Command
name.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |