1 | #include <Dictionaries/CacheDictionary.h> |
2 | #include <Dictionaries/CacheDictionary.inc.h> |
3 | |
4 | namespace DB |
5 | { |
6 | namespace ErrorCodes |
7 | { |
8 | extern const int TYPE_MISMATCH; |
9 | } |
10 | |
11 | using TYPE = UInt16; |
12 | void CacheDictionary::getUInt16(const std::string & attribute_name, const PaddedPODArray<Key> & ids, const TYPE def, ResultArrayType<TYPE> & out) const |
13 | { |
14 | auto & attribute = getAttribute(attribute_name); |
15 | checkAttributeType(name, attribute_name, attribute.type, AttributeUnderlyingType::utUInt16); |
16 | |
17 | getItemsNumberImpl<TYPE, TYPE>(attribute, ids, out, [&](const size_t) { return def; }); |
18 | } |
19 | |
20 | } |
21 | |