CommonLibSSE (powerof3)
NiTStringMap.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include "RE/N/NiTMap.h"
4 
5 namespace RE
6 {
7  // 28
8  template <class Parent, class T>
9  class NiTStringTemplateMap : public Parent
10  {
11  private:
12  using Base = Parent;
13 
14  public:
15  using key_type = typename Base::key_type;
16  using mapped_type = typename Base::mapped_type;
17  using value_type = typename Base::value_type;
18  using size_type = typename Base::size_type;
19 
20  NiTStringTemplateMap(std::uint32_t a_hashSize = 37, bool a_copy = true) :
21  Base(a_hashSize),
22  _copy(a_copy),
23  _pad21(0),
24  _pad22(0),
25  _pad24(0)
26  {}
27 
28  virtual ~NiTStringTemplateMap(); // 00
29 
30  protected:
31  // override (Parent)
32  std::uint32_t hash_function(key_type a_key) const override; // 01
33  bool key_eq(key_type a_lhs, key_type a_rhs) const override; // 02
34  void assign_value(value_type* a_value, key_type a_key, mapped_type a_mapped) override; // 03
35  void clear_value(value_type* a_value) override; // 04
36 
37  // members
38  bool _copy; // 20
39  std::uint8_t _pad21; // 21
40  std::uint16_t _pad22; // 22
41  std::uint32_t _pad24; // 24
42  };
43 
44  // 28
45  template <class T>
46  class NiTStringMap : public NiTStringTemplateMap<NiTMap<const char*, T>, T>
47  {
48  private:
50 
51  public:
52  using key_type = typename Base::key_type;
53  using mapped_type = typename Base::mapped_type;
54  using value_type = typename Base::value_type;
55  using size_type = typename Base::size_type;
56 
57  virtual ~NiTStringMap(); // 00
58  };
59 }
typename Base::key_type key_type
Definition: NiTMap.h:15
typename Base::size_type size_type
Definition: NiTMap.h:18
typename Base::mapped_type mapped_type
Definition: NiTMap.h:16
typename Base::value_type value_type
Definition: NiTMap.h:17
Definition: NiTStringMap.h:47
virtual ~NiTStringMap()
Definition: NiTStringMap.h:10
std::uint32_t _pad24
Definition: NiTStringMap.h:41
bool key_eq(key_type a_lhs, key_type a_rhs) const override
std::uint16_t _pad22
Definition: NiTStringMap.h:40
typename Base::mapped_type mapped_type
Definition: NiTStringMap.h:16
typename Base::key_type key_type
Definition: NiTStringMap.h:15
void clear_value(value_type *a_value) override
typename Base::size_type size_type
Definition: NiTStringMap.h:18
typename Base::value_type value_type
Definition: NiTStringMap.h:17
std::uint32_t hash_function(key_type a_key) const override
bool _copy
Definition: NiTStringMap.h:38
NiTStringTemplateMap(std::uint32_t a_hashSize=37, bool a_copy=true)
Definition: NiTStringMap.h:20
std::uint8_t _pad21
Definition: NiTStringMap.h:39
void assign_value(value_type *a_value, key_type a_key, mapped_type a_mapped) override
Definition: AbsorbEffect.h:6