$SirVer: Difference between revisions

From m204wiki
Jump to navigation Jump to search
(Automatically generated page update)
m (misc cleanup)
 
Line 2: Line 2:
<span class="pageSubtitle">Current version number of Sirius product</span>
<span class="pageSubtitle">Current version number of Sirius product</span>


<p class="warn"><b>Note: </b>Most Sirius $functions have been deprecated in favor of Object Oriented methods. There is no OO equivalent for the $SirVer function, but you can get the same information from the <var>[[SIRIUS command|SIRIUS]]</var> command.</p>
<p class="warn"><b>Note: </b>Many $functions have been deprecated in favor of Object Oriented methods. There is no OO equivalent for the $SirVer function, but you can get the same information from the <var>[[SIRIUS command|SIRIUS]]</var> command.</p>


This function returns the current version number of a particular [[Sirius Software|Sirius]] product.  
This function returns the current version number of a particular [[Sirius Software|Sirius]] product.  


The <var>$SirVer</var> function accepts one argument and returns a numeric result that is the current version number of the requested product.
==Syntax==
<p class="syntax"><span class="term">%ver</span> = <span class="literal">$SirVer</span>([<span class="term">product</span>])
</p>


The argument is a string corresponding to one of the following products:
===Syntax terms===
<table>
<tr><th>%ver</th>
<td>A numeric variable that is set to the current version number of the requested product.</td></tr>


<tr><th>product</th>
<td>A string corresponding to one of the following products:
<ul>
<ul>
<li>SIRMODS: <var class="product">[[Sirius Mods]]</var>  
<li>SIRMODS: <var class="product">[[Sirius Mods]]</var>  
<li>FUNLOAD: <var class="product">[[Fast/Unload]]</var> (accessed via the <i>[[Fast/Unload User Language Interface]]</i>)
</ul>
==Syntax==
<p class="syntax"><span class="term">%ver</span> = <span class="literal">$SirVer</span>([<span class="term">product</span>])
</p>


<p>
<li>FUNLOAD: <var class="product">[[Fast/Unload]]</var> (accessed via the [[Fast/Unload SOUL Interface]])
<var class="term">%ver</var> is set to the current product version number.</p>
</ul></td></tr>
</table>


==Usage notes==
==Usage notes==
<ul>
<ul>
<li>This function can be used to ensure that you are running the correct version of the <var class="product">Sirius Mods</var> or of <i>[[Fast/Unload]]</i>. For example, the program
<li>This function can be used to ensure that you are running the correct version of the <var class="product">Sirius Mods</var> or of <var class="product">Fast/Unload</var>. For example, the following program
 
would stop if the <var class="product">Sirius Mods</var> were older than release 6.03:
<p class="code">IF $SirVer < 603 THEN
<p class="code">IF $SirVer < 603 THEN
PRINT 'OBSOLETE SIRIUS FUNCTIONS'
PRINT 'OBSOLETE SIRIUS FUNCTIONS'
STOP
STOP
END IF
END IF
</p>
</p></li>
 
would stop if the <var class="product">Sirius Mods</var> were older than release 6.03.


<li>The default product is SIRMODS, that is, if the argument is missing or is the null string, the version number of the <var class="product">Sirius Mods</var> is returned. If the argument is invalid, 0 is returned. If the argument is FUNLOAD, and the <i>[[Fast/Unload User Language Interface]]</i> is not available, 0 is returned.
<li>The default product value is <var>SIRMODS</var>; that is, if the argument is missing or is the null string, the version number of the <var class="product">Sirius Mods</var> is returned. If the argument is invalid, 0 is returned. If the argument is <var>FUNLOAD</var>, and the <var class="product">Fast/Unload SOUL Interface</var> is not available, 0 is returned. </li>
</ul>
</ul>



Latest revision as of 23:50, 6 October 2015

Current version number of Sirius product

Note: Many $functions have been deprecated in favor of Object Oriented methods. There is no OO equivalent for the $SirVer function, but you can get the same information from the SIRIUS command.

This function returns the current version number of a particular Sirius product.

Syntax

%ver = $SirVer([product])

Syntax terms

%ver A numeric variable that is set to the current version number of the requested product.
product A string corresponding to one of the following products:

Usage notes

  • This function can be used to ensure that you are running the correct version of the Sirius Mods or of Fast/Unload. For example, the following program would stop if the Sirius Mods were older than release 6.03:

    IF $SirVer < 603 THEN PRINT 'OBSOLETE SIRIUS FUNCTIONS' STOP END IF

  • The default product value is SIRMODS; that is, if the argument is missing or is the null string, the version number of the Sirius Mods is returned. If the argument is invalid, 0 is returned. If the argument is FUNLOAD, and the Fast/Unload SOUL Interface is not available, 0 is returned.

Products authorizing $SirVer