ThreadBase.id

Gets the OS identifier for this thread.

class ThreadBase
final @property @safe @nogc
id
()

Return Value

Type: ThreadID

If the thread hasn't been started yet, returns ThreadID$(D.init). Otherwise, returns the result of GetCurrentThreadId on Windows, and pthread_self on POSIX.

The value is unique for the current process.

Meta