Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
The first items to explore when scripting the file system are the different classes of objects Finder and System Events use to represent files, folders and disks. There are quite a few differences between the Finder's and System Events' object models, so this section will focus on the Finder and the next section will cover System Events.
The top of the food chain in the Finder's inheritance structure is a class called item. The item class describes the basic features found in every class of file system object you'll meet in Finder scripting: disk, folder, application file, document file, and so on.