UserStatistics methods syntax: Difference between revisions
m (Automatically generated page update) |
m (Automatically generated page update) |
||
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">% | <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: none; margin-top:0px;"><span class="term">% | <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">%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"> | <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">%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"> | <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> | ||
<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">:[[DifferenceToXmlDoc (UserStatistics function)|DifferenceToXmlDoc]]</span><span class="literal">(</span> <span class="term" title="UserStatistics"> | <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">:[[DifferenceToXmlDoc (UserStatistics function)|DifferenceToXmlDoc]]</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">AttributeValues=</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">AttributeValues=</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">AttributeNames=</span> <span class="term" title="Boolean">boolean</span><span class="squareb">]</span><span class="comma">,</span> - | ||
Line 15: | Line 14: | ||
<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="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">%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"> | <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">:[[RatePerSecond (UserStatistics function)|RatePerSecond]]</span><span class="literal">(</span> <span class="term" title="UserStatistics"> | <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> | ||
<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> |
Revision as of 21:38, 14 March 2011
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.
%newUserStats = userStatistics:Copy
%newUserStats = userStatistics:DeepCopy
%number = userStatistics:Difference( ustatOld, string)
%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)
%number = userStatistics:RatePerSecond( ustatOld, string)
%string = userStatistics:RequestToString[( [Zeros= boolean], - [NamesToLower= boolean])]
%number = userStatistics:RequestValue( string)
%string = userStatistics:ToString[( [Zeros= boolean], [NamesToLower= boolean])]
%doc = userStatistics:ToXmlDoc[( [Zeros= boolean], - [AttributeValues= boolean], - [AttributeNames= boolean], - [NamesToLower= boolean])]
%number = userStatistics:Value( string)