Difference between revisions of "Thread:execute"

From GiderosMobile
m (Text replacement - "</source>" to "</syntaxhighlight>")
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
__NOTOC__
 
__NOTOC__
<languages />
+
'''Available since:''' 2018.10<br/>
'''<translate>Available since</translate>:''' 2018.10<br/>
+
'''Class:''' [[Thread]]<br/>
'''<translate>Class</translate>:''' [[Special:MyLanguage/Thread|Thread]]<br/>
 
  
=== <translate>Description</translate> ===
+
=== Description ===
<translate>Starts/executes our thread if the function has been set with setFunction and the thread is not currently running.
+
Starts/executes the thread if a function has been set with ''setFunction'' and the thread is not currently running.
</translate><br/>
+
<syntaxhighlight lang="lua">
<source lang="lua">local ok = thread:execute(vararg)</source>
+
local ok = thread:execute(vararg)
 +
</syntaxhighlight>
  
=== <translate>Parameters</translate> ===
+
=== Parameters ===
'''vararg: ''' ''(...)''  <translate>Arguments for our thread function to process.</translate><br/>
+
'''vararg''': (...) arguments for our thread function to process<br/>
=== <translate>Return values</translate> ===
+
 
'''ok: ''' ''(boolean)''  <translate>success or failure</translate><br/>
+
=== Return values ===
 +
'''ok''': (boolean) success or failure<br/>
  
 
{{Thread}}
 
{{Thread}}

Latest revision as of 14:33, 13 July 2023

Available since: 2018.10
Class: Thread

Description

Starts/executes the thread if a function has been set with setFunction and the thread is not currently running.

local ok = thread:execute(vararg)

Parameters

vararg: (...) arguments for our thread function to process

Return values

ok: (boolean) success or failure