com.mindtree.techworks.insight.reporting.jobs.message
Interface JobMessage

All Superinterfaces:
java.io.Serializable
All Known Implementing Classes:
DefaultJobMessage

public interface JobMessage
extends java.io.Serializable

A JobMessage is the data passed on to a Job for executing its task. Specializations of this class would have additional information regardin the data content and action modifiers for the Job. For example, an email message might have data like the mesage body, the recepients address, etc.

A JobMessage is uniquely identified by the type string returned by the object (the #getJobMessageType() method).

The DefaultJobMessage implementation provided is supported by all Jobs.

Since:
Insight 1.5
Version:
$Revision: 27 $ $Date: 2007-12-16 04:58:03 -0700 (Sun, 16 Dec 2007) $
Author:
Bindul Bhowmik
See Also:
Job, DefaultJobMessage

Field Summary
static int ACTION_FILTER
          Indicates that the message was generated from a Filter action.
static short MODE_DAEMON
          Indicates that the message was generated while Insight was running in the Daemon mode.
static short MODE_INTERACTIVE
          Indicates that the message was generated while Insight was running in the Interactive mode.
 
Method Summary
 int getAction()
          Returns the action which caused the message.
 FilterCriteria getFilterCriteria()
          Returns the criteria that was in use on the action while the message was generated.
 short getInsightMode()
          Returns the mode in which Insight was running when the message was generated.
 java.lang.String getJobMessageType()
          Returns the type of the message.
 

Field Detail

MODE_INTERACTIVE

static final short MODE_INTERACTIVE
Indicates that the message was generated while Insight was running in the Interactive mode.

See Also:
Constant Field Values

MODE_DAEMON

static final short MODE_DAEMON
Indicates that the message was generated while Insight was running in the Daemon mode.

See Also:
Constant Field Values

ACTION_FILTER

static final int ACTION_FILTER
Indicates that the message was generated from a Filter action.

See Also:
Constant Field Values
Method Detail

getJobMessageType

java.lang.String getJobMessageType()
Returns the type of the message. A message may be identified uniquely by the fully qualified class name of the JobMessage class.

Returns:
The type of the message.

getFilterCriteria

FilterCriteria getFilterCriteria()
Returns the criteria that was in use on the action while the message was generated.

Returns:
The criteria in use to generate the message.

getInsightMode

short getInsightMode()
Returns the mode in which Insight was running when the message was generated. It would be one of the MODE_ constants.

Returns:
The mode in which Insight is running.

getAction

int getAction()
Returns the action which caused the message. See the ACTION_ constants.

Returns:
The action which caused the message.


Copyright © 2003-2008 MindTree Consulting Ltd.. All Rights Reserved.