• All Known Subinterfaces:
CsvInfoResolver

public interface TradeCsvInfoResolver

Data loaded from a CSV may contain additional information that needs to be captured. This plugin point allows the additional CSV columns to be parsed and captured.

• ### Method Summary

All Methods
Modifier and Type Method and Description
default FraTrade completeTrade(CsvRow row, FraTrade trade)
default FxSingleTrade completeTrade(CsvRow row, FxSingleTrade trade)
default SecurityTrade completeTrade(CsvRow row, SecurityTrade trade)
default SwapTrade completeTrade(CsvRow row, SwapTrade trade)
default TermDepositTrade completeTrade(CsvRow row, TermDepositTrade trade)
ReferenceData getReferenceData()
Gets the reference data being used.
static TradeCsvInfoResolver of(ReferenceData refData)
Obtains an instance that uses the specified set of reference data.
default void parseTradeInfo(CsvRow row, TradeInfoBuilder builder)
Parses attributes into TradeInfo.
static TradeCsvInfoResolver standard()
Obtains an instance that uses the standard set of reference data.
• ### Method Detail

• #### standard

static TradeCsvInfoResolver standard()
Obtains an instance that uses the standard set of reference data.
Returns:
• #### of

static TradeCsvInfoResolver of(ReferenceData refData)
Obtains an instance that uses the specified set of reference data.
Parameters:
refData - the reference data
Returns:
• #### getReferenceData

ReferenceData getReferenceData()
Gets the reference data being used.
Returns:
the reference data

default void parseTradeInfo(CsvRow row,
TradeInfoBuilder builder)
Parses attributes into TradeInfo.

If they are available, the trade ID, date, time and zone will have been set before this method is called. They may be altered if necessary, although this is not recommended.

Parameters:
row - the CSV row to parse
builder - the builder to update

default FraTrade completeTrade(CsvRow row,
FraTrade trade)

This is called after the trade has been parsed and after parseTradeInfo(CsvRow, TradeInfoBuilder).

Parameters:
row - the CSV row to parse
trade - the parsed trade
Returns:

default SecurityTrade completeTrade(CsvRow row,
SecurityTrade trade)

This is called after the trade has been parsed and after parseTradeInfo(CsvRow, TradeInfoBuilder).

Parameters:
row - the CSV row to parse
trade - the parsed trade
Returns:

default SwapTrade completeTrade(CsvRow row,
SwapTrade trade)

This is called after the trade has been parsed and after parseTradeInfo(CsvRow, TradeInfoBuilder).

Parameters:
row - the CSV row to parse
trade - the parsed trade
Returns:

default TermDepositTrade completeTrade(CsvRow row,
TermDepositTrade trade)
This is called after the trade has been parsed and after parseTradeInfo(CsvRow, TradeInfoBuilder).
row - the CSV row to parse
trade - the parsed trade