class
|
The class function returns the class name symbol of the specified Lambda or Structure. For instance below we define a class Lambda, create an object of the class, and then
use the class function to return the class name of the new object. Usage Use class on a defClass Lambda or a class Structure to determine the class name.
(defclass employee()
svars:(String:Name (Number:Salary 0.0))
cvars:(empStatic)
(defun new(self name salary)
(setq Name (string name))
(setq Salary salary)
self) ;; end of new method
;;.... other class methods here
true) ;; end of employee class
;; Finding the class name of an object created by a class Lambda
(setq emp (new employee "John Doe" 24000.0)) ;; Create an object of class employee
(setq className (class emp)) ;; className now = "employee"
;; Finding the class name of a class Lambda saved in a Vector
(setq vec (new Vector: 1 employee)) ;; Store the class Lambda in a Vector
(setq className (class vec[0])) ;; className now = "employee"
(class arg) The class name of the Lambda or Structure.
Expression:
Arguments
Name
Type
Description Argument: arg Structure or Lambda
A Structure or a Lambda
Returns:
Here are a number of links to Lambda coding examples which contain this instruction in various use cases.
Here are the links to the data types of the function arguments.
Lambda | Structure |
Here are also a number of links to functions having arguments with any of these data types.
Analytic Information Server (AIS)AIS Component Systems
|