getTime (SDK Trading)
getTime is a Fintechee API to get the sending time of the specific pending order.
number
getTime(pendingOrder) ⇒ EA SDK This function gets the time(UTC time stamp) of the specific pending order. Phase (this API's scope): onTick | deinit
Kind: global function
Returns: number
- time(UTC time stamp).
Param | Type | Description |
---|---|---|
pendingOrder | object | specific pending order |
getTime (SDK Trading)
registerEA(
"test_api",
"An EA to test APIs",
[],
function (context) { // Init()
},
function (context) { // Deinit()
},
function (context) { // OnTick()
var length = getPendingOrdersListLength(context)
for (var i = 0; i < length; i++) {
var pendingOrder = getPendingOrder(context, i)
if (pendingOrder != null) {
var time = getTime(pendingOrder)
}
}
})