RequestValue (UserStatistics function): Difference between revisions

From m204wiki
Jump to navigation Jump to search
mNo edit summary
 
(9 intermediate revisions by 5 users not shown)
Line 1: Line 1:
<span style="font-size:120%; color:black"><b>Value of specified Request statistic</b></span>
{{Template:UserStatistics:RequestValue subtitle}}
[[Category:UserStatistics methods|RequestValue function]]
<var>RequestValue</var> returns the value of a [[UserStatistics class#request|Request]] statistic.
<!--DPL?? Category:UserStatistics methods|RequestValue function: Value of specified Request statistic-->
<!--DPL?? Category:System methods|RequestValue (UserStatistics function): Value of specified Request statistic-->
<p>
RequestValue is a member of the [[UserStatistics class]].
</p>


This function returns the value of a [[UserStatistics class#request|Request statistic]].
==Syntax==
{{Template:UserStatistics:RequestValue syntax}}


The method cancels the request if it is applied to a statistic
that is exclusively a [[UserStatistics class#login|Login]]
(also called Final) statistic.
===Syntax===
  %val = %ustat:RequestValue(statistic)
===Syntax terms===
===Syntax terms===
<dl>
<table class="syntaxTable">
<dt><i>%val</i>
<tr><th>%number</th>
<dd>A numeric variable to contain the value of the specified statistic
<td>A numeric variable to contain the value of the specified statistic that is contained in the method object. </td></tr>
that is contained in the method object.
 
<dt><i>%ustat</i>
<tr><th>userStatistics</th>
<dd>A UserStatistics object variable.
<td>A <var>UserStatistics</var> object variable. </td></tr>
<dt><i>statistic</i>
 
<dd>This case-independent string contains the name of a ''Model 204'' user statistic.
<tr><th>string</th>
Only the names of ''Model 204'' Request statistics are valid.
<td>This case-independent string contains the name of a <var class="product">Model 204</var> user statistic. Only the names of <var class="product">Model 204</var> Request statistics are valid. All other names return an <var>[[UnknownStatistic_class|UnknownStatistic]]</var> exception.</td></tr>
All other names return an UnknownStatistic exception.
</table>


</dl>
==Usage notes==
===Usage Notes===
<ul>
<ul>
<li>The [[Value (UserStatistics function)|Value]] function returns the value of a
<li><var>RequestValue</var> cancels the request if it is applied to a statistic that is exclusively a [[UserStatistics class#login|Login]] (also called "Final") statistic.
''Model 204'' user Login statistic.
</ul>
</ul>
===Examples===


The following statements respectively assign
==Examples==
and print a Request statistic value:
The following statements print a Request statistic value:
<pre>
<p class="code">%stat is object userStatistics auto new
    %num = %stat:requestValue('dkpr')
print 'PDL highwater mark: ' %stat:requestValue('pdl')
</p>


    printText PDL highwater mark: {%stat:requestValue('PDL')}
==See also==
</pre>
<ul>
<li><var>[[Value (UserStatistics function)|Value]]</var> returns the value of a <var class="product">Model 204</var> user Login statistic.
</ul>
{{Template:UserStatistics:RequestValue footer}}

Latest revision as of 23:30, 8 April 2014

Value of the specified Request statistic (UserStatistics class)

RequestValue returns the value of a Request statistic.

Syntax

%number = userStatistics:RequestValue( string) Throws UnknownStatistic

Syntax terms

%number A numeric variable to contain the value of the specified statistic that is contained in the method object.
userStatistics A UserStatistics object variable.
string This case-independent string contains the name of a Model 204 user statistic. Only the names of Model 204 Request statistics are valid. All other names return an UnknownStatistic exception.

Usage notes

  • RequestValue cancels the request if it is applied to a statistic that is exclusively a Login (also called "Final") statistic.

Examples

The following statements print a Request statistic value:

%stat is object userStatistics auto new print 'PDL highwater mark: ' %stat:requestValue('pdl')

See also

  • Value returns the value of a Model 204 user Login statistic.