IsInThread

Verifies if the calling execution code is running in a thread or not.

Method Signature

IsInThread()

Arguments

This function does not accept any arguments

Examples

isinthread Example

Check if the code is running inside a bx:thread.

Run Example

request.INTHREAD = false;
writeOutput( isInThread() );
bx:thread action="run" name="inThread" {
	request.INTHREAD = isInThread();
}
sleep( 1000 );
writeOutput( request.INTHREAD );

Result: falsetrue

Additional Examples

Last updated

Was this helpful?