UserStatistics methods syntax: Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (Automatically generated page update)
(Automatically generated page update)
 
(3 intermediate revisions by 2 users not shown)
Line 2: Line 2:
     replaced, so any manual edits will be lost. You've been warned. -->
     replaced, so any manual edits will be lost. You've been warned. -->
{{Template:Syntax list header|class=UserStatistics}}
{{Template:Syntax list header|class=UserStatistics}}
<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">%newUserStats</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[Copy (UserStatistics function)|Copy]]</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">%outUserStatistics</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[Copy (UserStatistics function)|Copy]]</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">%newUserStats</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[DeepCopy (UserStatistics function)|DeepCopy]]</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">%outUserStatistics</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[DeepCopy (UserStatistics function)|DeepCopy]]</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">userStatistics</span><span class="literal">:[[Difference (UserStatistics function)|Difference]]</span><span class="literal">(</span> <span class="term" title="UserStatistics">ustatOld</span><span class="comma">,</span> <span class="term" title="String">string</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">%number</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[Difference (UserStatistics function)|Difference]]</span><span class="literal">(</span> <span class="term" title="UserStatistics">ustatOld</span><span class="comma">,</span> <span class="term" title="String">string</span><span class="literal">)</span>
 
Throws [[UnknownStatistic class|UnknownStatistic]]</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">%string</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[DifferenceToString (UserStatistics function)|DifferenceToString]]</span><span class="literal">(</span> <span class="term" title="UserStatistics">ustatOld</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</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">%string</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[DifferenceToString (UserStatistics function)|DifferenceToString]]</span><span class="literal">(</span> <span class="term" title="UserStatistics">ustatOld</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</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">NamesToLower=</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">NamesToLower=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="literal">)</span></p>
Line 13: Line 15:
<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">%string</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[LoginToString (UserStatistics function)|LoginToString]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</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">%string</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[LoginToString (UserStatistics function)|LoginToString]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</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">NamesToLower=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p>
                                         <span class="squareb">[</span><span class="literal" title="Boolean">NamesToLower=</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">%userStatistics</span><span class="literal"> =</span> <span class="literal">%(UserStatistics):[[New (UserStatistics constructor)|New]]</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="squareb">[</span><span class="literal">%(UserStatistics):</span><span class="squareb">]</span><span class="literal">[[New (UserStatistics constructor)|New]]</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">userStatistics</span><span class="literal">:[[Rate (UserStatistics function)|Rate]]</span><span class="literal">(</span> <span class="term" title="UserStatistics">ustatOld</span><span class="comma">,</span> <span class="term" title="String">string</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">%number</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[Rate (UserStatistics function)|Rate]]</span><span class="literal">(</span> <span class="term" title="UserStatistics">ustatOld</span><span class="comma">,</span> <span class="term" title="String">string</span><span class="literal">)</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">%number</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[RatePerSecond (UserStatistics function)|RatePerSecond]]</span><span class="literal">(</span> <span class="term" title="UserStatistics">ustatOld</span><span class="comma">,</span> <span class="term" title="String">string</span><span class="literal">)</span></p>
 
Throws [[UnknownStatistic class|UnknownStatistic]]</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">userStatistics</span><span class="literal">:[[RatePerSecond (UserStatistics function)|RatePerSecond]]</span><span class="literal">(</span> <span class="term" title="UserStatistics">ustatOld</span><span class="comma">,</span> <span class="term" title="String">string</span><span class="literal">)</span>
 
Throws [[UnknownStatistic class|UnknownStatistic]]</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">%string</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[RequestToString (UserStatistics function)|RequestToString]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</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">%string</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[RequestToString (UserStatistics function)|RequestToString]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</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">NamesToLower=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p>
                                           <span class="squareb">[</span><span class="literal" title="Boolean">NamesToLower=</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">%number</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[RequestValue (UserStatistics function)|RequestValue]]</span><span class="literal">(</span> <span class="term" title="String">string</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">%number</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[RequestValue (UserStatistics function)|RequestValue]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="literal">)</span>
 
Throws [[UnknownStatistic class|UnknownStatistic]]</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">%string</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[ToString (UserStatistics function)|ToString]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</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">NamesToLower=</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">%string</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[ToString (UserStatistics function)|ToString]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</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">NamesToLower=</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">%doc</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[ToXmlDoc (UserStatistics function)|ToXmlDoc]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</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">%doc</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[ToXmlDoc (UserStatistics function)|ToXmlDoc]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="literal" title="Boolean">Zeros=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="comma">,</span>                            -
Line 24: Line 32:
                                 <span class="squareb">[</span><span class="literal" title="Boolean">AttributeNames=</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">AttributeNames=</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">NamesToLower=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p>
                                 <span class="squareb">[</span><span class="literal" title="Boolean">NamesToLower=</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">%number</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[Value (UserStatistics function)|Value]]</span><span class="literal">(</span> <span class="term" title="String">string</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">%number</span><span class="literal"> =</span> <span class="term">userStatistics</span><span class="literal">:[[Value (UserStatistics function)|Value]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="literal">)</span>
 
Throws [[UnknownStatistic class|UnknownStatistic]]</p>

Latest revision as of 16:20, 23 December 2015

The syntax for each of the UserStatistics 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 UserStatistics methods.

%outUserStatistics = userStatistics:Copy

%outUserStatistics = userStatistics:DeepCopy

%number = userStatistics:Difference( ustatOld, string) Throws UnknownStatistic

%string = userStatistics:DifferenceToString( ustatOld, [Zeros= boolean], - [NamesToLower= boolean])

%doc = userStatistics:DifferenceToXmlDoc( ustatOld, [Zeros= boolean], - [AttributeValues= boolean], - [AttributeNames= boolean], - [NamesToLower= boolean])

%string = userStatistics:LoginToString[( [Zeros= boolean], - [NamesToLower= boolean])]

%userStatistics = [%(UserStatistics):]New

%number = userStatistics:Rate( ustatOld, string) Throws UnknownStatistic

%number = userStatistics:RatePerSecond( ustatOld, string) Throws UnknownStatistic

%string = userStatistics:RequestToString[( [Zeros= boolean], - [NamesToLower= boolean])]

%number = userStatistics:RequestValue( string) Throws UnknownStatistic

%string = userStatistics:ToString[( [Zeros= boolean], [NamesToLower= boolean])]

%doc = userStatistics:ToXmlDoc[( [Zeros= boolean], - [AttributeValues= boolean], - [AttributeNames= boolean], - [NamesToLower= boolean])]

%number = userStatistics:Value( string) Throws UnknownStatistic