home *** CD-ROM | disk | FTP | other *** search
- /*
- File: ProfileLib.h
-
- Contains: ProfileLib API for dumping and clearing profiling counters
-
- Version: 1.0
-
- Copyright: © 1997 by Apple Computer, Inc., all rights reserved.
-
- */
-
- #ifndef __PROFILELIB__
- #define __PROFILELIB__
-
- #ifndef __TYPES__
- #include <Types.h>
- #endif
- #ifndef __ERRORS__
- #include <Errors.h>
- #endif
- #ifndef __FILES__
- #include <Files.h>
- #endif
- #ifndef __PROCESSES__
- #include <Processes.h>
- #endif
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- #if PRAGMA_IMPORT_SUPPORTED
- #pragma import on
- #endif
-
- #if PRAGMA_ALIGN_SUPPORTED
- #pragma options align=mac68k
- #endif
-
- /* Error codes */
-
- enum {
- kProfRegistryBusy = -30769,
- kDataMergeMismatch = -30768
- };
-
-
- /*--------------------------------------------------------------------------------------------*/
- /* Calls to clear/dump counters for a specific registered connection of a fragment */
- /* by a specific process */
- /*--------------------------------------------------------------------------------------------*/
-
- extern OSStatus
- ProfClearCounters(
- ConstStr63Param fragmentName,
- const ProcessSerialNumber *processNumber);
-
- extern OSStatus
- ProfDumpCounters(
- ConstStr63Param fragmentName,
- const ProcessSerialNumber *processNumber,
- Boolean mergeData,
- ConstStr63Param dumpFileName);
-
-
- /*--------------------------------------------------------------------------------------------*/
- /* Calls to clear/dump counters for all registered connections of a fragment */
- /*--------------------------------------------------------------------------------------------*/
-
- extern OSStatus
- ProfClearFragmentCounters(
- ConstStr63Param fragmentName);
-
- extern OSStatus
- ProfDumpFragmentCounters(
- ConstStr63Param fragmentName,
- Boolean mergeData,
- ConstStr63Param dumpFileName);
-
- /*--------------------------------------------------------------------------------------------*/
- /* Calls to clear/dump counters for the specified process */
- /*--------------------------------------------------------------------------------------------*/
-
- extern OSStatus
- ProfClearProcessCounters(
- const ProcessSerialNumber *processNumber);
-
- extern OSStatus
- ProfDumpProcessCounters(
- const ProcessSerialNumber *processNumber,
- Boolean mergeData,
- ConstStr63Param dumpFileName);
-
- /*--------------------------------------------------------------------------------------------*/
- /* Calls to clear/dump counters for all registered items */
- /*--------------------------------------------------------------------------------------------*/
-
- extern OSStatus
- ProfClearAllCounters(void);
-
- extern OSStatus
- ProfDumpAllCounters(
- Boolean mergeData,
- ConstStr63Param dumpFileName);
-
-
-
- #if PRAGMA_ALIGN_SUPPORTED
- #pragma options align=reset
- #endif
-
- #if PRAGMA_IMPORT_SUPPORTED
- #pragma import off
- #endif
-
- #ifdef __cplusplus
- }
- #endif
-
- #endif /* __PROFILELIB__ */
-
-