Function CDM_FirstDocument


Definition:#include <CDM.h>
Prototype:CDM_Document CDM_FirstDocument(CDM_Collection Collection);
Arguments:

Collection: A Collection object. (CDM_Collection)

C/C++ API Sections
Tcl API Sections
Description
Return Value
Notes
See Also
Index

Description:

This function will return a Document object representing the first Document of the specified Collection. It can be used in order to start an iteration over all Documents of the Collection. This function will return the first Document in the given Collection and make the proper arrangements so as subsequent calls to CDM_NextDocument return the following Documents.

Return Value:

This function returns a Document object (of type CDM_Document) that can be used as a reference to all functions that require a Document object as input. This object will be valid until the Collection that holds this Document object is closed (through CDM_Close) and the parent Collection removed from memory. If this object is used after its parent Collection has been closed, an undefined behaviour will occur.

If an error occurs, then NULL will be return and an error message will be left at the current active Tcl interpreter (CDM_Interp).

Note that the returned object is property of the CDM and should never be freed or modified in any way by the caller.

Notes:

This function is equivelant to tip_FirstDocument (Tcl API).

See Also:

CDM_Close, CDM_NextDocument, tip_FirstDocument


Generated by: petasis@aias on Wed Aug 16 10:31:57 PM EEST 2006.