Class ActivityBlotterService
- All Implemented Interfaces:
com.caplin.datasource.blotter.BlotterApplicationListener
- a request occurs when the user logs in and selects the activity blotter - a discard occurs when the blotter is no longer required by the user - deal updates are triggered after a deal is submitted (for example, the deal changes from 'Submitted' to 'Accepted')
The activity blotter is a session blotter, so updates outside of a user being logged in and having established a channel can safely be ignored.
+----------+ +----------------------+ +-------------------+ |(Blotters)| |ActivityBlotterService| |BlotterDataExtractor| +-----+----+ +----------+-----------+ +---------+---------+ | | | | | | | blotterChannelOpened | | +--------------------->| | | | | | | updateDeal | | |<----------------------| | | | | sendBlotterItem | | |<---------------------| | | | | | | | | | | | | | | blotterChannelClosed | | +--------------------->| | v v v
The ActivityBlotterService gets its data from one of the the BlotterDataProviders, which in turn are updated by a combination of the FX API, as the trade progresses through the trade model states, and TrAPI.
- (concurrent) stores currently in-use channels in a concurrent map - (longlife) alive continually
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
blotterChannelClosed
(com.caplin.datasource.blotter.BlotterChannel channel) Called once when the activity blotter is discarded by the user.void
blotterChannelOpened
(com.caplin.datasource.blotter.BlotterChannel channel) Called once when the activity blotter is subscribed to by the user.void
Called by us whenever the state of a deal changes (notified by the FX API).
-
Constructor Details
-
ActivityBlotterService
-
-
Method Details
-
blotterChannelOpened
public void blotterChannelOpened(com.caplin.datasource.blotter.BlotterChannel channel) Called once when the activity blotter is subscribed to by the user.This method is called automatically by the blotter api.
- Specified by:
blotterChannelOpened
in interfacecom.caplin.datasource.blotter.BlotterApplicationListener
-
blotterChannelClosed
public void blotterChannelClosed(com.caplin.datasource.blotter.BlotterChannel channel) Called once when the activity blotter is discarded by the user.This method is called automatically by the blotter api.
- Specified by:
blotterChannelClosed
in interfacecom.caplin.datasource.blotter.BlotterApplicationListener
-
updateDeal
Called by us whenever the state of a deal changes (notified by the FX API).This method is used to publish the fields associated with each new or updated deal, ie it publishes a line in the activity blotter.
- Parameters:
user
- A string identifying the logged in user, their logged in namedealId
- A string identifying a new or existing dealfields
- A dictionary of field : value pairs
-