LassoScript Utility
Basics Browse Detail

[Define_Type] ... [/Define_Type]

Tag Link [Define_Type] ... Category Custom Tag
Type Container Source Available No
Support Preferred Version 5.0
Change Unchanged Data Source Any
Output Type None Security None
Implementation Internal Sets Lasso 8.5, Lasso 8.0, Lasso 7.0, Lasso 6.0, Lasso 5.0

Description

[Define_Type] ... [/Define_Type] defines a new data type. The data type can have member tags defined by enclosed [Define_Tag] ... [/Define_Tag] tags and variables local to the data type defined by enclosed [Local] tags.

An optional -Namespace parameter specifies what namespace the newly defined type should be in. Additional parameters specify types that the new type should inherit from.

Syntax

[Define_Type: 'Type Name', 'Inherited Type']
  [Local: 'Member Variable'='Variable Value']
  [Define_Tag: 'Member Tag']
    ...
  [/Define_Tag]
[/Define_Type]

[Define_Type: 'Type Name', -Namespace='_Global_MyType_']
  [Local: 'Member Variable'='Variable Value']
  [Define_Tag: 'Member Tag']
    ...
  [/Define_Tag]
[/Define_Type]

Parameters

Required Parameters
Type Name The name of the type to be defined.
Optional Parameters
Inherited Types The optional names of a custom types from which this type should inherit attributes. If the type must inherit from multiple ancestors then each should be listed in order from the immediate parent, its parent, etc.
-Description An optional description for the type.
-Namespace The namespace for the new type.
-Prototype Specifies that the type should be defined as a prototype.

Examples

See the Lasso 8 Language Guide for examples of how to use this tag.