DekGenius.com
[ Team LiB ] Previous Section Next Section

10.1 Class

Every value is of some fixed type. I often refer to this as its datatype, but the AppleScript term for a value's type is its class. You can assign a value of any class to any variable, but at any given moment a variable has only one value and that value has only one class (so it is customary to speak of a variable's class, meaning the class of the value it has at that moment).

You can inquire of any value what its class is, by asking for its class. For example:

class of 7 -- integer
class of "howdy" -- string
class of {"Mannie"} -- list
class of class of 1975 -- class

As the last line shows, even something's class is a value and therefore has to have a class, namely class.

    [ Team LiB ] Previous Section Next Section