Class LBNConfigurationBuilder
java.lang.Object
com.caplin.motif.fx.ret.lbn.config.LBNConfigurationBuilder
This class produces a LBNConfiguration which can be used to instantiate an LBNAdapter.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionThis class produces a LBNConfiguration which can be used to instantiate aLBNAdapter. -
Method Summary
Modifier and TypeMethodDescriptionaddBlotterType(BlotterType blotterType) Adds a blotter type to the LBN adapter.build()Creates an instance of LBNConfiguration which can be used to instantiate a LBNAdapter.Sets a customAdapterConfigurationListenerto load custom configurations.setBlotterCriteriaFactory(BlotterCriteriaFactory blotterCriteriaFactory) Sets the factory used to generate LBN queriessetBlotterItemFieldsUpdater(BlotterRecordFieldsUpdater fieldsUpdater) Deprecated.setBlotterRecordFactory(com.caplin.motif.fx.ret.lbn.internal.BlotterRecordFactory blotterRecordFactory) Sets a customBlotterRecordFactoryto override the default factory used to create blotter records from RET deal records.setBlotterRecordIdFactory(BlotterRecordIdFactory blotterRecordIdFactory) Sets a customBlotterRecordIdFactoryto override the default id factory for the executed blotter.setConfigurationLoader(ConfigurationLoader configurationLoader) Sets a customConfigurationLoaderto replace the OrderAdapter's default behaviour.setCustomFieldValuesSerialiser(CustomFieldValuesSerialiser customFieldValuesSerialiser) Sets a customCustomFieldValuesSerialiserused to serialise/deserialiseCustomFieldValuesobjects.setDataSource(com.caplin.datasource.DataSource dataSource) Sets a customDataSourceto extend the LBNAdapter's default behaviour.setDisplayFieldsUpdater(DisplayFieldsUpdater displayFieldsUpdater) Sets a customDisplayFieldsUpdaterused to modifyDisplayFieldsobjects.setLBNCustomFieldsFactory(LBNCustomFieldsFactory lbnCustomFieldsFactory) Sets a customLBNCustomFieldsFactoryto override the LBNAdapter's default LBNCustomFieldsFactory.setUserManager(UserManager userManager) Sets a customUserManagerto override the LBNAdapter's default UserManager.
-
Field Details
-
ADAPTER_NAME
- See Also:
-
-
Constructor Details
-
LBNConfigurationBuilder
This class produces a LBNConfiguration which can be used to instantiate aLBNAdapter.- Throws:
ConfigurationLoaderException
-
-
Method Details
-
setBlotterItemFieldsUpdater
@Deprecated public LBNConfigurationBuilder setBlotterItemFieldsUpdater(BlotterRecordFieldsUpdater fieldsUpdater) Deprecated.BlotterRecordFieldsUpdaterhas been deprecated. Please useLBNCustomFieldsFactory.Sets a custom
BlotterRecordFieldsUpdaterto override the LBNAdapter's default BlotterItemFieldsUpdater. The BlotterItemFieldsUpdater allows the user to receive fields to be sent for a blotter record. The custom BlotterItemFieldsUpdater can change, add, remove fields on the record.- Parameters:
fieldsUpdater- A customBlotterRecordFieldsUpdater- Returns:
- the LBNConfigurationBuilder
- See Also:
-
setLBNCustomFieldsFactory
public LBNConfigurationBuilder setLBNCustomFieldsFactory(LBNCustomFieldsFactory lbnCustomFieldsFactory) Sets a customLBNCustomFieldsFactoryto override the LBNAdapter's default LBNCustomFieldsFactory. The LBNCustomFieldsFactory allows the user to receive fields to be sent for a blotter record. The custom LBNCustomFieldsFactory can add more fields on the record.- Parameters:
lbnCustomFieldsFactory- A customLBNCustomFieldsFactory- Returns:
- the LBNConfigurationBuilder
-
setBlotterRecordIdFactory
public LBNConfigurationBuilder setBlotterRecordIdFactory(BlotterRecordIdFactory blotterRecordIdFactory) Sets a customBlotterRecordIdFactoryto override the default id factory for the executed blotter.- Parameters:
blotterRecordIdFactory- A customBlotterRecordIdFactory- Returns:
- the LBNConfigurationBuilder
- See Also:
-
setBlotterRecordFactory
public LBNConfigurationBuilder setBlotterRecordFactory(com.caplin.motif.fx.ret.lbn.internal.BlotterRecordFactory blotterRecordFactory) Sets a customBlotterRecordFactoryto override the default factory used to create blotter records from RET deal records.- Parameters:
blotterRecordFactory- a customBlotterRecordFactory- Returns:
- the LBNConfigurationBuilder
- See Also:
-
BlotterRecordFactory
-
setUserManager
Sets a customUserManagerto override the LBNAdapter's default UserManager.- Parameters:
userManager- a customUserManager- Returns:
- the LBNConfigurationBuilder
- See Also:
-
setAdapterConfigurationListener
public LBNConfigurationBuilder setAdapterConfigurationListener(AdapterConfigurationListener listener) Sets a customAdapterConfigurationListenerto load custom configurations.- Parameters:
listener- The listener that will receive a callback to load custom configurations- Returns:
- the LBNConfigurationBuilder
- See Also:
-
setCustomFieldValuesSerialiser
public LBNConfigurationBuilder setCustomFieldValuesSerialiser(CustomFieldValuesSerialiser customFieldValuesSerialiser) Sets a customCustomFieldValuesSerialiserused to serialise/deserialiseCustomFieldValuesobjects. The resulting serialised objects will be stored in the TakerOrderCustom field.- Parameters:
customFieldValuesSerialiser- The custom serialiser to use when serialising/deserialisingCustomFieldValuesobjects
-
setDisplayFieldsUpdater
Sets a customDisplayFieldsUpdaterused to modifyDisplayFieldsobjects.- Parameters:
displayFieldsUpdater- The custom display fields updater to use when modifyingDisplayFieldsobjects before a trade confirmation is published
-
setDataSource
Sets a customDataSourceto extend the LBNAdapter's default behaviour.- Parameters:
dataSource- a customDataSource- Returns:
- the LBNConfigurationBuilder
- See Also:
-
DataSource
-
setConfigurationLoader
Sets a customConfigurationLoaderto replace the OrderAdapter's default behaviour.- Parameters:
configurationLoader- a customConfigurationLoader- Returns:
- the LBNConfigurationBuilder
- See Also:
-
setBlotterCriteriaFactory
public LBNConfigurationBuilder setBlotterCriteriaFactory(BlotterCriteriaFactory blotterCriteriaFactory) Sets the factory used to generate LBN queries- Returns:
- the LBNConfigurationBuilder
- See Also:
-
addBlotterType
Adds a blotter type to the LBN adapter. Blotters will be loaded in order; as a consequence the first blotter to match the request subject (determined by BlotterType#getSubjectPattern) will handle the request.- Returns:
- the LBNConfigurationBuilder
- See Also:
-
build
Creates an instance of LBNConfiguration which can be used to instantiate a LBNAdapter.- Returns:
- a new LBNConfiguration
-
BlotterRecordFieldsUpdaterhas been deprecated.