SetTime (PersistentObjectInfo function): Difference between revisions
m (→Syntax terms) |
m (→Syntax terms) |
||
(3 intermediate revisions by the same user not shown) | |||
Line 6: | Line 6: | ||
<table class="syntaxTable"> | <table class="syntaxTable"> | ||
<tr><th>%string</th><td> A string variable to contain the time the object was set.</td></tr> | <tr><th>%string</th><td> A string variable to contain the time the object was set.</td></tr> | ||
<tr><th> | <tr><th>persObjInfo</th> | ||
<td>A <var>PersistentObjectInfo</var> object variable.</td></tr> | <td>A <var>PersistentObjectInfo</var> object variable.</td></tr> | ||
</table> | </table> | ||
Line 16: | Line 16: | ||
instance, and then request <code>B</code> sets it to a new value, <var>SetTime</var> still indicates | instance, and then request <code>B</code> sets it to a new value, <var>SetTime</var> still indicates | ||
the time the object reference was set in request <code>A</code>. | the time the object reference was set in request <code>A</code>. | ||
==Examples== | |||
A somewhat trivial example follows: | |||
<p class="code">b | |||
%i is float | |||
%persInfo is object persistentObjectInfo | |||
%sl is object stringlist | |||
%sl = list('alpha', 'beta', 'ceta') | |||
%(Object):SetGlobal('ABC', %sl) | |||
%persInfo = newFromGlobal('ABC') | |||
printText {~} = {%persInfo:name}, {~} = {%persInfo:setTime} | |||
end | |||
</p> | |||
The result is: | |||
<p class="output">%persInfo:name = ABC, %persInfo:setTime = 20110819105715221 | |||
</p> | |||
==See also== | ==See also== | ||
{{Template:PersistentObjectInfo:SetTime footer}} | {{Template:PersistentObjectInfo:SetTime footer}} |
Latest revision as of 19:43, 19 August 2011
Time object was set (YYYYMMDDHHMISSXXX format) (PersistentObjectInfo class)
[Introduced in Sirius Mods 7.8]
Syntax
%string = persObjInfo:SetTime
Syntax terms
%string | A string variable to contain the time the object was set. |
---|---|
persObjInfo | A PersistentObjectInfo object variable. |
Usage notes
SetTime is intended for debugging and problem diagnosis and not for application purposes.
For global and session variable declarations,
SetTime does not change if request A
sets a variable to an object
instance, and then request B
sets it to a new value, SetTime still indicates
the time the object reference was set in request A
.
Examples
A somewhat trivial example follows:
b %i is float %persInfo is object persistentObjectInfo %sl is object stringlist %sl = list('alpha', 'beta', 'ceta') %(Object):SetGlobal('ABC', %sl) %persInfo = newFromGlobal('ABC') printText {~} = {%persInfo:name}, {~} = {%persInfo:setTime} end
The result is:
%persInfo:name = ABC, %persInfo:setTime = 20110819105715221