|
| SDKAlgo () |
|
| ~SDKAlgo () |
|
virtual const char * | GetOrderId () const noexcept=0 |
| Returns the unique id of this algo.
|
|
virtual InstrumentPtr | GetInstrument () const noexcept=0 |
| Returns the instrument referenced by the algo. Might be null if the user did not send.
|
|
virtual AlgoDefinitionPtr | GetAlgoDefinition () const noexcept=0 |
| Returns the algo definition Id for the algo definition.
|
|
virtual ExecutionReportPtr | GetCurrentState () const noexcept=0 |
| Returns the current state of the algo.
|
|
virtual bool | GenerateSyntheticFill (const double fillPrc, const double fillQty) noexcept=0 |
| Generates and sends a fill message for the given qty and price. If the fill qty exceeds the currently.
|
|
virtual bool | GenerateUserResponse (const char *msg, const ttsdk::UserParameter params[], const size_t numParams) noexcept=0 |
| Generates and sends a restatement message to the user contains the given information. Note that.
|
|
virtual bool | FailAlgo (const char *message) noexcept=0 |
| Sets this algo as failed and send a message to user indicating failed status. This will not remove the order from the order book but will indicate to the end user the algo has stopped working and they need to cancel it.
|
|
virtual bool | StopAlgo (const char *message) noexcept=0 |
| Sets this algo as finished and send a message to user indicating finished status.
|
|
virtual void | OnPendingRequestCompleted (const AlgoResponseCode code, const char *message=nullptr) noexcept=0 |
| This needs to be called when a request from the user is completed. If the algo request action was successful, pass AlgoResponseCode::ok otherwise pass in a code that describes the reason for failure.
|
|
virtual void | ScheduledEvent (unsigned int eventId, void *eventUserData)=0 |
| Schedules an OnScheduleEvent callback to be triggered for this algo with the given id and user data.
|
|
virtual bool | ReserveRisk (InstrumentPtr instrument, const uint64_t accountId, const RiskSide side, const double quantity, const double maxClipSize) noexcept=0 |
| Reserves a quantity of risk for the given instrumentId/accountId/side to be used to by this algo to avoid the quantity checks in bouncer when an order is sent. Must be called before the algo places any orders on that instrument/account/side. If orders already exists for the instrument/account/side or there already is risk allocated for it, this method will return false. maxClipSize indicates the max lot size for orders sent. This value can not exceed any max order qty values defined in TT Setup.
|
|
virtual bool | ReleaseRisk (InstrumentPtr instrument, const uint64_t accountId, const RiskSide side) noexcept=0 |
| Releases the previously allocated quantity of risk for the given instrumentId/accountId/side.
|
|
virtual PositionReserveBucket | GetRiskBucket (InstrumentPtr instrument, const uint64_t accountId) noexcept=0 |
| Returns the current position reserve bucket for the instrument and account.
|
|
| shared_base () |
|
virtual | ~shared_base () |
|
int | dec_ref () const |
|
void | inc_ref () const |
|
virtual void | del_ref () const |
|
an interface to interact with the sdk managed algo.
Definition at line 114 of file sdkalgo.h.