Thrill  0.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
strings1.cpp
Go to the documentation of this file.
1 /*******************************************************************************
2  * tlx/sort/strings1.cpp
3  *
4  * Part of tlx - http://panthema.net/tlx
5  *
6  * Copyright (C) 2018 Timo Bingmann <[email protected]>
7  *
8  * All rights reserved. Published under the Boost Software License, Version 1.0
9  ******************************************************************************/
10 
11 #include <tlx/sort/strings.hpp>
15 
16 namespace tlx {
17 
18 namespace ss = tlx::sort_strings_detail;
19 
20 void sort_strings(char** strings, size_t size, size_t memory) {
21  return sort_strings(
22  reinterpret_cast<unsigned char**>(strings), size, memory);
23 }
24 
25 void sort_strings(unsigned char** strings, size_t size, size_t memory) {
27  ss::UCharStringSet(strings, strings + size), /* depth */ 0, memory);
28 }
29 
30 void sort_strings(std::vector<char*>& strings, size_t memory) {
31  return sort_strings(strings.data(), strings.size(), memory);
32 }
33 
34 void sort_strings(std::vector<unsigned char*>& strings, size_t memory) {
35  return sort_strings(strings.data(), strings.size(), memory);
36 }
37 
38 } // namespace tlx
39 
40 /******************************************************************************/
Class implementing StringSet concept for char* and unsigned char* strings.
Definition: string_set.hpp:190
void sort_strings(char **strings, size_t size, size_t memory=0)
Sort a set of strings represented by C-style char* in place.
Definition: strings1.cpp:20
static void radixsort_CE3(const StringSet &ss, size_t depth, size_t memory)
Definition: radix_sort.hpp:331