Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Programmer's Guide to MacApp / Part 2 - Working With MacApp


Chapter 10 -
Working With Objects

This chapter provides recipes and sample code for performing basic operations with objects. The recipes demonstrate how to

Before reading this chapter, you should read Chapter 2, "Basic Operations," which describes MacApp's basic object class, TObject, and MacApp's runtime type information (RTTI) mechanism.


Chapter Contents
Overview
Choosing an Object Class
Creating Objects
Providing Runtime Type Information for a Class
Recipes--Objects
Recipe--Defining a Class
Provide a Class Definition
Provide Runtime Type Information in the Implementation
Provide Constructor and Destructor Methods
Provide an Initialization Method
Override Additional Methods
Recipe--Creating, Initializing, and Deleting an Object
Create and Initialize an Instance of a Class
Delete the Object When It Is No Longer Needed
Recipe--Dynamic Casting Between Class Types
Recipe--Determining Whether an Object Descends From a Specified Class

Previous Book Contents Book Index Next

© Apple Computer, Inc.
25 JUL 1996