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


Appendix C - Organization of MacApp's
Source Code


The source code in the MacApp class library is written almost entirely in C++. Related classes and support code are grouped by function and stored in standard C++ header files (such as UAppleEvents.h) and implementation files (such as UAppleEvents.cp). Largely for historical reasons, these header and implementation pairs are referred to as units, and many start with the letter U. (For more information on MacApp filenaming conventions, see "The Magic Five Files," beginning on page 675.)

A unit typically contains one or more related classes that perform the central function of the unit, along with support classes such as iterator classes and command classes.

This appendix lists MacApp's units and provides a brief description of the function provided by each unit. Units are grouped by their organization in the MacApp class library.
Unit nameDescription
Core units 
UMemory, BestFitHeap, MemoryHeap, ObjectHeap, PlatformMemoryManaging efficient, platform-independent, pointer-based memory allocation
CWDebugProviding framework-level support for Metrowerks' CodeWarrior MW Debug debugger
MacAppTypesDefining simple type declarations
NubInspectorHooksProviding NubDispatch traps for inspector support
PascalStringDefining Pascal string-compatible string classes
ToolboxSupplying CRGBColor definitions and assorted Toolbox convenience routines
UAssociationManaging lists of key-value entries
UClassDesc, UClassDescIteratorProviding runtime type information for application objects
UDebug, UDebugViewProviding MacApp debugger functions and interface
UDependenciesPropagating change notification
UDynamicArrayProviding efficient storage and operations on dynamic arrays
UFailureHandling exception conditions
UGeometry, GeometryHandling geometry class definitions for points, rectangles, and so on
UIteratorProviding iteration over arrays or lists of items
UList, UListIteratorBuilding lists on top of dynamic array structure; operating on sorted lists
UniversalStartupProviding safe, processor-independent code for starting up an application
UObjectServing as superclass and providing functions needed by most classes
UPatchProviding a processor-independent mechanism for patching ROM traps
UPointerObjectProviding operations on pointer-based objects
USegmentsProviding safe, efficient segment operations (68K applications only)
UStreamManaging data streams
UTheDebuggerProviding framework-level support for Jasik's The Debugger
MPW tools 
UCPlusTool

Supplying a framework for building MPW tools
Framework 
UAdornersDrawing frames and other view adornments
UAppleEventsDescribing, manipulating, and sending Apple events
UBehaviorModifying the behavior of event-handler objects
UBusyCursorChanging the cursor image while the application is busy
UClipboardMgrManaging Clipboard operations
UCommandPerforming command operations that can be done, undone, and redone
UCommandHandlerManaging applicationwide command operations that support undo
UControlProviding abstract control operations
UDesignatorDesignating sections of a document, including selections
UDeskScrapViewSupporting a default Clipboard
UDialogBehaviorProviding dialog-box behavior
UDocumentManaging document objects
UDragDrop, UDragDropBehaviorProviding support for drag-and-drop operations
UDrawingEnvironmentSetting and storing characteristics of a graphics environment
UErrorMgrHandling error messages
UEventDescribing and manipulating basic operating system events
UEventHandlerResponding to dispatched events
UFileHandling file operations
UFloatWindow, FloatWindowSupporting floating windows
UMacAppGlobalsProviding miscellaneous global declarations
UMacAppUtilitiesProviding miscellaneous global routines
UMenuMgrSupporting programmatic menu creation and modification
UOSAScriptRepresenting and manipulating scripts
UPrintHandlerSupporting simple printing
UPrintingRepresenting and manipulating printer objects; handling customizable printing
UScriptableObjectMixing in with event-handler objects to support Apple events
UScriptingSupporting the Apple event object model
UScrollerManaging scroller objects
UViewDisplaying and manipulating data in nested views
UViewServerManaging window and view creation
UWindowSupporting basic Macintosh window operations
Documents 
UEditionDocumentProviding Edition Manager support for documents that implement publish and subscribe
UFileBasedDocumentHandling disk-based document operations
UFileHandlerMediating between files and documents
USection,
USectionMgr
Representing and managing section events
UTEDocumentAdding text-editing capability to document objects (from DemoText sample application)
Views 
UDialogProviding views and commands used with dialog boxes
UGrabberTrackerSupporting scrolling with grabber-hand cursor
UGridViewDisplaying arrays of information
UKeySelectionBehaviorProviding alphabetic type-ahead in text list views
UMenuViewSupporting custom menu creation
UPopupManaging pop-up menus
USynchScrollerSynchronizing multiple scrollers
UTabBehaviorsProviding tabbing support between text entry views
UTearOffMenuViewSupplying tear-off menu operations
UTECommandsSupporting text-editing commands
UTEViewSupporting text-editing views
Application 
UApplicationHandling application-level tasks
UVUAssistProviding a hook for Virtual User assistance (to automate testing and other operations)
Mail 
UMailableMixing in with document classes to provide electronic-mail functions
UMailableDocumentWorking with MMailable to turn a document into electronic mail
UMailerRepresenting a PowerTalk mailer attached to a document
UMailerViewMediating between a MacApp mailer view and an AOCE view
UMailingApplicationProviding applicationwide Standard Mail Package support


Previous Book Contents Book Index Next

© Apple Computer, Inc.
25 JUL 1996