dk.netarkivet.archive.bitarchive.distribute
Class BatchTerminationMessage

java.lang.Object
  extended by dk.netarkivet.common.distribute.NetarkivetMessage
      extended by dk.netarkivet.archive.bitarchive.distribute.BatchTerminationMessage
All Implemented Interfaces:
java.io.Serializable

public class BatchTerminationMessage
extends NetarkivetMessage

Message for telling the bitarchives to terminate a specific batchjob.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class dk.netarkivet.common.distribute.NetarkivetMessage
replyOfId
 
Constructor Summary
BatchTerminationMessage(ChannelID to, ChannelID replyTo, java.lang.String batchID)
          Constructor.
BatchTerminationMessage(ChannelID to, java.lang.String batchID)
          Constructor.
 
Method Summary
 java.lang.String getTerminateID()
          Method for retrieving the ID of the batchjob to terminate.
 java.lang.String toString()
          Extends the default toString of NetarkiveMessage with the terminateID.
 
Methods inherited from class dk.netarkivet.common.distribute.NetarkivetMessage
getErrMsg, getID, getReplyOfId, getReplyTo, getTo, hasBeenSent, isOk, setNotOk, setNotOk
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BatchTerminationMessage

public BatchTerminationMessage(ChannelID to,
                               java.lang.String batchID)
                        throws ArgumentNotValid
Constructor.

Parameters:
to - Where the message should be sent.
batchID - The ID of the batchjob to terminate.
Throws:
ArgumentNotValid - If the batchID is either null or the empty string.

BatchTerminationMessage

public BatchTerminationMessage(ChannelID to,
                               ChannelID replyTo,
                               java.lang.String batchID)
                        throws ArgumentNotValid
Constructor.

Parameters:
to - Where the message should be sent.
replyTo - Where the message is sent from.
batchID - The ID of the batchjob to terminate.
Throws:
ArgumentNotValid - If the batchID is either null or the empty string.
Method Detail

getTerminateID

public java.lang.String getTerminateID()
Method for retrieving the ID of the batchjob to terminate.

Returns:
The ID of the batchjob to terminate.

toString

public java.lang.String toString()
Extends the default toString of NetarkiveMessage with the terminateID.

Overrides:
toString in class NetarkivetMessage
Returns:
The string representation of this message.