public class FXBlotterItemMessage extends Object
An instance of this class represents a Record Item, in a Container.
Instances of this class should be created in on of two ways, this is determined by whether or not you are using
the FXBlotterPublisher
or the FXCachedBlotterPublisher
If you have the FXBlotterPublisher
, then you must use a corresponding FXBlotterItemPublisher
.
You may then obtain the message factory FXBlotterItemPublisher.getMessageFactory()
which will return you an
instance of FXBlotterItemMessageFactory
, on which you should invoke FXBlotterItemMessageFactory.newItemBuilder(String, String)
to obtain the builder for this class.
If you have the FXCachedBlotterPublisher
. You should obtain the message factory FXCachedBlotterPublisher.getMessageFactory()
, which
creates the FXCachedBlotterMessage
. On the message object you should then invoke FXCachedBlotterMessage.newItemBuilder(String)
to
obtain the builder for this class.
Modifier and Type | Field and Description |
---|---|
protected String |
itemId |
protected com.caplin.datasource.messaging.record.GenericMessage |
record |
protected String |
username |
Constructor and Description |
---|
FXBlotterItemMessage(String username,
String itemId,
com.caplin.datasource.messaging.record.GenericMessage record)
Deprecated.
You should not need to create
instances of this class yourself. Please refer to the class javadoc to
see how instances of this class should be obtained.
|
Modifier and Type | Method and Description |
---|---|
FXBlotterItemMessage |
copyOf(com.caplin.datasource.messaging.MessageFactory factory)
Creates a new object with the same state as this object.
|
String |
getField(String fieldName)
Returns a field that has been set on this message with the given name.
|
List<com.caplin.datasource.messaging.Field> |
getFields()
Returns all the fields that have been set on this object as a list.
|
String |
getItemID()
Returns the item id, which will be part of the Record Item's subject
|
com.caplin.datasource.messaging.record.GenericMessage |
getRecord()
Returns the underlying DataSource message object
|
String |
getUsername()
Returns the username, which will be part of the Record Item's subject
|
boolean |
isImage()
Returns true if the this message is to be an image update
|
void |
setImage(boolean isImage)
Sets the image flag on the outgoing Record
|
String |
toString() |
protected final com.caplin.datasource.messaging.record.GenericMessage record
protected final String username
protected final String itemId
@Deprecated public FXBlotterItemMessage(String username, String itemId, com.caplin.datasource.messaging.record.GenericMessage record)
public void setImage(boolean isImage)
isImage
- The image flag to be set on the Record.public boolean isImage()
public com.caplin.datasource.messaging.record.GenericMessage getRecord()
public String getItemID()
public String getUsername()
public String getField(String fieldName)
fieldName
- The name of the fieldpublic List<com.caplin.datasource.messaging.Field> getFields()
public FXBlotterItemMessage copyOf(com.caplin.datasource.messaging.MessageFactory factory)
factory
- The factory to be used in creating the FXBlotterItemMessage
Copyright © 2015 Caplin Systems.