Package dk.netarkivet.archive.distribute
Class ArchiveMessage
- java.lang.Object
-
- dk.netarkivet.common.distribute.NetarkivetMessage
-
- dk.netarkivet.archive.distribute.ArchiveMessage
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
AdminDataMessage
,BatchEndedMessage
,BatchMessage
,BatchReplyMessage
,CorrectMessage
,GetAllChecksumsMessage
,GetAllFilenamesMessage
,GetChecksumMessage
,GetFileMessage
,GetMessage
,HeartBeatMessage
,RemoveAndGetFileMessage
,StoreMessage
,UploadMessage
public abstract class ArchiveMessage extends NetarkivetMessage
Common base class for messages exchanged between an archive server and an archive client (or within an archive).- See Also:
NetarkivetMessage
, Serialized Form
-
-
Field Summary
-
Fields inherited from class dk.netarkivet.common.distribute.NetarkivetMessage
replyOfId
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
ArchiveMessage(ChannelID to, ChannelID replyTo)
Creates a new ArchiveMessage.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract void
accept(ArchiveMessageVisitor v)
Should be implemented as a part of the visitor pattern.-
Methods inherited from class dk.netarkivet.common.distribute.NetarkivetMessage
getErrMsg, getID, getReplyOfId, getReplyTo, getTo, hasBeenSent, isOk, setNotOk, setNotOk, toString
-
-
-
-
Constructor Detail
-
ArchiveMessage
protected ArchiveMessage(ChannelID to, ChannelID replyTo) throws ArgumentNotValid
Creates a new ArchiveMessage.- Parameters:
to
- the initial receiver of the messagereplyTo
- the initial sender of the message- Throws:
ArgumentNotValid
- if to==replyTo or there is a null parameter.
-
-
Method Detail
-
accept
public abstract void accept(ArchiveMessageVisitor v)
Should be implemented as a part of the visitor pattern. e.g.: public void accept(ArchiveMessageVisitor v) { v.visit(this); }- Parameters:
v
- A message visitor- See Also:
ArchiveMessageVisitor
-
-