Chapter 13. Datatypes


A datatype is a classification of a value; every value is of one datatype or another. This is what AppleScript calls a class . For example, string is a datatype, integer is a datatype, and so forth. AppleScript provides a number of native datatypes; this chapter describes them.

Scriptable applications can extend the language through additional classes. For example, the Finder implements a folder class. But such additional classes are confined to the application that defines them; a value returned by a scriptable application must be either a reference to an object belonging to that application or one of AppleScript's native datatypes .

Script objects, handlers, and references are not dealt with in this chapter (see respectively Chapters 8, 9, and 12). The details of coercion, the conversion of certain values from one datatype to another, will be explained in Chapters 14 and 15.




AppleScript. The Definitive Guide
AppleScript: The Definitive Guide, 2nd Edition
ISBN: 0596102119
EAN: 2147483647
Year: 2006
Pages: 267
Authors: Matt Neuburg

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net