Daemon methods syntax: Difference between revisions
m (Automatically generated page update) |
m (Automatically generated page update) |
||
(7 intermediate revisions by 3 users not shown) | |||
Line 3: | Line 3: | ||
{{Template:Syntax list header|class=Daemon}} | {{Template:Syntax list header|class=Daemon}} | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top:1px solid;"><span class="term">%boolean</span><span class="literal"> =</span> <span class="literal">%(Daemon):[[AmDaemon (Daemon property)|AmDaemon]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top:1px solid;"><span class="term">%boolean</span><span class="literal"> =</span> <span class="literal">%(Daemon):[[AmDaemon (Daemon property)|AmDaemon]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%boolean</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[AsynchronousFinished (Daemon property)|AsynchronousFinished]]</span></p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="squareb">[</span><span class="term">%sl</span><span class="literal"> =</span><span class="squareb">]</span> <span class="term">daemon</span><span class="literal">:[[Continue (Daemon function)|Continue]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Object">Input=</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Object">Output=</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Object">Info=</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span> | |||
Throws [[DaemonLost class|DaemonLost]], [[IncorrectDaemonState class|IncorrectDaemonState]]</p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">daemon</span><span class="literal">:[[ContinueAsynchronously (Daemon subroutine)|ContinueAsynchronously]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Object">Input=</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span> | |||
Throws [[DaemonLost class|DaemonLost]], [[IncorrectDaemonState class|IncorrectDaemonState]]</p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">daemon</span><span class="literal">:[[ContinueIndependently (Daemon subroutine)|ContinueIndependently]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Object">Input=</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span> | |||
Throws [[DaemonLost class|DaemonLost]], [[IncorrectDaemonState class|IncorrectDaemonState]]</p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="literal">%(Daemon):[[GetInputObject (Daemon subroutine)|GetInputObject]]</span><span class="literal">(</span> <span class="term" title="Object">object</span><span class="literal">)</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="literal">%(Daemon):[[GetInputObject (Daemon subroutine)|GetInputObject]]</span><span class="literal">(</span> <span class="term" title="Object">object</span><span class="literal">)</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%boolean</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[HaveDaemon (Daemon property)|HaveDaemon]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%boolean</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[HaveDaemon (Daemon property)|HaveDaemon]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[LastCommandErrorCount (Daemon property)|LastCommandErrorCount]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[LastCommandErrorCount (Daemon property)|LastCommandErrorCount]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="literal">%(Daemon):[[MasterNumber (Daemon property)|MasterNumber]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="literal">%(Daemon):[[MasterNumber (Daemon property)|MasterNumber]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%daemon</span><span class="literal"> =</span> <span class="literal">%(Daemon):[[New (Daemon constructor)|New]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">CopyGlobals=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Boolean">Transactional=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%daemon</span><span class="literal"> =</span> <span class="squareb">[</span><span class="literal">%(Daemon):</span><span class="squareb">]</span><span class="literal">[[New (Daemon constructor)|New]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">CopyGlobals=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Boolean">Transactional=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="comma">,</span> - | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">daemon</span><span class="literal">:[[Open (Daemon subroutine)|Open]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Boolean">Default=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="literal">)</span></p> | <span class="squareb">[</span><span class="literal" title="Boolean">OpenAll=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span> | ||
Throws [[MaxDaemExceeded class|MaxDaemExceeded]], [[NoFreeDaemons class|NoFreeDaemons]], [[DaemonLost class|DaemonLost]]</p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">daemon</span><span class="literal">:[[Open (Daemon subroutine)|Open]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Boolean">Default=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="literal">)</span> | |||
Throws [[DaemonLost class|DaemonLost]], [[IncorrectDaemonState class|IncorrectDaemonState]]</p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="literal">%(Daemon):[[ParentNumber (Daemon property)|ParentNumber]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="literal">%(Daemon):[[ParentNumber (Daemon property)|ParentNumber]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="literal">%(Daemon):[[ReturnInfoObject (Daemon subroutine)|ReturnInfoObject]]</span><span class="literal">(</span> <span class="term" title=" | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="literal">%(Daemon):[[ReturnInfoObject (Daemon subroutine)|ReturnInfoObject]]</span><span class="literal">(</span> <span class="term" title="Object">outputObj</span><span class="literal">)</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="literal">%(Daemon):[[ReturnObject (Daemon subroutine)|ReturnObject]]</span><span class="literal">(</span> <span class="term" title=" | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="literal">%(Daemon):[[ReturnObject (Daemon subroutine)|ReturnObject]]</span><span class="literal">(</span> <span class="term" title="Object">outputObj</span><span class="literal">)</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="squareb">[</span><span class="term">%sl</span><span class="literal"> =</span><span class="squareb">]</span> <span class="term">daemon</span><span class="literal">:[[Run (Daemon function)|Run]]</span><span class="literal">(</span> <span class="term" title="String">commands</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title=" | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="literal">%(Daemon):[[ReturnToMaster (Daemon subroutine)|ReturnToMaster]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">daemon</span><span class="literal">:[[RunAsynchronously (Daemon subroutine)|RunAsynchronously]]</span><span class="literal">(</span> <span class="term" title="String">commands</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title=" | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="squareb">[</span><span class="term">%sl</span><span class="literal"> =</span><span class="squareb">]</span> <span class="term">daemon</span><span class="literal">:[[Run (Daemon function)|Run]]</span><span class="literal">(</span> <span class="term" title="String">commands</span><span class="comma">,</span> <span class="squareb">[</span><span class="squareb">[</span><span class="literal" title="Object">Input=</span><span class="squareb">]</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="squareb">[</span><span class="literal" title="Object">Output=</span><span class="squareb">]</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="comma">,</span> - | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">daemon</span><span class="literal">:[[RunIndependently (Daemon subroutine)|RunIndependently]]</span><span class="literal">(</span> <span class="term" title="String">commands</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title=" | <span class="squareb">[</span><span class="literal" title="Object">Info=</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="literal">)</span> | ||
Throws [[DaemonLost class|DaemonLost]], [[IncorrectDaemonState class|IncorrectDaemonState]]</p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">daemon</span><span class="literal">:[[RunAsynchronously (Daemon subroutine)|RunAsynchronously]]</span><span class="literal">(</span> <span class="term" title="String">commands</span><span class="comma">,</span> <span class="squareb">[</span><span class="squareb">[</span><span class="literal" title="Object">Input=</span><span class="squareb">]</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="literal">)</span> | |||
Throws [[DaemonLost class|DaemonLost]], [[IncorrectDaemonState class|IncorrectDaemonState]]</p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">daemon</span><span class="literal">:[[RunIndependently (Daemon subroutine)|RunIndependently]]</span><span class="literal">(</span> <span class="term" title="String">commands</span><span class="comma">,</span> <span class="squareb">[</span><span class="squareb">[</span><span class="literal" title="Object">Input=</span><span class="squareb">]</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="literal">)</span> | |||
Throws [[DaemonLost class|DaemonLost]], [[IncorrectDaemonState class|IncorrectDaemonState]]</p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%daemonState</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[State (Daemon property)|State]]</span></p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[UserNumber (Daemon property)|UserNumber]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[UserNumber (Daemon property)|UserNumber]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%userStatistics</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[UserStatistics (Daemon function)|UserStatistics]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%userStatistics</span><span class="literal"> =</span> <span class="term">daemon</span><span class="literal">:[[UserStatistics (Daemon function)|UserStatistics]]</span> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="squareb">[</span><span class="term">%sl</span><span class="literal"> =</span><span class="squareb">]</span> <span class="term">daemon</span><span class="literal">:[[WaitAsynchronous (Daemon function)|WaitAsynchronous]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="Object">object</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Object">Info=</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | |||
Throws [[DaemonLost class|DaemonLost]]</p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="squareb">[</span><span class="term">%sl</span><span class="literal"> =</span><span class="squareb">]</span> <span class="term">daemon</span><span class="literal">:[[WaitAsynchronous (Daemon function)|WaitAsynchronous]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="squareb">[</span><span class="literal" title="Object">Output=</span><span class="squareb">]</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Object">Info=</span> <span class="term" title="Object">object</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span> | |||
Throws [[DaemonLost class|DaemonLost]], [[IncorrectDaemonState class|IncorrectDaemonState]]</p> |
Latest revision as of 20:57, 28 November 2012
The syntax for each of the Daemon class methods is shown below.
Square brackets indicate optional elements of the method invocation. See also the notation conventions for methods and the List of Daemon methods.
%boolean = %(Daemon):AmDaemon
%boolean = daemon:AsynchronousFinished
[%sl =] daemon:Continue[( [Input= object], [Output= object], [Info= object])] Throws DaemonLost, IncorrectDaemonState
daemon:ContinueAsynchronously[( [Input= object])] Throws DaemonLost, IncorrectDaemonState
daemon:ContinueIndependently[( [Input= object])] Throws DaemonLost, IncorrectDaemonState
%(Daemon):GetInputObject( object)
%boolean = daemon:HaveDaemon
%number = daemon:LastCommandErrorCount
%number = %(Daemon):MasterNumber
%daemon = [%(Daemon):]New[( [CopyGlobals= boolean], [Transactional= boolean], - [OpenAll= boolean])] Throws MaxDaemExceeded, NoFreeDaemons, DaemonLost
daemon:Open( string, [Default= boolean]) Throws DaemonLost, IncorrectDaemonState
%number = %(Daemon):ParentNumber
%(Daemon):ReturnInfoObject( outputObj)
%(Daemon):ReturnObject( outputObj)
%(Daemon):ReturnToMaster
[%sl =] daemon:Run( commands, [[Input=] object], [[Output=] object], - [Info= object]) Throws DaemonLost, IncorrectDaemonState
daemon:RunAsynchronously( commands, [[Input=] object]) Throws DaemonLost, IncorrectDaemonState
daemon:RunIndependently( commands, [[Input=] object]) Throws DaemonLost, IncorrectDaemonState
%daemonState = daemon:State
%number = daemon:UserNumber
%userStatistics = daemon:UserStatistics Throws DaemonLost
[%sl =] daemon:WaitAsynchronous[( [[Output=] object], [Info= object])] Throws DaemonLost, IncorrectDaemonState