uTrade Frontend Algo API  Version 1.0.0.0
μTrade HFT
APIWrapper Class Reference
Inheritance diagram for APIWrapper:

Public Slots

virtual void onModifyStrategy ()
 onModifyStrategy To modify and run the strategy when it is already running can be implemented by user
 

Public Member Functions

void setBaseWrapper (BaseStrategyWrapper *baseStrategyWrapper)
 setBaseWrapper To set the the passed pointer to the pointer of base strategy wrapper class More...
 
BaseStrategyWrappergetBaseWrapper ()
 getBaseWrapper To get the pointer object of base strategy wrapper class More...
 
void setCommonMethodsWrapper (CommonMethodsWrapper *commonMethodsWrapper)
 setCommonMethodsWrapper To set the passed pointer to the pointer of common methods wrapper class More...
 
CommonMethodsWrappergetCommonMethodsWrapper ()
 getCommonMethodsWrapper To get the pointer object of common methods wrapper class More...
 
virtual void getDllVersionString (QString &dllVersionString)
 getDllVersionString To get the dll version string in the passed dllversionstring reference can be implemented by user More...
 
virtual void setBasePointer (BaseStrategyWrapper *ptr)
 setBasePointer To set the passed pointer ptr to assign to base strategy wrapper pointer can be implemented by user More...
 
virtual void initDisplay ()
 initDisplay To initialize the display can be implemented by user
 
virtual void onFirstLegSymbolFocusOut ()
 onFirstLegSymbolFocusOut To be called when the first leg symbol's focus is out can be implemented by user
 
virtual void onFirstLegAccountChanged (bool isChecked)
 onFirstLegAccountChanged To be run when the account of first leg is changed More...
 
virtual void onAddPushButtonClicked ()
 onAddPushButtonClicked To add the strategy in the strategy tabe and database by calling the function on_AddPushButton_Clicked can be implemented by user
 
virtual void onNewPushButtonClicked ()
 onNewPushButtonClicked To call the function on_NewPushButton_Clicked to enable the parameters to add new strategy can be implemented by user
 
virtual void onEditPushButtonClicked ()
 onEditPushButtonClicked To call the function on_EditPushButton_Clicked to edit the added strategy can be implemented by user
 
virtual void onCommitPushButtonClicked ()
 onCommitPushButtonClicked To call the function on_CommitPushButton_Clicked to commit the changes done to strategy can be implemented by user
 
virtual void onStopAllPushButtonclicked ()
 onStopAllPushButtonclicked To call the function on_StopAllPushButton_Clicked to stop all the running strategies can be implemented by user
 
virtual void onRemovePushButtonClicked ()
 onRemovePushButtonClicked To call the function on_RemovePushButton_Clicked to remove the selected strategy from the table can be implemented by user
 
virtual void onStopPushButtonClicked ()
 onStopPushButtonClicked To call the function on_StopPushButton_Clicked to stop the selected running strategy can be implemented by user
 
virtual void onRunPushButtonClicked ()
 onRunPushButtonClicked To call the function on_RunPushButton_Clicked to run the selected startegy can be implemented by user
 
virtual void loadDataFromMarketWatch (qlonglong symbolId, short option)
 loadDataFromMarketWatch To load the data from the market watch of the passed symbol id in the strategy window can be implemented by user More...
 
virtual void sendUserResponse (QMessageBox::StandardButton ret, QSharedPointer< API2::Strategy > strategyResponseSharedPtr)
 sendUserResponse To send the response message to user usnig the passed strategy response shared pointer can be implemented by user More...
 
virtual bool validateData (API2::PORTFOLIO_STATE state)
 validateData To validate the data entered in the strategy parameters before saving it in the strategy table can be implemented by user More...
 
virtual bool buildCommandFromUi (API2::PORTFOLIO_STATE state)
 buildCommandFromUi To fetch the details from the ui parameters and save them in the strategy table can be implemented by user More...
 
virtual void updateSymbolIdsDetail (int row, bool isUpdateAll=false)
 updateSymbolIdsDetail To update the symbol id details in the strategy table can be implemented by user More...
 
virtual void updateRemainingFeilds (int row, QSqlRecord &adminTokenIdData)
 updateRemainingFeilds To update the remaining fields in the strategy table using the passed admimn token id in the passed row can be implemented by user More...
 
virtual bool updateRemainingQty (int row)
 updateRemainingQty To update the remaining quantity in the passed row can be implemented by user More...
 
virtual void setCommandParameters (QSqlRecord &record, int stgCount, short type)
 setCommandParameters To set the command parameters using the passed sql record can be implemented by user More...
 
virtual bool setTotalQtyForLegs (int row, short type, QSqlRecord &oldRecord, const QList< BaseSymbolIds * > &symbolIdsList)
 setTotalQtyForLegs To set the total quantity using old sql record of the passed row of all the passed symbol id list can be implemented by user More...
 
virtual void populateUIPanels (int row, QSqlRecord &record, bool isNew)
 populateUIPanels To populate the ui panel taking values from the strategy table of the passed row can be implemented by user More...
 
virtual void applyUIValidation (short, short state)
 applyUIValidation To apply ui validation so that no invalid data gets saved in the database can be implemented by user More...
 
virtual void updateEditableFieldColor (int row, QColor color)
 updateEditableFieldColor To update the colour of the editable fields of the passed row as the color passed can be implemented by user More...
 
virtual bool updateStrategyDefaultValues (qlonglong adminTokenIdNew)
 updateStrategyDefaultValues To check the updation of the strategy default values using the passed admin token id More...
 
virtual void clearCustomStructure (qlonglong adminTokenIdNew)
 clearCustomStructure To clear the custom structure of the passed new admin token id can be implemented by user More...
 
virtual bool isTotalQtyVailid (int row)
 isTotalQtyVailid To check whether the total qauntity is valid or not total quantity should be greater than the lot size can be implemented by user More...
 
virtual bool isRatioUnChanged (int row)
 isRatioUnChanged To check whether the ratio is unchanged of the passed row can be implemented by user More...
 
virtual void onColumnDoubleClicked (QModelIndex index)
 onColumnDoubleClicked To enable the editable column for editing in the strategy table on double clicking the passed index can be implemented by user More...
 
virtual void updateDisableColumnsColor (int row)
 updateDisableColumnsColor To update the disable columns colour of the selected row as the passed color can be implemented by user More...
 
virtual void setColumnCustomColor (int row)
 setColumnCustomColor To set the columns default colour of the passed row More...
 
virtual bool isSpreadAllowed (short strategy)
 isSpreadAllowed To check whether the spread is allowed for the passed strategy can be implemented by user More...
 
virtual short isIvstrategy (short strategy, int row=-1)
 isIvstrategy To check whether the strategy contains implied volatility can be implemented by user More...
 
virtual bool isNoRemainingQty (int row)
 isNoRemainingQty To check whether their is remaining quantity or not of the passed row can be implemented by user More...
 
virtual bool isBuySellSpreadDiff (short strategy)
 isBuySellSpreadDiff To check whether their is spread diff in the buy sell of the passed strategy can be implemented by user More...
 
virtual void convertToLots (QSqlRecord &record)
 convertToLots To convert the quantity in lots in the passed sql record reference can be implemented by user More...
 
virtual void convertToLots (QModelIndex index)
 convertToLots To convert the quantity in lots of the passed index can be implemented by user More...
 
virtual void allUIValidation (int row=-1, short strategy=STRATEGY_TYPE_MAX)
 allUIValidation To perform all the ui validation of the passed row and strategy type can be implemented by user More...
 
virtual void setPortfolioDefaultValues (QStringList &portfolioRow)
 setPortfolioDefaultValues To set the default portfolio values in the passed portfolio row can be implemented by user More...
 
virtual bool readyStateValidations (int row, QSqlRecord &dbRecord)
 readyStateValidations To validate the passed row which is in ready state from the db record can be implemented by user More...
 
virtual void spreadCalculationMethod (int row, QList< BaseSymbolIds > &symbolIdsList)
 spreadCalculationMethod To calculate spread of passed row of the symbol id list can be implemented by user More...
 
virtual void onSpacePressed ()
 onSpacePressed On pressing space key the editing is enable can be implemented by user
 
virtual void onAltMPressed ()
 onAltMPressed To save the changes done on editable fields in the database can be implemented by user
 
virtual void onEscapePressed ()
 onEscapePressed On pressing Escape key the strategy window will get minimized can be implemented by user
 
virtual void onCtrlSpacePressed ()
 onCtrlSpacePressed On pressing Ctrl Space it uncheckes the selected row and checks the selcted row can be implemented by user
 
virtual void onUpKeyPressed ()
 onUpKeyPressed On pressing up key if strategy container is visible then it hides it otherwise show it can be implemented by user
 
virtual void OnDownKeyPressed ()
 OnDownKeyPressed On down key preesing it make sure that strategy container is visible can be implemented by user.
 
virtual void onRunActivated ()
 onRunActivated On pressing Run push button or clicking the check box of particular row, the strategy will start to run can be implemented by user
 
virtual void onAltSPressed ()
 onAltSPressed On pressing ALt + 'S' the portfolio is saved can be implemented by user
 
virtual void onAltOPressed ()
 onAltOPressed On pressing ALt + 'O' the load portfolio is enabled can be implemented by user
 
virtual void setApiCommand (API2::UserParams *, QSqlRecord &record, int stgCount, short type)
 setApiCommand To set the api command and set default vaues and send the values to the backend from the fronend can be implemented by user More...
 
virtual void setApiCommand (API2::UserParams *, QSqlRecord &record, int stgCount, short type, API2::apiOrderBookParams *ptr)
 setApiCommand can be implemented by user More...
 
virtual API2::UserParams * getAPICommand ()
 getAPICommand To get the api params values form the parameters can be implemented by user More...
 
virtual bool isSpreadCalculationAllowed ()
 isSpreadCalculationAllowed To check whether the spread calculation is allowed can be implemented by user More...
 
virtual bool isPortfolioNamePresent ()
 isPortfolioNamePresent To check whether the portfolio name is present can be implemented by user More...
 
virtual bool isStrategyLegPresent ()
 isStrategyLegPresent To check whether the strategy leg is present can be implemented by user More...
 
virtual bool isSidTotalQtyHandling ()
 isSidTotalQtyHandling To check whether sid total quantity is handling can be implemented by user More...
 
virtual void receiveStrategyResponse (API2::Strategy &strategyResponse)
 receiveStrategyResponse Receives response from hft and if it is success then put it in the queue can be implemented by user More...
 
virtual void updateTrades (const RSP::OrderConfirmation &orderConfirmation)
 updateTrades To update the trades from order confirmation object can be implemented by user More...
 
virtual UNSIGNED_LONG getTotalQuantityForLegs (API2::LEGS)
 getTotalQuantityForLegs To get the total quantity from the passed leg can be implemented by user More...
 
virtual void receiveCustomResponse (API2::API2_CustomResponse &apiCustomResponse)
 receiveCustomResponse To receive custom response from the passed api custom response object can be implemented by user More...
 
virtual bool showSpreadPopup ()
 showSpreadPopup To check whether spread pop up is shown on adding new strategy can be implemented by user More...
 
virtual bool showRemovePopup ()
 showRemovePopup To check whether remove pop up is shown on removing strategy can be implemented by user More...
 
virtual void getHitTrySpread (short spreadType, const QList< BaseSymbolIds * > &symbolIdsList, SpreadDetails *spreadDetail, int row=-1)
 getHitTrySpread To get the hit try spread of passed spread type from the symbol id list of the passed row can be implemented by user More...
 
virtual void updateAccountDetail (const int row)
 updateAccountDetail To update the account deatils of the passed row in the database can be implemented by user More...
 
virtual void keyPressEventStrategySpecific ()
 keyPressEventStrategySpecific To create a key press event for specific strategy can be implemented by user
 
virtual void populateIvUnderlying (const qlonglong &symbolId, const int &count)
 populateIvUnderlying To populate the underlying iv of the passed symbol id can be implemented by user More...
 
virtual bool validatePortFolioData (QStringList &dataList, QString &errorText, int portfolioCount)
 validatePortFolioData To validate the portfolio data from the passed reference datalist and return error if any in errortext reference can be implemented by user More...
 
virtual void showHideCheckBoxClicked (bool isChecked)
 showHideCheckBoxClicked To chow/hide the check box in the button panel can be implemented by user More...
 
virtual void revertEditableFeildData (int row)
 revertEditableFeildData To revert the changes done in editable fields of passed row can be implemented by user More...
 
virtual void firstLegSymbolChanged ()
 firstLegSymbolChanged On first leg symbol changed show the selected leg symbols and details can be implemented by user
 
virtual void onFirstLegMarketChanged ()
 onFirstLegMarketChanged On First leg market changed show the symbols accordingly can be implemented by user
 
virtual void onFirstLegExpiryChanged ()
 onFirstLegExpiryChanged On First leg expiry change, change other details accordingly can be implemented by user
 
virtual void onFirstLegOptTypeChanged ()
 onFirstLegOptTypeChanged On First leg opt type change, change other details accordingly can be implemented by user
 
virtual void secondLegSymbolChanged ()
 secondLegSymbolChanged On Second leg symbol changed show the selected leg symbols and details can be implemented by user
 
virtual void onSecondLegMarketChanged ()
 onSecondLegMarketChanged On Second leg market changed show the symbols accordingly can be implemented by user
 
virtual void onMarketChanged ()
 onMarketChanged On market change show the symbols and other data for the same can be implemented by user
 
virtual void on_radioButtonClientAccount1_toggled (bool checked)
 on_radioButtonClientAccount1_toggled On toggling the radio button of client and pro, changes show on the account name can be implemented by user More...
 
virtual bool terminateValidation (int row, QString &error)
 terminateValidation To check whether the validation is terminated and give the error in the passed reference can be implemented by user More...
 
virtual bool isAlwaysArchive ()
 isAlwaysArchive To check whether it is always archived can be implemented by user More...
 
virtual void updateFieldsOnLoadOld (int row)
 updateFieldsOnLoadOld To update the fields on loading the old data from row can be implemented by user More...
 
virtual void onRowClickedNotifier (int rowClicked)
 onRowClickedNotifier To notify when the passed row is clicked can be implemented by user More...
 
virtual void onShowHideLegs ()
 onShowHideLegs To show/hide the legs can be implemented by user
 
virtual void updateOldStrategyId (qlonglong strategyId, qlonglong adminTokenId)
 updateOldStrategyId To update the old strategy id with passed admin token id can be implemented by user More...
 
virtual bool byPassRunAddedStrategy ()
 byPassRunAddedStrategy can be implemented by user More...
 
virtual bool showRunAddedStrategyPopup ()
 showRunAddedStrategyPopup To show the pop up to run the strategy when added new strategy can be implemented by user More...
 
virtual bool isWaitStateSupported ()
 isWaitStateSupported To check whether the wait state is supported by that strategy can be implemented by user More...
 
virtual void rowRemovedNotifier (int row, int pid=0)
 rowRemovedNotifier To notify when the row that is removed is the passed row can be implemented by user More...
 
virtual bool isSpreadAlgo ()
 isSpreadAlgo To check whether the given algo is spread algo can be implemented by user More...
 
virtual bool showAdditionalSpreadPopups (short strategy, QSqlRecord &adminTokenIdData, bool isModify=false)
 showAdditionalSpreadPopups To check whether to show the additional spread pop ups of passed admin token id can be implemented by user More...
 
virtual void updateAdditionalValuesInPortfolio (QStringList &dataList)
 updateAdditionalValuesInPortfolio To update the additional values in the portfolio from the datalist can be implemented by user More...
 
virtual bool isDisplayInLotsAllowed ()
 isDisplayInLotsAllowed To check whether to display in lots is allowed can be implemented by user More...
 
virtual bool validatePortFolioDataOnLoadOld (qlonglong adminTokenId)
 validatePortFolioDataOnLoadOld To validate portfolio data while loading the old data can be implemented by user More...
 
virtual bool isSameSidHandling ()
 isSameSidHandling To check whether their is handling of more than one same strategy quauntity can be implemented by user More...
 
virtual void updateCustomDbValuesOnLoadOld ()
 updateCustomDbValuesOnLoadOld To update the custom database values on loading old data can be implemented by user
 
virtual bool validatePortFolioDataWithErrorText (qlonglong adminTokenId, QStringList &errorText)
 
virtual QKeySequence getStrategyShortCut (short orderMode)
 getStrategyShortCut To get the shortcut of the strategy of passed order mode can be implemented by user More...
 
virtual void showByPopulatingSymbolPanel (qlonglong symbolId, QKeySequence sequence=QKeySequence::UnknownKey)
 showByPopulatingSymbolPanel To show by populating the symbol panel from the passed symbol id can be implemented by user More...
 
virtual bool isStrategyCompletedState (int row)
 isStrategyCompletedState To check whether the strategy is in completed state can be implemented by user More...
 
virtual bool isTruncateOnArchive ()
 isTruncateOnArchive To check whether it is going to be truncated on archive can be implemented by user More...
 
virtual QString getSymbolString (bool isAdd, int row=-1)
 getSymbolString To get the symbol string from the passed row can be implemented by user More...
 
virtual void fillOldPositionData (QStringList &dataList)
 fillOldPositionData To fill the old position data from the passed datalist can be implemented by user More...
 
virtual void closeOpenDialog ()
 closeOpenDialog To open/close dialog can be implemented by user
 
virtual void resetTotalQtyForLegs ()
 resetTotalQtyForLegs To reset the total quantity for legs to again start again with 0 can be implemented by user
 
virtual void insertCustomSymbolDetailParameters (BaseSymbolIds *symbolIds, int row)
 insertCustomSymbolDetailParameters To insert the custom symbol detail parameters from the passed symbol id in the passed row can be implemented by user More...
 
virtual QString getTrackerTableName ()
 getTrackerTableName To get the tracker table name can be implemented by user More...
 
virtual bool isTracker ()
 isTracker To check whether it is tracker can be implemented by user More...
 
virtual void loadOldTrackerData ()
 loadOldTrackerData To load old tracker data can be implemented by user
 
virtual void firstLegAccountUpdated ()
 firstLegAccountUpdated On Updating the account deatils of the first leg can be implemented by user
 
virtual void secondLegAccountUpdated ()
 secondLegAccountUpdated On Updating the account deatils of the second leg can be implemented by user
 
virtual QString getStrategyDisplayName ()
 getStrategyDisplayName To get the strategy name to display on the window can be implemented by user More...
 
virtual void thirdLegAccountUpdated ()
 thirdLegAccountUpdated On Updating the account deatils of the third leg can be implemented by user
 
virtual void replacePortfolioValuesOnSave (QStringList &dataList)
 replacePortfolioValuesOnSave To Replace portfolio values that need to changed while saving portfolio can be implemented by user More...
 
virtual void replacePortfolioValuesOnLoad (QStringList &dataList)
 replacePortfolioValuesOnLoad To Replace portfolio values that need to changed while loading portfolio can be implemented by user More...
 
virtual void modifySaveFileHeader (QString &headerRow)
 modifySaveFileHeader To modify save file header in case implementing custom portfolio save can be implemented by user More...
 
virtual void updateSidQty (qlonglong row)
 updateSidQty To update the total strategy quantity in the passed row can be implemented by user More...
 
virtual void changesOnTermiantion (int rowClicked)
 changesOnTermiantion To do the changes done on termination in the passed row can be implemented by user More...
 
virtual bool isStrategyIdExists (qlonglong strategyId)
 isStrategyIdExists To check whether their exists any other strategy id same as passed strategy id can be implemented by user More...
 
virtual bool isUniqueSpreadHandling ()
 isUniqueSpreadHandling To check whether the handling of unique spread is done can be implemented by user More...
 
virtual void getUniqueSpreadKeyValuePair (QPair< QString, QString > &uniqueSpreadKeyValuePair, int row=-1, const QStringList &dataList=QStringList())
 getUniqueSpreadKeyValuePair Used for unique spread key on addding,loading portfolio, eq. -> uniquekey = "Symbol1 : Symbol 2 = Spread " can be implemented by user More...
 
virtual bool isPortfolioNewLoadSaveHandling ()
 isPortfolioNewLoadSaveHandling To check whether the handlilng of new, load and save portfolio is done can be implemented by user More...
 
virtual void updateNonPortfolioDbParams (QMap< QString, QString > &nonPortfolioDbParams, QStringList &dataList)
 updateNonPortfolioDbParams To update database parameters that are not in portfolio can be implemented by user More...
 
virtual void destroyDependendObjects ()
 destroyDependendObjects To Destroy objects dependent on basestrategywrapper from its destructor can be implemented by user
 
virtual void updateCustomValuesInUiOnModify (int row)
 updateCustomValuesInUiOnModify To update the custom values of strategy in ui when strategy is already running can be implemented by user More...
 
virtual bool customUniqueSpreadHandlingCheck (int row=-1, const QStringList &dataList=QStringList())
 customUniqueSpreadHandlingCheck To check whether the custom unique spread check is handling can be implemented by user More...
 
virtual bool isBidAllowed ()
 isBidAllowed To check whether the Bid is allowed for placing the given order can be implemented by user More...
 
virtual bool isIocAllowed ()
 isIocAllowed To check whether the IOC is allowed for the given specifications can be implemented by user More...
 
virtual bool isMulIocAllowed ()
 isMulIocAllowed To check whether the validity is mulyi IOC can be implemented by user More...
 

Member Function Documentation

◆ allUIValidation()

virtual void APIWrapper::allUIValidation ( int  row = -1,
short  strategy = STRATEGY_TYPE_MAX 
)
inlinevirtual

allUIValidation To perform all the ui validation of the passed row and strategy type can be implemented by user

Parameters
row
strategy

◆ applyUIValidation()

virtual void APIWrapper::applyUIValidation ( short  ,
short  state 
)
inlinevirtual

applyUIValidation To apply ui validation so that no invalid data gets saved in the database can be implemented by user

Parameters
state

◆ buildCommandFromUi()

virtual bool APIWrapper::buildCommandFromUi ( API2::PORTFOLIO_STATE  state)
inlinevirtual

buildCommandFromUi To fetch the details from the ui parameters and save them in the strategy table can be implemented by user

Parameters
state
Returns
By default it returns true

◆ byPassRunAddedStrategy()

virtual bool APIWrapper::byPassRunAddedStrategy ( )
inlinevirtual

byPassRunAddedStrategy can be implemented by user

Returns
default return value is false

◆ changesOnTermiantion()

virtual void APIWrapper::changesOnTermiantion ( int  rowClicked)
inlinevirtual

changesOnTermiantion To do the changes done on termination in the passed row can be implemented by user

Parameters
rowClicked

◆ clearCustomStructure()

virtual void APIWrapper::clearCustomStructure ( qlonglong  adminTokenIdNew)
inlinevirtual

clearCustomStructure To clear the custom structure of the passed new admin token id can be implemented by user

Parameters
adminTokenIdNew

◆ convertToLots() [1/2]

virtual void APIWrapper::convertToLots ( QSqlRecord &  record)
inlinevirtual

convertToLots To convert the quantity in lots in the passed sql record reference can be implemented by user

Parameters
record

◆ convertToLots() [2/2]

virtual void APIWrapper::convertToLots ( QModelIndex  index)
inlinevirtual

convertToLots To convert the quantity in lots of the passed index can be implemented by user

Parameters
index

◆ customUniqueSpreadHandlingCheck()

virtual bool APIWrapper::customUniqueSpreadHandlingCheck ( int  row = -1,
const QStringList &  dataList = QStringList() 
)
inlinevirtual

customUniqueSpreadHandlingCheck To check whether the custom unique spread check is handling can be implemented by user

Parameters
row
dataList
Returns
By default it returns true

◆ fillOldPositionData()

virtual void APIWrapper::fillOldPositionData ( QStringList &  dataList)
inlinevirtual

fillOldPositionData To fill the old position data from the passed datalist can be implemented by user

Parameters
dataList

◆ getAPICommand()

virtual API2::UserParams* APIWrapper::getAPICommand ( )
inlinevirtual

getAPICommand To get the api params values form the parameters can be implemented by user

Returns
default return value is NULL

◆ getBaseWrapper()

BaseStrategyWrapper* APIWrapper::getBaseWrapper ( )
inline

getBaseWrapper To get the pointer object of base strategy wrapper class

Returns

◆ getCommonMethodsWrapper()

CommonMethodsWrapper* APIWrapper::getCommonMethodsWrapper ( )
inline

getCommonMethodsWrapper To get the pointer object of common methods wrapper class

Returns

◆ getDllVersionString()

virtual void APIWrapper::getDllVersionString ( QString &  dllVersionString)
inlinevirtual

getDllVersionString To get the dll version string in the passed dllversionstring reference can be implemented by user

Parameters
dllVersionString

◆ getHitTrySpread()

virtual void APIWrapper::getHitTrySpread ( short  spreadType,
const QList< BaseSymbolIds * > &  symbolIdsList,
SpreadDetails spreadDetail,
int  row = -1 
)
inlinevirtual

getHitTrySpread To get the hit try spread of passed spread type from the symbol id list of the passed row can be implemented by user

Parameters
spreadType
symbolIdsList
spreadDetail
row

◆ getStrategyDisplayName()

virtual QString APIWrapper::getStrategyDisplayName ( )
inlinevirtual

getStrategyDisplayName To get the strategy name to display on the window can be implemented by user

Returns

◆ getStrategyShortCut()

virtual QKeySequence APIWrapper::getStrategyShortCut ( short  orderMode)
inlinevirtual

getStrategyShortCut To get the shortcut of the strategy of passed order mode can be implemented by user

Parameters
orderMode
Returns

◆ getSymbolString()

virtual QString APIWrapper::getSymbolString ( bool  isAdd,
int  row = -1 
)
inlinevirtual

getSymbolString To get the symbol string from the passed row can be implemented by user

Parameters
isAdd
row
Returns

◆ getTotalQuantityForLegs()

virtual UNSIGNED_LONG APIWrapper::getTotalQuantityForLegs ( API2::LEGS  )
inlinevirtual

getTotalQuantityForLegs To get the total quantity from the passed leg can be implemented by user

Returns
default return value is 0

◆ getTrackerTableName()

virtual QString APIWrapper::getTrackerTableName ( )
inlinevirtual

getTrackerTableName To get the tracker table name can be implemented by user

Returns

◆ getUniqueSpreadKeyValuePair()

virtual void APIWrapper::getUniqueSpreadKeyValuePair ( QPair< QString, QString > &  uniqueSpreadKeyValuePair,
int  row = -1,
const QStringList &  dataList = QStringList() 
)
inlinevirtual

getUniqueSpreadKeyValuePair Used for unique spread key on addding,loading portfolio, eq. -> uniquekey = "Symbol1 : Symbol 2 = Spread " can be implemented by user

Parameters
QPair<QString,QString> &uniqueSpreadKeyValuePair,int row = -1 , const QStringList &dataList = QStringList()
Returns
void

◆ insertCustomSymbolDetailParameters()

virtual void APIWrapper::insertCustomSymbolDetailParameters ( BaseSymbolIds symbolIds,
int  row 
)
inlinevirtual

insertCustomSymbolDetailParameters To insert the custom symbol detail parameters from the passed symbol id in the passed row can be implemented by user

Parameters
symbolIds
row

◆ isAlwaysArchive()

virtual bool APIWrapper::isAlwaysArchive ( )
inlinevirtual

isAlwaysArchive To check whether it is always archived can be implemented by user

Returns
default return value is false

◆ isBidAllowed()

virtual bool APIWrapper::isBidAllowed ( )
inlinevirtual

isBidAllowed To check whether the Bid is allowed for placing the given order can be implemented by user

Returns
default return value is false

◆ isBuySellSpreadDiff()

virtual bool APIWrapper::isBuySellSpreadDiff ( short  strategy)
inlinevirtual

isBuySellSpreadDiff To check whether their is spread diff in the buy sell of the passed strategy can be implemented by user

Parameters
strategy
Returns
default return value is false

◆ isDisplayInLotsAllowed()

virtual bool APIWrapper::isDisplayInLotsAllowed ( )
inlinevirtual

isDisplayInLotsAllowed To check whether to display in lots is allowed can be implemented by user

Returns
default return value is false

◆ isIocAllowed()

virtual bool APIWrapper::isIocAllowed ( )
inlinevirtual

isIocAllowed To check whether the IOC is allowed for the given specifications can be implemented by user

Returns
default return value is false

◆ isIvstrategy()

virtual short APIWrapper::isIvstrategy ( short  strategy,
int  row = -1 
)
inlinevirtual

isIvstrategy To check whether the strategy contains implied volatility can be implemented by user

Parameters
strategy
row
Returns
default return value is -1

◆ isMulIocAllowed()

virtual bool APIWrapper::isMulIocAllowed ( )
inlinevirtual

isMulIocAllowed To check whether the validity is mulyi IOC can be implemented by user

Returns
default return value is false

◆ isNoRemainingQty()

virtual bool APIWrapper::isNoRemainingQty ( int  row)
inlinevirtual

isNoRemainingQty To check whether their is remaining quantity or not of the passed row can be implemented by user

Parameters
row
Returns
default return value is false

◆ isPortfolioNamePresent()

virtual bool APIWrapper::isPortfolioNamePresent ( )
inlinevirtual

isPortfolioNamePresent To check whether the portfolio name is present can be implemented by user

Returns
By default it returns true

◆ isPortfolioNewLoadSaveHandling()

virtual bool APIWrapper::isPortfolioNewLoadSaveHandling ( )
inlinevirtual

isPortfolioNewLoadSaveHandling To check whether the handlilng of new, load and save portfolio is done can be implemented by user

Returns
default return value is false

◆ isRatioUnChanged()

virtual bool APIWrapper::isRatioUnChanged ( int  row)
inlinevirtual

isRatioUnChanged To check whether the ratio is unchanged of the passed row can be implemented by user

Parameters
row
Returns
By default it returns true

◆ isSameSidHandling()

virtual bool APIWrapper::isSameSidHandling ( )
inlinevirtual

isSameSidHandling To check whether their is handling of more than one same strategy quauntity can be implemented by user

Returns
default return value is false

◆ isSidTotalQtyHandling()

virtual bool APIWrapper::isSidTotalQtyHandling ( )
inlinevirtual

isSidTotalQtyHandling To check whether sid total quantity is handling can be implemented by user

Returns
By default it returns true

◆ isSpreadAlgo()

virtual bool APIWrapper::isSpreadAlgo ( )
inlinevirtual

isSpreadAlgo To check whether the given algo is spread algo can be implemented by user

Returns
default return value is false

◆ isSpreadAllowed()

virtual bool APIWrapper::isSpreadAllowed ( short  strategy)
inlinevirtual

isSpreadAllowed To check whether the spread is allowed for the passed strategy can be implemented by user

Parameters
strategy
Returns
default return value is false

◆ isSpreadCalculationAllowed()

virtual bool APIWrapper::isSpreadCalculationAllowed ( )
inlinevirtual

isSpreadCalculationAllowed To check whether the spread calculation is allowed can be implemented by user

Returns
By default it returns true

◆ isStrategyCompletedState()

virtual bool APIWrapper::isStrategyCompletedState ( int  row)
inlinevirtual

isStrategyCompletedState To check whether the strategy is in completed state can be implemented by user

Parameters
row
Returns
default return value is false

◆ isStrategyIdExists()

virtual bool APIWrapper::isStrategyIdExists ( qlonglong  strategyId)
inlinevirtual

isStrategyIdExists To check whether their exists any other strategy id same as passed strategy id can be implemented by user

Parameters
strategyId
Returns
default return value is false

◆ isStrategyLegPresent()

virtual bool APIWrapper::isStrategyLegPresent ( )
inlinevirtual

isStrategyLegPresent To check whether the strategy leg is present can be implemented by user

Returns
By default it returns true

◆ isTotalQtyVailid()

virtual bool APIWrapper::isTotalQtyVailid ( int  row)
inlinevirtual

isTotalQtyVailid To check whether the total qauntity is valid or not total quantity should be greater than the lot size can be implemented by user

Parameters
row
Returns
By default it returns true

◆ isTracker()

virtual bool APIWrapper::isTracker ( )
inlinevirtual

isTracker To check whether it is tracker can be implemented by user

Returns
default return value is false

◆ isTruncateOnArchive()

virtual bool APIWrapper::isTruncateOnArchive ( )
inlinevirtual

isTruncateOnArchive To check whether it is going to be truncated on archive can be implemented by user

Returns
default return value is false

◆ isUniqueSpreadHandling()

virtual bool APIWrapper::isUniqueSpreadHandling ( )
inlinevirtual

isUniqueSpreadHandling To check whether the handling of unique spread is done can be implemented by user

Returns
default return value is false

◆ isWaitStateSupported()

virtual bool APIWrapper::isWaitStateSupported ( )
inlinevirtual

isWaitStateSupported To check whether the wait state is supported by that strategy can be implemented by user

Returns
default return value is false

◆ loadDataFromMarketWatch()

virtual void APIWrapper::loadDataFromMarketWatch ( qlonglong  symbolId,
short  option 
)
inlinevirtual

loadDataFromMarketWatch To load the data from the market watch of the passed symbol id in the strategy window can be implemented by user

Parameters
symbolId
option

◆ modifySaveFileHeader()

virtual void APIWrapper::modifySaveFileHeader ( QString &  headerRow)
inlinevirtual

modifySaveFileHeader To modify save file header in case implementing custom portfolio save can be implemented by user

Parameters
QString&headerRow

◆ on_radioButtonClientAccount1_toggled()

virtual void APIWrapper::on_radioButtonClientAccount1_toggled ( bool  checked)
inlinevirtual

on_radioButtonClientAccount1_toggled On toggling the radio button of client and pro, changes show on the account name can be implemented by user

Parameters
checked

◆ onColumnDoubleClicked()

virtual void APIWrapper::onColumnDoubleClicked ( QModelIndex  index)
inlinevirtual

onColumnDoubleClicked To enable the editable column for editing in the strategy table on double clicking the passed index can be implemented by user

Parameters
index

◆ onFirstLegAccountChanged()

virtual void APIWrapper::onFirstLegAccountChanged ( bool  isChecked)
inlinevirtual

onFirstLegAccountChanged To be run when the account of first leg is changed

Parameters
isChecked

◆ onRowClickedNotifier()

virtual void APIWrapper::onRowClickedNotifier ( int  rowClicked)
inlinevirtual

onRowClickedNotifier To notify when the passed row is clicked can be implemented by user

Parameters
rowClicked

◆ populateIvUnderlying()

virtual void APIWrapper::populateIvUnderlying ( const qlonglong &  symbolId,
const int &  count 
)
inlinevirtual

populateIvUnderlying To populate the underlying iv of the passed symbol id can be implemented by user

Parameters
symbolId
count

◆ populateUIPanels()

virtual void APIWrapper::populateUIPanels ( int  row,
QSqlRecord &  record,
bool  isNew 
)
inlinevirtual

populateUIPanels To populate the ui panel taking values from the strategy table of the passed row can be implemented by user

Parameters
row
record
isNew

◆ readyStateValidations()

virtual bool APIWrapper::readyStateValidations ( int  row,
QSqlRecord &  dbRecord 
)
inlinevirtual

readyStateValidations To validate the passed row which is in ready state from the db record can be implemented by user

Parameters
row
dbRecord
Returns
By default it returns true

◆ receiveCustomResponse()

virtual void APIWrapper::receiveCustomResponse ( API2::API2_CustomResponse &  apiCustomResponse)
inlinevirtual

receiveCustomResponse To receive custom response from the passed api custom response object can be implemented by user

Parameters
apiCustomResponse

◆ receiveStrategyResponse()

virtual void APIWrapper::receiveStrategyResponse ( API2::Strategy &  strategyResponse)
inlinevirtual

receiveStrategyResponse Receives response from hft and if it is success then put it in the queue can be implemented by user

Parameters
strategyResponse

◆ replacePortfolioValuesOnLoad()

virtual void APIWrapper::replacePortfolioValuesOnLoad ( QStringList &  dataList)
inlinevirtual

replacePortfolioValuesOnLoad To Replace portfolio values that need to changed while loading portfolio can be implemented by user

Parameters
QStringList&dataList

◆ replacePortfolioValuesOnSave()

virtual void APIWrapper::replacePortfolioValuesOnSave ( QStringList &  dataList)
inlinevirtual

replacePortfolioValuesOnSave To Replace portfolio values that need to changed while saving portfolio can be implemented by user

Parameters
QStringList&dataList

◆ revertEditableFeildData()

virtual void APIWrapper::revertEditableFeildData ( int  row)
inlinevirtual

revertEditableFeildData To revert the changes done in editable fields of passed row can be implemented by user

Parameters
row

◆ rowRemovedNotifier()

virtual void APIWrapper::rowRemovedNotifier ( int  row,
int  pid = 0 
)
inlinevirtual

rowRemovedNotifier To notify when the row that is removed is the passed row can be implemented by user

Parameters
row
pid

◆ sendUserResponse()

virtual void APIWrapper::sendUserResponse ( QMessageBox::StandardButton  ret,
QSharedPointer< API2::Strategy >  strategyResponseSharedPtr 
)
inlinevirtual

sendUserResponse To send the response message to user usnig the passed strategy response shared pointer can be implemented by user

Parameters
ret
strategyResponseSharedPtr

◆ setApiCommand() [1/2]

virtual void APIWrapper::setApiCommand ( API2::UserParams *  ,
QSqlRecord &  record,
int  stgCount,
short  type 
)
inlinevirtual

setApiCommand To set the api command and set default vaues and send the values to the backend from the fronend can be implemented by user

Parameters
record
stgCount
type

◆ setApiCommand() [2/2]

virtual void APIWrapper::setApiCommand ( API2::UserParams *  ,
QSqlRecord &  record,
int  stgCount,
short  type,
API2::apiOrderBookParams ptr 
)
inlinevirtual

setApiCommand can be implemented by user

Parameters
record
stgCount
type
ptr

◆ setBasePointer()

virtual void APIWrapper::setBasePointer ( BaseStrategyWrapper ptr)
inlinevirtual

setBasePointer To set the passed pointer ptr to assign to base strategy wrapper pointer can be implemented by user

Parameters
ptr

◆ setBaseWrapper()

void APIWrapper::setBaseWrapper ( BaseStrategyWrapper baseStrategyWrapper)
inline

setBaseWrapper To set the the passed pointer to the pointer of base strategy wrapper class

Parameters
baseStrategyWrapper

◆ setColumnCustomColor()

virtual void APIWrapper::setColumnCustomColor ( int  row)
inlinevirtual

setColumnCustomColor To set the columns default colour of the passed row

Parameters
row

◆ setCommandParameters()

virtual void APIWrapper::setCommandParameters ( QSqlRecord &  record,
int  stgCount,
short  type 
)
inlinevirtual

setCommandParameters To set the command parameters using the passed sql record can be implemented by user

Parameters
record
stgCount
type

◆ setCommonMethodsWrapper()

void APIWrapper::setCommonMethodsWrapper ( CommonMethodsWrapper commonMethodsWrapper)
inline

setCommonMethodsWrapper To set the passed pointer to the pointer of common methods wrapper class

Parameters
commonMethodsWrapper

◆ setPortfolioDefaultValues()

virtual void APIWrapper::setPortfolioDefaultValues ( QStringList &  portfolioRow)
inlinevirtual

setPortfolioDefaultValues To set the default portfolio values in the passed portfolio row can be implemented by user

Parameters
portfolioRow

◆ setTotalQtyForLegs()

virtual bool APIWrapper::setTotalQtyForLegs ( int  row,
short  type,
QSqlRecord &  oldRecord,
const QList< BaseSymbolIds * > &  symbolIdsList 
)
inlinevirtual

setTotalQtyForLegs To set the total quantity using old sql record of the passed row of all the passed symbol id list can be implemented by user

Parameters
row
type
oldRecord
symbolIdsList
Returns

◆ showAdditionalSpreadPopups()

virtual bool APIWrapper::showAdditionalSpreadPopups ( short  strategy,
QSqlRecord &  adminTokenIdData,
bool  isModify = false 
)
inlinevirtual

showAdditionalSpreadPopups To check whether to show the additional spread pop ups of passed admin token id can be implemented by user

Parameters
strategy
adminTokenIdData
isModify
Returns
default return value is false

◆ showByPopulatingSymbolPanel()

virtual void APIWrapper::showByPopulatingSymbolPanel ( qlonglong  symbolId,
QKeySequence  sequence = QKeySequence::UnknownKey 
)
inlinevirtual

showByPopulatingSymbolPanel To show by populating the symbol panel from the passed symbol id can be implemented by user

Parameters
symbolId
sequence

◆ showHideCheckBoxClicked()

virtual void APIWrapper::showHideCheckBoxClicked ( bool  isChecked)
inlinevirtual

showHideCheckBoxClicked To chow/hide the check box in the button panel can be implemented by user

Parameters
isChecked

◆ showRemovePopup()

virtual bool APIWrapper::showRemovePopup ( )
inlinevirtual

showRemovePopup To check whether remove pop up is shown on removing strategy can be implemented by user

Returns
By default it returns true

◆ showRunAddedStrategyPopup()

virtual bool APIWrapper::showRunAddedStrategyPopup ( )
inlinevirtual

showRunAddedStrategyPopup To show the pop up to run the strategy when added new strategy can be implemented by user

Returns
By default it returns true

◆ showSpreadPopup()

virtual bool APIWrapper::showSpreadPopup ( )
inlinevirtual

showSpreadPopup To check whether spread pop up is shown on adding new strategy can be implemented by user

Returns
default return value is false

◆ spreadCalculationMethod()

virtual void APIWrapper::spreadCalculationMethod ( int  row,
QList< BaseSymbolIds > &  symbolIdsList 
)
inlinevirtual

spreadCalculationMethod To calculate spread of passed row of the symbol id list can be implemented by user

Parameters
row
symbolIdsList

◆ terminateValidation()

virtual bool APIWrapper::terminateValidation ( int  row,
QString &  error 
)
inlinevirtual

terminateValidation To check whether the validation is terminated and give the error in the passed reference can be implemented by user

Parameters
row
error
Returns
By default it returns true

◆ updateAccountDetail()

virtual void APIWrapper::updateAccountDetail ( const int  row)
inlinevirtual

updateAccountDetail To update the account deatils of the passed row in the database can be implemented by user

Parameters
row

◆ updateAdditionalValuesInPortfolio()

virtual void APIWrapper::updateAdditionalValuesInPortfolio ( QStringList &  dataList)
inlinevirtual

updateAdditionalValuesInPortfolio To update the additional values in the portfolio from the datalist can be implemented by user

Parameters
dataList

◆ updateCustomValuesInUiOnModify()

virtual void APIWrapper::updateCustomValuesInUiOnModify ( int  row)
inlinevirtual

updateCustomValuesInUiOnModify To update the custom values of strategy in ui when strategy is already running can be implemented by user

Parameters
row

◆ updateDisableColumnsColor()

virtual void APIWrapper::updateDisableColumnsColor ( int  row)
inlinevirtual

updateDisableColumnsColor To update the disable columns colour of the selected row as the passed color can be implemented by user

Parameters
row

◆ updateEditableFieldColor()

virtual void APIWrapper::updateEditableFieldColor ( int  row,
QColor  color 
)
inlinevirtual

updateEditableFieldColor To update the colour of the editable fields of the passed row as the color passed can be implemented by user

Parameters
row
color

◆ updateFieldsOnLoadOld()

virtual void APIWrapper::updateFieldsOnLoadOld ( int  row)
inlinevirtual

updateFieldsOnLoadOld To update the fields on loading the old data from row can be implemented by user

Parameters
row

◆ updateNonPortfolioDbParams()

virtual void APIWrapper::updateNonPortfolioDbParams ( QMap< QString, QString > &  nonPortfolioDbParams,
QStringList &  dataList 
)
inlinevirtual

updateNonPortfolioDbParams To update database parameters that are not in portfolio can be implemented by user

Parameters
nonPortfolioDbParams
dataList

◆ updateOldStrategyId()

virtual void APIWrapper::updateOldStrategyId ( qlonglong  strategyId,
qlonglong  adminTokenId 
)
inlinevirtual

updateOldStrategyId To update the old strategy id with passed admin token id can be implemented by user

Parameters
strategyId
adminTokenId

◆ updateRemainingFeilds()

virtual void APIWrapper::updateRemainingFeilds ( int  row,
QSqlRecord &  adminTokenIdData 
)
inlinevirtual

updateRemainingFeilds To update the remaining fields in the strategy table using the passed admimn token id in the passed row can be implemented by user

Parameters
row
adminTokenIdData

◆ updateRemainingQty()

virtual bool APIWrapper::updateRemainingQty ( int  row)
inlinevirtual

updateRemainingQty To update the remaining quantity in the passed row can be implemented by user

Parameters
row
Returns
default return value is false

◆ updateSidQty()

virtual void APIWrapper::updateSidQty ( qlonglong  row)
inlinevirtual

updateSidQty To update the total strategy quantity in the passed row can be implemented by user

Parameters
row

◆ updateStrategyDefaultValues()

virtual bool APIWrapper::updateStrategyDefaultValues ( qlonglong  adminTokenIdNew)
inlinevirtual

updateStrategyDefaultValues To check the updation of the strategy default values using the passed admin token id

Parameters
adminTokenIdNew
Returns
default return value is false

◆ updateSymbolIdsDetail()

virtual void APIWrapper::updateSymbolIdsDetail ( int  row,
bool  isUpdateAll = false 
)
inlinevirtual

updateSymbolIdsDetail To update the symbol id details in the strategy table can be implemented by user

Parameters
row
isUpdateAll

◆ updateTrades()

virtual void APIWrapper::updateTrades ( const RSP::OrderConfirmation orderConfirmation)
inlinevirtual

updateTrades To update the trades from order confirmation object can be implemented by user

Parameters
orderConfirmation

◆ validateData()

virtual bool APIWrapper::validateData ( API2::PORTFOLIO_STATE  state)
inlinevirtual

validateData To validate the data entered in the strategy parameters before saving it in the strategy table can be implemented by user

Parameters
state
Returns
default return value is false

◆ validatePortFolioData()

virtual bool APIWrapper::validatePortFolioData ( QStringList &  dataList,
QString &  errorText,
int  portfolioCount 
)
inlinevirtual

validatePortFolioData To validate the portfolio data from the passed reference datalist and return error if any in errortext reference can be implemented by user

Parameters
dataList
errorText
portfolioCount
Returns
By default it returns true

◆ validatePortFolioDataOnLoadOld()

virtual bool APIWrapper::validatePortFolioDataOnLoadOld ( qlonglong  adminTokenId)
inlinevirtual

validatePortFolioDataOnLoadOld To validate portfolio data while loading the old data can be implemented by user

Parameters
adminTokenId
Returns
By default it returns true

The documentation for this class was generated from the following file: