Class
caplin.trading.trademodel

AbstractTradeFactory

Extending classes should only implement caplin.trading.trademodel.TradeFactory#createNewTrade. They should also invoke the super constructor.

Constructor Summary

Attributes Name and Description
caplin.trading.trademodel.AbstractTradeFactory( oTradeMessageService)

An abstract TradeFactory implementation that handles trade restoration.

Method Summary

Attributes Name and Description
void restoreExistingTrade(caplin.trading.trademodel.Trade oTrade, Map mFieldMap)

Restores a trade that is currently known on the client.

caplin.trading.trademodel.Trade restoreNewTrade(Map mFieldMap)

Restores a trade that is not known on the client, then returns the newly created trade.

Methods implemented from class caplin.trading.trademodel.TradeFactory:
createNewTrade

Constructor Detail

caplin.trading.trademodel.AbstractTradeFactory( oTradeMessageService)

An abstract TradeFactory implementation that handles trade restoration.

Parameters
oTradeMessageService

Method Detail

void restoreExistingTrade(caplin.trading.trademodel.Trade oTrade, Map mFieldMap)

Restores a trade that is currently known on the client.

Parameters
caplin.trading.trademodel.Trade oTrade the trade object to restore.
Map mFieldMap the trade data to restore the trade with.

caplin.trading.trademodel.Trade restoreNewTrade(Map mFieldMap)

Restores a trade that is not known on the client, then returns the newly created trade. This method internally invokes #restoreExistingTrade on the newly restored trade.

Parameters
Map mFieldMap The data to restore the trade with.
Returns
{caplin.trading.trademodel.Trade} The newly created trade.