The resource loading... loading...

关于exchange.Go的疑惑

Author: Adchun, Created: 2018-06-25 15:40:05, Updated:

var a = exchange.Go ((GetTicker button); //GetTicker Asynchronous multi-threaded execution var b = exchange.Go ((GetDepth); Var c = exchange.Go ((Buy, 1000, 0.1)); var d = exchange.Go (( GetRecords button, PERIOD_H1)); // The above four operations are performed asynchronously on multiple threads simultaneously, without taking up time, and return immediately var ticker = a.wait ((); // call the wait method to wait to return asynchronous ticker results var depth = b.wait ((); // Returns depth, which is also possible to return null if retrieval fails var orderId = c.wait ((1000); // Returns order number, limited to 1 second overtime, overtime returns undefined, this parameter can continue to call wait wait if the last wait was overtime

My understanding: the first four lines in the example are immediate returns, but the last three lines of wait are still sequential execution, which is equivalent to no clicking and clicking, is there a callback function?


More

Inventors quantify - small dreamsThis is a picture of me. This is a list of all the different ways Dn-filebox.qbox.me/7a22ad78f2e117551879bbfba3c6be9009d103bb.png is credited in the database. This is a list of all the different ways Dn-filebox.qbox.me/f457ff165b82e54941ffa020c77a6b12563e779d is credited in the database.