Rice Pastry API

rice.p2p.commonapi
Interface Message

All Superinterfaces:
java.io.Serializable
All Known Subinterfaces:
RawMessage
All Known Implementing Classes:
AggregationMessage, GlacierMessage, JavaSerializedMessage, Message, MultiringRegrTest.MultiringTestMessage, MyMsg, MyMsg, MyMsg, PastMessage, PRawMessage, ReminderMessage, ReplicationMessage, ScribeMessage, TimeoutMessage

public interface Message
extends java.io.Serializable

Version:
$Id: Message.java 3274 2006-05-15 16:17:47Z jeffh $
Author:
Alan Mislove, Peter Druschel

Field Summary
static byte HIGH_PRIORITY
          DESCRIBE THE FIELD
static byte LOW_PRIORITY
          DESCRIBE THE FIELD
static byte MAX_PRIORITY
          DESCRIBE THE FIELD
static byte MEDIUM_HIGH_PRIORITY
          DESCRIBE THE FIELD
static byte MEDIUM_LOW_PRIORITY
          DESCRIBE THE FIELD
static byte MEDIUM_PRIORITY
          DESCRIBE THE FIELD
 
Method Summary
 byte getPriority()
          Method which should return the priority level of this message.
 

Field Detail

MAX_PRIORITY

public static final byte MAX_PRIORITY
DESCRIBE THE FIELD

See Also:
Constant Field Values

HIGH_PRIORITY

public static final byte HIGH_PRIORITY
DESCRIBE THE FIELD

See Also:
Constant Field Values

MEDIUM_HIGH_PRIORITY

public static final byte MEDIUM_HIGH_PRIORITY
DESCRIBE THE FIELD

See Also:
Constant Field Values

MEDIUM_PRIORITY

public static final byte MEDIUM_PRIORITY
DESCRIBE THE FIELD

See Also:
Constant Field Values

MEDIUM_LOW_PRIORITY

public static final byte MEDIUM_LOW_PRIORITY
DESCRIBE THE FIELD

See Also:
Constant Field Values

LOW_PRIORITY

public static final byte LOW_PRIORITY
DESCRIBE THE FIELD

See Also:
Constant Field Values
Method Detail

getPriority

public byte getPriority()
Method which should return the priority level of this message. The messages can range in priority from 0 (highest priority) to Integer.MAX_VALUE (lowest) - when sending messages across the wire, the queue is sorted by message priority. If the queue reaches its limit, the lowest priority messages are discarded. Thus, applications which are very verbose should have LOW_PRIORITY or lower, and applications which are somewhat quiet are allowed to have MEDIUM_PRIORITY or possibly even HIGH_PRIORITY.

Returns:
This message's priority

Rice Pastry API

Copyright © 2001-2005 - Rice Pastry.


Imprint-Dataprotection