From 018af964aaae9393c32a9631687e11c084a88a75 Mon Sep 17 00:00:00 2001 From: Mark Drew Date: Mon, 21 Oct 2024 12:37:07 +0100 Subject: [PATCH] #1521 adding IsInThread Lucee documentation --- data/en/isinthread.json | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 data/en/isinthread.json diff --git a/data/en/isinthread.json b/data/en/isinthread.json new file mode 100644 index 000000000..956545235 --- /dev/null +++ b/data/en/isinthread.json @@ -0,0 +1,23 @@ +{ + "name": "isinthread", + "type": "function", + "syntax": "isinthread()", + "returns": "boolean", + "description": "Determines whether the executing code is inside a cfthread or not.", + "params": [], + "engines": { + "lucee": { + "notes": "", + "minimum_version": "5.0.0.0", + "docs": "https://docs.lucee.org/reference/functions/isinthread.html" + } + }, + "examples": [ + { + "title": "isinthread Example", + "description": "Check if the code is running inside a cfthread.", + "code": "request.inthread = false;\nwriteOutput(isInThread());\nthread action=\"run\" name=\"inThread\" {\n request.inthread = isInThread();\n}\nsleep(1000);\nwriteOutput(request.inthread)", + "result": "falsetrue" + } + ] +} \ No newline at end of file