Package org.ka2ddo.yaac.core
Class LocalObjectTracker.ObjectLink
java.lang.Object
org.ka2ddo.yaac.core.LocalObjectTracker.ObjectLink
- All Implemented Interfaces:
SupportsExtraData
- Enclosing class:
- LocalObjectTracker
This class maintains an association between a local ObjectReport and the ObjectReportSender used
to transmit this object to the network (assuming that the Object is enabled for transmission).
- Author:
- Andrew Pavlin, KA2DDO
-
Method Summary
Modifier and TypeMethodDescriptiongetAttachment
(Object key) Get a named attachment for this record.Get the ObjectReport associated with this pairing.getOrs()
Get the ObjectReportSender (if any) associated with this pairing's ObjectReport.Return the hashable and comparable identifier for the record.putAttachment
(Object key, Object attachment) Add an attachment to this record.removeAttachment
(Object key) Remove an attachment from this record.void
setOrs
(ObjectReportSender ors) Specify a new ObjectReportSender for this pairing's ObjectReport.toString()
Returns a string representation of the object.
-
Method Details
-
getObject
Get the ObjectReport associated with this pairing.- Returns:
- ObjectReport
-
getOrs
Get the ObjectReportSender (if any) associated with this pairing's ObjectReport.- Returns:
- ObjectReportSender
-
setOrs
Specify a new ObjectReportSender for this pairing's ObjectReport.- Parameters:
ors
- ObjectReportSender to remember
-
toString
Returns a string representation of the object. -
getRecordIdentifier
Return the hashable and comparable identifier for the record.- Specified by:
getRecordIdentifier
in interfaceSupportsExtraData
- Returns:
- Object that uniquely identifies the record within its GuiContentType domain
-
getAttachment
Get a named attachment for this record.- Specified by:
getAttachment
in interfaceSupportsExtraData
- Parameters:
key
- Object identifying the particular attachment- Returns:
- the attached data, or null if no attachment with the specified key
-
putAttachment
Add an attachment to this record.- Specified by:
putAttachment
in interfaceSupportsExtraData
- Parameters:
key
- Object that will identify this particular attachmentattachment
- data to be attached- Returns:
- previous attachment under this key, or null if no previous attachment
- Throws:
NullPointerException
- if a null attachment is specified
-
removeAttachment
Remove an attachment from this record.- Specified by:
removeAttachment
in interfaceSupportsExtraData
- Parameters:
key
- Object identifying the attachment to be removed- Returns:
- whatever attachment was formerly associated with this key, or null if no previous attachment
-