|
defstruct
|
The defstruct macro creates and initializes a new object type
{newType} with the specified field names {fieldnames}. There
may be one or more field names. The new type created by defstruct
can inherit from another object by specifying the include: keyword and
the name of the parent object {parentName}.
The defstruct macro results in the following substitution: (defineStructure newType: include: parentName fieldnames....) When to use The defstruct macro and the defineStructure function do exactly the
same thing. The defstruct macro is a mechanism for adding user-defined types
to the Analytic Information Server workbench. The defstruct function brings the
conventional object-oriented paradigm to the Analytic Information Server workbench.
The defstruct describes a template for the new type object. The object is not
instantiated until the constructor function is invoked. The new type can inherit
field names (analogous to OOP properties or members) and methods by using the
include: syntax.
(defstruct newType: include: parentName fieldnames....) The name of the new object type (as a symbol).
Here are a number of links to Lambda coding examples which contain this instruction in various use cases.
Example_Structure_defstruct_001
Here are the links to the data types of the function arguments. Here are also a number of links to functions having arguments with any of these data types.
You can always talk with the AIS at aiserver.sourceforge.net.
Name
Description
AIS Types newType A symbolic name for the new object type String or Text include: An optional keyword. If present, it must be followed by an existing object type parentName If the include: keyword is present, it must be followed by an existing
object type name String or Text 'fieldnames One or more field names that is to be associated with the object type String or Text
Returns:
Examples
Argument Types
Structure
How do I contact the AIS team?