$ProcCls: Difference between revisions
m (1 revision) |
mNo edit summary |
||
Line 2: | Line 2: | ||
<span class="pageSubtitle"><section begin="desc" />Close procedure before reaching end<section end="desc" /></span> | <span class="pageSubtitle"><section begin="desc" />Close procedure before reaching end<section end="desc" /></span> | ||
<p class="warning">Most Sirius $functions have been deprecated in favor of Object Oriented methods. | <p class="warning">Most Sirius $functions have been deprecated in favor of Object Oriented methods. There is currently no OO equivalent for the $ProcCls function.</p> | ||
The $ProcCls function may be used to "close" a procedure before reaching its end. | The $ProcCls function may be used to "close" a procedure before reaching its end. | ||
The $ProcCls function accepts no arguments and returns a numeric result. As of ''[[Sirius Mods]]'' Version 6.8, it is a callable $function . | The $ProcCls function accepts no arguments and returns a numeric result. As of ''[[Sirius Mods]]'' Version 6.8, it is a callable $function. | ||
==Syntax== | ==Syntax== | ||
<p class="syntax"><section begin="syntax" /> %RESULT = $ProcCls | <p class="syntax"><section begin="syntax" /> %RESULT = $ProcCls | ||
Line 13: | Line 14: | ||
</p> | </p> | ||
<p class="caption">%RESULT is set to indicate the results of the function.</p> | <p class="caption">%RESULT is set to indicate the results of the function.</p> | ||
If $ProcCls is called before the current procedure has been completely processed, the current procedure is closed and the next [[$ProcGet]], [[$ProcDat]], or [[$ProcLoc]] call operates on the previous procedure, if any. $ProcCls will not close an input stream that was not open via [[$ProcOpn]]. | |||
The following instructions close all procedure input streams opened by $ProcOpn. | The following instructions close all procedure input streams opened by $ProcOpn. | ||
Line 21: | Line 22: | ||
END REPEAT | END REPEAT | ||
</p> | </p> | ||
<p class="code"> | <p class="code"> | ||
-1 - Current include level not opened by $ProcOpn | -1 - Current include level not opened by $ProcOpn | ||
0 - Include level closed, no more $ProcOpn levels left | |||
N - Include level close, N $ProcOpn levels left | |||
</p> | </p> | ||
<p class="caption">$ProcCls Result Codes | <p class="caption">$ProcCls Result Codes | ||
Line 30: | Line 32: | ||
<p class="code"> | <p class="code"> | ||
<ul> | <ul class="smallAndTightList"> | ||
<li>[[Sirius $Functions]] | |||
<li> | <li>[[Fast/Unload User Language Interface]] | ||
<li>[[Janus Web Server]] | |||
<li> | |||
<li> | |||
</ul> | </ul> | ||
</p> | |||
</p> | |||
<p class="caption">Products authorizing $ProcCls | <p class="caption">Products authorizing $ProcCls | ||
</p> | </p> | ||
[[Category:$Functions|$ProcCls]] | [[Category:$Functions|$ProcCls]] |
Revision as of 22:05, 1 February 2011
<section begin="desc" />Close procedure before reaching end<section end="desc" />
Most Sirius $functions have been deprecated in favor of Object Oriented methods. There is currently no OO equivalent for the $ProcCls function.
The $ProcCls function may be used to "close" a procedure before reaching its end.
The $ProcCls function accepts no arguments and returns a numeric result. As of Sirius Mods Version 6.8, it is a callable $function.
Syntax
<section begin="syntax" /> %RESULT = $ProcCls <section end="syntax" />
If $ProcCls is called before the current procedure has been completely processed, the current procedure is closed and the next $ProcGet, $ProcDat, or $ProcLoc call operates on the previous procedure, if any. $ProcCls will not close an input stream that was not open via $ProcOpn.
The following instructions close all procedure input streams opened by $ProcOpn.
REPEAT UNTIL %RESULT <= 0 %RESULT = $ProcCls END REPEAT
-1 - Current include level not opened by $ProcOpn 0 - Include level closed, no more $ProcOpn levels left N - Include level close, N $ProcOpn levels left