Sumber dimuat naik... memuat...

Thread semasa

PeraturancurrentThread()fungsi digunakan untuk mendapatkan objek benang benang semasa.

PeraturancurrentThread()fungsi mengembalikan objek benang benang semasa.

Threadobjek

CurrentThread ((()

function test() {
    Log("Id of the current thread:", threading.currentThread().id())
}

function main() {
    var t1 = threading.Thread(test)
    t1.join()
}

DapatkanThreadobjek benang semasa dan outputthreadIddaripada benang semasa.

Ia menyokong sistem backtesting dan persekitaran perdagangan langsung.

{@fun/Threads/threading/Thread Thread}, {@fun/Threads/threading/mainThread mainThread}, {@fun/Threads/threading/Thread Thread}, {@fun/Threads/threading/Lock Lock}, {@fun/Threads/threads/threading/Condition Condition}, {@fun/Threads/threads/threading/Event Event}, {@fun/Threads/threads/threading/Dict Dict}, {@fun/Threads/threading/threading/pending pending}, {@fun/Threads/threading/eventLoop eventLoop}

mainThread Kunci