Difference between revisions of "SHIP:Property:variable:varid"

From Serious Documentation
Jump to: navigation, search
(Created page with "=== Node: Variable === {{PropTableStart|}} |<onlyinclude>{{Prop|variable|varid}}**||{{DataType|Short}}|| Unique in-{{Prop|variable|context}} Variable ID for a {{...")
 
(Node: Variable)
Line 1: Line 1:
 
=== Node: [[SHIP:Node|Variable]] ===
 
=== Node: [[SHIP:Node|Variable]] ===
 
{{PropTableStart|}}
 
{{PropTableStart|}}
|<onlyinclude>{{Prop|variable|varid}}**||{{DataType|Short}}|| Unique in-{{Prop|variable|context}} Variable ID for a {{Prop|variable|persistent}} registry variable.</onlyinclude>
+
|<onlyinclude>{{Prop|variable|varid}}||{{DataType|Short}}|| Unique in-{{Prop|variable|context}} Variable ID for a {{Prop|variable|persistent}} registry variable.</onlyinclude>
 
|}
 
|}
 
Variables marked {{Prop|variable|persistent}} must be stored in the registry in a specific name space, or {{Prop|variable|context}}.  Within that context, each variable must be assigned a unique ID, or {{Prop|variable|varid}}.
 
Variables marked {{Prop|variable|persistent}} must be stored in the registry in a specific name space, or {{Prop|variable|context}}.  Within that context, each variable must be assigned a unique ID, or {{Prop|variable|varid}}.
Line 10: Line 10:
  
 
See the related properties {{Prop|variable|persistent}}, {{Prop|variable|context}}, and {{Prop|variable|varversion}}. In order to make a variable {{Prop|variable|persistent}}, you must set these 3 related properties as well.
 
See the related properties {{Prop|variable|persistent}}, {{Prop|variable|context}}, and {{Prop|variable|varversion}}. In order to make a variable {{Prop|variable|persistent}}, you must set these 3 related properties as well.
 
<nowiki>*</nowiki>The {{Prop|variable|persistent}} property can only be set in [[SHIPTide]].
 

Revision as of 10:11, 6 August 2013

Node: Variable

Property Data Type Description
varid Short Unique in-context Variable ID for a persistent registry variable.

Variables marked persistent must be stored in the registry in a specific name space, or context. Within that context, each variable must be assigned a unique ID, or varid.

A varid is a 16 bit number, with 0x0000 and 0xFFFF reserved for Serious use. Make sure all your variable IDs are unique.

Variables are stored by a combined unique value of context + varid + varversion. A persistent variable in one GUI with context 0x01, varid 0x0001, varversion 0x01 is a completely different stored variable than one with a different (say, 0x02) context.

See the related properties persistent, context, and varversion. In order to make a variable persistent, you must set these 3 related properties as well.