13 #ifndef __SAS_STRINGBTREE_H
14 #define __SAS_STRINGBTREE_H
16 #include "sasstringbtreenode.h"
186 extern __C__ block_size_t
198 extern __C__ block_size_t
213 extern __C__ SASStringBTreeNode_t
230 extern __C__ SASStringBTreeNode_t
270 extern __C__ SASStringBTreeNode_t
283 extern __C__ SASStringBTreeNode_t
647 block_size_t page_size,
int expanding);
667 extern __C__ block_size_t
678 extern __C__ SASStringBTreeNode_t
690 extern __C__ SASStringBTreeNode_t
715 SASStringBTreeNode_t free_block);
__C__ block_size_t SASStringBTreeFreeSpaceNoLock(SASStringBTree_t btree)
Internal function. Return the total available free space on SAS B-Tree btree.
__C__ int SASStringBTreeContainsKey(SASStringBTree_t btree, char *key)
Return true if the SAS B-Tree btree contains the key key.
__C__ SASStringBTreeNode_t SASStringBTreeNearAlloc(void *nearObj)
Internal function to allocate a new SASStringBTreeNode_t from the containing SAS B-Tree near an exist...
__C__ void * SASStringBTreeGet(SASStringBTree_t btree, char *key)
Return the memory address value associated with key in SAS B-Tree btree.
__C__ SASStringBTree_t SASStringBTreeExpandCreate(SASStringBTree_t btree)
Internal function that creates new block of B-Tree nodes for an expanding SAS B-Tree btree...
__C__ long SASStringBTreeGetModCount(SASStringBTree_t btree)
Return the number or insert/replace/remove operations performed on btree.
__C__ SASStringBTree_t SASStringBTreeCreatePageSize(block_size_t block_size, block_size_t page_size)
Create a new expanding SAS B-Tree with heap_size size and page_size node size.
__C__ int SASStringBTreeIsEmpty_nolock(SASStringBTree_t btree)
Return true if the SAS B-Tree btree is empty.
__C__ int SASStringBTreePut(SASStringBTree_t btree, char *key, void *value)
Add a new element value with key key in the SAS B-Tree btree.
__C__ SASStringBTreeNode_t SASStringBTreeAllocNoLock(SASStringBTree_t btree)
Internal function. Allocate a new SASStringBTreeNode_t from SAS B-Tree btree.
__C__ SASStringBTreeNode_t SASStringBTreeGetRootNode(SASStringBTree_t btree)
Internal function that returns the root SASStringBTreeNode_t node for btree B-Tree.
void * SASStringBTree_t
Handle to an instance of String B-tree.
Definition: sasstringbtree.h:102
__C__ SASStringBTreeNode_t SASStringBTreeAlloc(SASStringBTree_t btree)
Internal function to allocate a new SASStringBTreeNode_t for SAS B-Tree btree.
__C__ void SASStringBTreeDestroyNoLock(SASStringBTree_t btree)
Destroy the SAS B-Tree btree.
#define __C__
ignore this macro behind the curtain
Definition: sasmsync.h:32
__C__ SASStringBTreeNode_t SASStringBTreeGetRootNodeNoLock(SASStringBTree_t btree)
Internal function that returns the root SASStringBTreeNode_t node for btree B-Tree.
__C__ void SASStringBTreeFree(SASStringBTree_t btree, SASStringBTreeNode_t free_block)
Internal function to return a SASStringBTreeNode_t free_block to the free space of B-tree btree for l...
__C__ int SASStringBTreeContainsKey_nolock(SASStringBTree_t btree, char *key)
Return true if the SAS B-Tree btree contains the key key.
__C__ void SASStringBTreeNearDealloc(void *memAddr)
Internal function to free the SASStringBTreeNode_t at memAddr from its associated SASStringBTree_t B-...
__C__ long SASStringBTreeGetCurCount(SASStringBTree_t btree)
Return the number of elements in the SAS B-Tree btree.
__C__ void * SASStringBTreeGet_nolock(SASStringBTree_t btree, char *key)
Return the memory address value associated with key in SAS B-Tree btree.
__C__ SASStringBTree_t SASStringBTreeInit(void *block, block_size_t block_size, block_size_t page_size, int expanding)
Internal function to initialize storage as a B-tree.
__C__ void * SASStringBTreeRemove_nolock(SASStringBTree_t btree, char *key)
Remove the key key and its associated value from SAS B-Tree btree.
__C__ void SASStringBTreeNearDeallocNoLock(void *memAddr)
Internal function. Free the SASStringBTreeNode_t on memAddr from its associated SASStringBTree_t B-Tr...
__C__ void * SASStringBTreeReplace_nolock(SASStringBTree_t btree, char *key, void *value)
Replace the associated value of the element with key key in SAS B-Tree btree with the value value...
__C__ long SASStringBTreeGetModCount_nolock(SASStringBTree_t btree)
Return the number or insert/replace/remove operations performed on btree.
__C__ void SASStringBTreeDestroy(SASStringBTree_t btree)
Destroy the SAS B-Tree btree.
__C__ SASStringBTree_t SASStringBTreeCreate(block_size_t block_size)
Create a new expanding SAS B-Tree with initial heap_size size and default page_size for nodes...
__C__ void * SASStringBTreeRemove(SASStringBTree_t btree, char *key)
Remove the key key and its associated value from SAS B-Tree btree.
__C__ char * SASStringBTreeGetMaxKey(SASStringBTree_t btree)
Return the maximum key string from btree.
__C__ int SASStringBTreePut_nolock(SASStringBTree_t btree, char *key, void *value)
Add a new element value with key key in the SAS B-Tree btree.
__C__ void * SASStringBTreeReplace(SASStringBTree_t btree, char *key, void *value)
Replace the associated value of the element with key key in SAS B-Tree btree with the value value...
__C__ block_size_t SASStringBTreeFreeSpace(SASStringBTree_t btree)
Return the total available node free space for btree.
__C__ char * SASStringBTreeGetMaxKey_nolock(SASStringBTree_t btree)
Return the maximum key string from btree.
__C__ SASStringBTree_t SASStringBTreeFixedCreate(block_size_t block_size)
Create a fixed SAS B-Tree of block_size size capacity.
__C__ block_size_t SASStringBTreeAllocSize(SASStringBTree_t btree)
Return the page size used for node allocation for btree.
__C__ void SASStringBTreeFreeNoLock(SASStringBTree_t btree, SASStringBTreeNode_t free_block)
Internal function. Free the SASStringBTreeNode_t free_block from B-tree btree.
__C__ char * SASStringBTreeGetMinKey_nolock(SASStringBTree_t btree)
Return the minimum key string from btree.
__C__ int SASStringBTreeIsEmpty(SASStringBTree_t btree)
Return true if the SAS B-Tree btree is empty.
__C__ char * SASStringBTreeGetMinKey(SASStringBTree_t btree)
Return the minimum key string from btree.
__C__ SASStringBTreeNode_t SASStringBTreeNearAllocNoLock(void *nearObj)
Internal function. Allocate a new SASStringBTreeNode_t from SAS B-Tree near nearObj.