public class GetMessage extends ArchiveMessage
replyOfId
Constructor and Description |
---|
GetMessage(ChannelID to,
ChannelID replyTo,
String arcfile,
long index)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
accept(ArchiveMessageVisitor v)
Should be implemented as a part of the visitor pattern.
|
String |
getArcFile()
Get name of the arc file.
|
long |
getIndex()
Index of the record to retrieve.
|
BitarchiveRecord |
getRecord()
Get the data retrieved from the arcfile.
|
void |
setRecord(BitarchiveRecord rec)
Register retrieved record.
|
String |
toString()
Retrieval of a string representation of this instance.
|
getErrMsg, getID, getReplyOfId, getReplyTo, getTo, hasBeenSent, isOk, setNotOk, setNotOk
public GetMessage(ChannelID to, ChannelID replyTo, String arcfile, long index)
to
- Where the message should be sent.replyTo
- where the reply of this message should be sent.arcfile
- The name of the file to retrieve a arc-record from.index
- The offset of the arc-file.public String getArcFile()
public long getIndex()
public void setRecord(BitarchiveRecord rec)
rec
- Record retrieved from arcfile at offset indexpublic BitarchiveRecord getRecord()
public void accept(ArchiveMessageVisitor v)
accept
in class ArchiveMessage
v
- A message visitorArchiveMessageVisitor
public String toString()
toString
in class NetarkivetMessage
Copyright © 2005–2016 The Royal Danish Library, the Danish State and University Library, the National Library of France and the Austrian National Library.. All rights reserved.