Thread.name
Returns the name of the current multi-threaded object instance.
name()Examples
Create a concurrently running thread and output the name of that concurrent thread in the main thread.
javascript
function main() {
var t1 = threading.Thread(function() {
threading.currentThread().setData("data", 100)
})
Log(`t1.name():`, t1.name())
// Output: t1.name(): Thread-1
t1.join()
}Returns
| Type | Description |
string | Name of the concurrent thread. |
See Also