#include <lib/sconfig.h>
#include <lib/tl/defop.h>
Include dependency graph for binsearch.h:
This graph shows which files directly or indirectly include this file:
Go to the source code of this file.
Defines | |
#define | _TemplateLibrary_BINARYSEARCH_H_ 1 |
Functions | |
template<typename T, typename K> ssize_t | BinarySearch (const T *arr, size_t nelem, const K &key) |
Binary search template. | |
template<typename T, typename K, typename _OP> ssize_t | TLBinarySearch (const T *_arr, size_t nelem, const K &key, const _OP &op=TLDefaultOperators_CDT< T >()) |
Binary search template for insertion index. | |
template<typename T, typename K> bool | BinarySearch (const T *arr, size_t nelem, const K &key, size_t *ret_idx) |
Binary search template for insertion index. | |
template<typename T, typename K, typename _OP> bool | TLBinarySearch (const T *_arr, size_t nelem, const K &key, size_t *ret_idx, const _OP &op=TLDefaultOperators_CDT< T >()) |
Binary search template for insertion index. |
Definition in file binsearch.h.
|
Definition at line 18 of file binsearch.h. |
|
Binary search template for insertion index.
There are different versions of this function; one using an operator class, one using standard C(++) operators. There is another version of this function available which does not return the insertion index. This is the version using standard C(++) operators. Definition at line 105 of file binsearch.h. |
|
Binary search template.
The array must be sorted in ascenting order. There is another version of this function available which returns the insertion index. There are different versions of this function; one using an operator class, one using standard C(++) operators; this is the latter. Definition at line 46 of file binsearch.h. References ssize_t. |
|
Binary search template for insertion index.
Definition at line 127 of file binsearch.h. Referenced by VM::VMLinker::_MergeNamespaceInfo_Recursive(), TLArray< RJumpEntry, RJumpEntry_Operators >::BinSearch(), and TLSortedArray< T, _OP >::search(). |
|
Binary search template for insertion index.
Definition at line 66 of file binsearch.h. References ssize_t. |