public abstract class Message extends Object implements Comparable<Message>
| Modifier and Type | Class and Description |
|---|---|
static class |
Message.Type |
| Modifier and Type | Field and Description |
|---|---|
protected static Set<Message.Type> |
AGGREGATE_SET |
protected boolean |
done |
protected static int |
HASH_MULTIPLIER |
| Modifier | Constructor and Description |
|---|---|
protected |
Message(Message.Type type,
TagsCardinality cardinality) |
protected |
Message(String aspect,
Message.Type type,
TagsCardinality cardinality,
String[] tags) |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
aggregate(Message message)
Aggregate message.
|
boolean |
canAggregate()
Return whether a message can be aggregated.
|
int |
compareTo(Message message) |
boolean |
equals(Object object)
Messages must implement hashCode.
|
String |
getAspect()
Return the message aspect.
|
boolean |
getDone() |
String[] |
getTags()
Return the array of tags for the message.
|
TagsCardinality |
getTagsCardinality() |
Message.Type |
getType()
Return the message type.
|
int |
hashCode()
Messages must implement hashCode.
|
void |
setDone(boolean done) |
protected boolean done
protected static final int HASH_MULTIPLIER
protected static final Set<Message.Type> AGGREGATE_SET
protected Message(Message.Type type, TagsCardinality cardinality)
protected Message(String aspect, Message.Type type, TagsCardinality cardinality, String[] tags)
public abstract void aggregate(Message message)
message - Message to aggregate.public final String getAspect()
public final Message.Type getType()
public String[] getTags()
public TagsCardinality getTagsCardinality()
public boolean canAggregate()
public void setDone(boolean done)
public boolean getDone()
public int hashCode()
public boolean equals(Object object)
public int compareTo(Message message)
compareTo in interface Comparable<Message>Copyright © 2025. All rights reserved.