cp_heap

Section: libcprops - cp_heap (3)
Updated: JULY 2006
Index Return to Main Contents
 

NAME

cp_heap_get_mode, cp_heap_set_mode, cp_heap_unset_mode - retrieve or change heap mode settings

 

SYNOPSIS

#include <cprops/heap.h>

int cp_heap_get_mode(cp_heap *heap);
void cp_heap_set_mode(cp_heap *heap, int mode);
void cp_heap_unset_mode(cp_heap *heap, int mode);

 

DESCRIPTION

The following mode bits affect heap function behavior:

COLLECTION_MODE_COPY
 - if the heap was initialized with a non-null copy function, this function is invoked by cp_heap_push (3) when inserting items in the heap.
COLLECTION_MODE_DEEP
 - if the heap was initialized with a non-null item destructor function, this function is invoked by cp_heap_pop (3) when removing items and by cp_heap_destroy (3) when deallocating the heap.
COLLECTION_MODE_NOSYNC
 - if set heap operations do not perform locking. 

cp_heap_set_mode may be used to set the specified mode bits.
cp_heap_unset_mode may be used to unset the specified mode bits.

 

RETURN VALUE

cp_heap_get_mode returns the current heap mode settings.

 

SEE ALSO

cp_heap_create(3), cp_heap_push(3), cp_heap_lock(3)


 

Index

NAME
SYNOPSIS
DESCRIPTION
RETURN VALUE
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 10:58:19 GMT, July 29, 2006