Class SettlementInstructionChannel
- Direct Known Subclasses:
SalesSettlementInstructionChannel
-
Field Summary
Modifier and TypeFieldDescriptionprotected final com.caplin.datasource.blotter.BlotterChannel
-
Constructor Summary
ConstructorDescriptionSettlementInstructionChannel
(com.caplin.datasource.blotter.BlotterChannel blotterChannel) -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
Clears allBlotterItem
s from the internal cache and sends a container clear so that these items are no longer requested when the channel is subscribed to.void
Closes the channel.Returns the entity for the channelReturns the subject for the channel.Returns the username for the channelvoid
removeSettlementInstruction
(String uniqueId) Removes theBlotterItem
from the internal cache and sends a container remove so that this item is no longer requested when the channel is subscribed to.void
removeSettlementInstructions
(List<String> uniqueIds) RemovesBlotterItem
s from the internal cache and sends a container remove so that these items are no longer requested when the channel is subscribed to.void
Sends an empty container on the channel.void
sendSettlementInstruction
(com.caplin.datasource.blotter.BlotterItem item) Adds theBlotterItem
to the internal cache and sends a container add so that this item is requested when the channel is subscribed to.void
Sends a status ok on the channel with custom message.void
Sends a status stale on the channel.void
Sends a status stale on the channel with custom message.void
sendSettlementInstructionMapping
(String newSubject) Sends aMappingMessage
to the Liberator, requesting that the Liberator map thisSettlementInstructionChannel
instance's subject to the specified subjectnewSubject
.void
sendSettlementInstructionNotFound
(String uniqueId) Sends a not found for aBlotterItem
.void
Sends a status ok on the channel.void
sendSettlementInstructionStatusOk
(String uniqueId) Send status ok for aBlotterItem
.void
sendSettlementInstructionStatusStale
(String uniqueId) Send status stale for aBlotterItem
.void
setSettlementInstructionItems
(List<com.caplin.datasource.blotter.BlotterItem> items) AddsBlotterItem
s to the internal cache and sends a container add so that these items are requested when the channel is subscribed to.
-
Field Details
-
blotterChannel
protected final com.caplin.datasource.blotter.BlotterChannel blotterChannel
-
-
Constructor Details
-
SettlementInstructionChannel
public SettlementInstructionChannel(com.caplin.datasource.blotter.BlotterChannel blotterChannel)
-
-
Method Details
-
closeChannel
public void closeChannel()Closes the channel.
Sends a Subject Not Found on the channel's subject to let subscribers know that it is no longer serviced.
-
getSubject
Returns the subject for the channel.
- Returns:
- subject for the channel
-
getUsername
Returns the username for the channel
- Returns:
- username for the channel
-
getEntity
Returns the entity for the channel
- Returns:
- entity for the channel
-
removeSettlementInstruction
Removes the
BlotterItem
from the internal cache and sends a container remove so that this item is no longer requested when the channel is subscribed to.- Parameters:
uniqueId
- of the item to remove
-
removeSettlementInstructions
Removes
BlotterItem
s from the internal cache and sends a container remove so that these items are no longer requested when the channel is subscribed to.- Parameters:
uniqueIds
- of the items to remove
-
clear
public void clear()Clears all
BlotterItem
s from the internal cache and sends a container clear so that these items are no longer requested when the channel is subscribed to. -
sendSettlementInstruction
public void sendSettlementInstruction(com.caplin.datasource.blotter.BlotterItem item) Adds the
BlotterItem
to the internal cache and sends a container add so that this item is requested when the channel is subscribed to.If an item with the same unique id already exists in the internal cache then that item's fields will be updated with this one. This will then trigger an update for any users currently subscribed to this item.
- Parameters:
item
- to send
-
sendSettlementInstructionNotFound
Sends a not found for a
BlotterItem
.Specifically for the case where there is more than one Integration Adapter providing for the same channel subject.
Sent in response to a
BlotterChannelListener.onBlotterItemRequest(com.caplin.datasource.blotter.BlotterChannel, java.lang.String)
when the item requested is not serviceable by your application.- Parameters:
uniqueId
- of item that cannot be serviced by your application.
-
setSettlementInstructionItems
Adds
BlotterItem
s to the internal cache and sends a container add so that these items are requested when the channel is subscribed to.If any items with the same unique id already exists in the internal cache then these items fields will be updated with these one. This will then trigger an update for any users currently subscribed to these items.
- Parameters:
items
- to send
-
sendSettlementInstructionMapping
Sends a
MappingMessage
to the Liberator, requesting that the Liberator map thisSettlementInstructionChannel
instance's subject to the specified subjectnewSubject
.Note: Liberator applies mapping rules configured by mapping messages after it applies mapping rules configured by
object-map
config items.This method can be used to provide a user with access to a shared group blotter via a general subject, such as /PRIVATE/FX/GROUPBLOTTER. In the
SettlementInstructionListener.settlementInstructionChannelOpened(SettlementInstructionChannel)
method for the general subject, determine which group the user is a member of and callsendSettlementInstructionMapping(java.lang.String)
, passing it the subject of the group's blotter.- Parameters:
newSubject
- the subject to map this blotter's subject to
-
sendSettlementInstructionStatusOk
Send status ok for a
BlotterItem
.Under normal circumstances this method is not used.
- Parameters:
uniqueId
- of the message whose status is OK
-
sendSettlementInstructionStatusStale
Send status stale for a
BlotterItem
.Under normal circumstances this method is not used.
- Parameters:
uniqueId
- of the message whose status is STALE
-
sendSettlementInstructionStatusOk
public void sendSettlementInstructionStatusOk()Sends a status ok on the channel.
Under normal circumstances this method is not used.
-
sendSettlementInstructionContainerStatusStale
Sends a status stale on the channel with custom message.
Under normal circumstances this method is not used.
-
sendSettlementInstructionContainerStatusOk
Sends a status ok on the channel with custom message.
Under normal circumstances this method is not used.
-
sendSettlementInstructionContainerStatusStale
public void sendSettlementInstructionContainerStatusStale()Sends a status stale on the channel.
Under normal circumstances this method is not used.
-
sendEmptySettlementInstructionContainer
public void sendEmptySettlementInstructionContainer()Sends an empty container on the channel.
Invoke when a
SettlementInstructionListener.settlementInstructionChannelOpened(SettlementInstructionChannel)
callback is received and there are currently noBlotterItem
s to be added for the channel.Note: This method is not required if the blotter Configuration option
BlotterConfiguration.setAutoSendEmptyContainer()
is turned on, in which case the API will send out an empty container for a settlement instruction channel that was opened - unless it is materialized paths
-