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: Cyberdog Programmer's Kit / Part 3 - Cyberdog Reference
Chapter 7 - Classes and Methods / CyberItem


Flatten

Flattens this Cyberdog item and writes it to a buffer.

long Flatten (in Ptr buffer, in long length);
buffer
A pointer to a data buffer. On return, the buffer contains the flattened CyberItem object.
length
The length of buffer.
return value
The number of bytes written to the buffer.
DISCUSSION
This method should convert this Cyberdog item to a flat representation and write it to a buffer. The format of a flattened Cyberdog item is described in Table 7-1 (page 227). The superclass implementation returns 0. This method is called by the StreamToStorageUnit method.

If you subclass CyberItem, you must override this method. Your override must not call its inherited method; that is, your override method must implement this method's functionality completely.

SEE ALSO
The GetFlatSize method (page 236).
The StreamToStorageUnit method (page 246).
The Unflatten method (page 246).


Previous Book Contents Book Index Next

© Apple Computer, Inc.
13 JUL 1996