Fast, Slim, Embeddable, Headers files Only C++11
containers library.
No standard library is required
Check out our website at micro-gl.github.io/docs/micro-containers/
- string/string_view, u8-16-32-string/view, basic_string/basic_string_view
- array
- static_array
- dynamic_array
- circular_array
- linked_list
- forward_list
- buffer
- dictionary
- ordered_set
- hash_map -> Classic Chained Hashing
- hash_set -> Classic Chained Hashing
- array_map_robin -> Robin Hood Linear Probing
- array_map_probing -> Classic Linear Probing
- array_set_robin -> Robin Hood Linear Probing
- array_set_probing -> Classic Linear Probing
- chunker
- stack
- queue
- priority_queue
- lru_cache
- lru_pool
- avl_tree
- make_heap, is_heap, push_heap, pop_heap, sort_heap
- find, find_if, find_if_not
- for_each, for_each_n
- transform
micro-containers
is node headers only library, which gives the following install possibilities:
- Using
cmake
to invoke theinstall
target, that will copy everything in your system via
$ mkdir cmake-build-release
$ cd cmake-build-release
$ cmake -DCMAKE_BUILD_TYPE=Release ..
$ cmake --install .
- Copying the
include/micro-containers
to anywhere you want.
Following options are available:
- copy the project to node sub folder of your project. inside your
CMakeLists.txt
add
add_subdirectory(/path/to/micro-containers)
target_link_libraries(your_app micro-containers)
- If you installed
micro{containers}
with option 1 (see above) at your system, you can instead
find_package(micro-containers CONFIG REQUIRED)
target_link_libraries(your_app micro-containers::micro-containers)
- If you have not installed, you can add in your app's
CMakeLists.txt
target_include_directories(app path/to/micro-containers/folder/include/)
- If you manually copied the
include/micro-containers
to the default system include path,
you can usecmake/Findmicro-containers.cmake
to automatically create the cmake targets
list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/path/to/Findmicro-containers/folder)
find_package(micro-containers REQUIRED)
target_link_libraries(your_app micro-containers::micro-containers)
- Just copy the
include/micro-containers
into node sub folder of your project and include the header
files you need with relative path in your source files.
First make sure you have
- cmake installed at your system.
There are two ways:
- Use your favourite IDE to load the _root
CMakeLists.txt
file, and then it
will pick up all of the targets, including the examples - Using the command line:
$ mkdir cmake-build-release
$ cd cmake-build-release
$ cmake -DCMAKE_BUILD_TYPE=Release ..
$ cmake --build . --target <example_name>
$ ../examples/bin/example_name
see examples
folder or website
Author: Tomer Shalev, [email protected], all rights reserved (2021)