aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/containers/comptrie/key_selector.h
blob: f156d6a909a5ed9c57a0c22d1d6a1f7686da8d12 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#pragma once

#include <util/generic/vector.h>
#include <util/generic/string.h>
#include <util/generic/strbuf.h>

template <class T>
struct TCompactTrieKeySelector {
    typedef TVector<T> TKey;
    typedef TVector<T> TKeyBuf;
};

template <class TChar>
struct TCompactTrieCharKeySelector {
    typedef TBasicString<TChar> TKey; 
    typedef TBasicStringBuf<TChar> TKeyBuf;
};

template <>
struct TCompactTrieKeySelector<char>: public TCompactTrieCharKeySelector<char> {
};

template <>
struct TCompactTrieKeySelector<wchar16>: public TCompactTrieCharKeySelector<wchar16> {
};

template <>
struct TCompactTrieKeySelector<wchar32>: public TCompactTrieCharKeySelector<wchar32> {
};