Difference between revisions of "Template:Property"
From Kerbal Space Program Wiki
Line 2: | Line 2: | ||
| <tt>{{type|{{{type}}}}}{{{array|}}} {{{name}}} { {{#if:{{{hasget|}}}|<span style="color:blue;">get;</span> }}{{#if:{{{hasset|}}}|<span style="color:blue;">set;</span> }}}</tt> | | <tt>{{type|{{{type}}}}}{{{array|}}} {{{name}}} { {{#if:{{{hasget|}}}|<span style="color:blue;">get;</span> }}{{#if:{{{hasset|}}}|<span style="color:blue;">set;</span> }}}</tt> | ||
| {{{desc|<small>?</small>}}}</includeonly><noinclude> | | {{{desc|<small>?</small>}}}</includeonly><noinclude> | ||
+ | '''Template:Property''' is a single property as listed inside a [[Template:Properties]] template. | ||
+ | |||
Template for a single property with parameters type, name, hasget, hasset and desc. Used inside a [[Template:Properties]] template. | Template for a single property with parameters type, name, hasget, hasset and desc. Used inside a [[Template:Properties]] template. | ||
+ | |||
+ | ===Parameters=== | ||
+ | :'''name''' - Required. The name of this property. | ||
+ | :'''type''' - Required. Pass a [[Template:Type]]. | ||
+ | :'''hasget''' - Optional. Set to "true" if this property has a getter or blank otherwise. | ||
+ | :'''hasset''' - Optional. Set to "true" if this property has a setter or blank otherwise. | ||
+ | :'''access''' - Optional. Set to "public" or "protected". | ||
+ | :'''static''' - Optional. Set to "true" for static properties. | ||
+ | :'''summary''' - Optional. Set to description of this property. | ||
+ | |||
+ | ===Examples=== | ||
+ | {{Properties|properties= | ||
+ | {{Property | ||
+ | |name=SomeProperty | ||
+ | |type={{Type|type=Vessel}} | ||
+ | }} | ||
+ | }} | ||
[[Category:Templates]] | [[Category:Templates]] | ||
[[Category:API Templates]] | [[Category:API Templates]] | ||
</noinclude> | </noinclude> |
Revision as of 22:56, 16 October 2015
Template:Property is a single property as listed inside a Template:Properties template.
Template for a single property with parameters type, name, hasget, hasset and desc. Used inside a Template:Properties template.
Parameters
- name - Required. The name of this property.
- type - Required. Pass a Template:Type.
- hasget - Optional. Set to "true" if this property has a getter or blank otherwise.
- hasset - Optional. Set to "true" if this property has a setter or blank otherwise.
- access - Optional. Set to "public" or "protected".
- static - Optional. Set to "true" for static properties.
- summary - Optional. Set to description of this property.
Examples
Properties
The following is a list of properties in Property.
Name | Description |
---|---|
Vessel SomeProperty { } | ? |