Nebula
Loading...
Searching...
No Matches
filterset.h
Go to the documentation of this file.
1#pragma once
2//------------------------------------------------------------------------------
13//------------------------------------------------------------------------------
14#include "attributeid.h"
15
16namespace MemDb
17{
18
20{
21public:
23 FilterSet() = default;
25 FilterSet(const std::initializer_list<AttributeId> inclusive, const std::initializer_list<AttributeId> exclusive);
32
34 TableSignature const& Inclusive() const;
36 TableSignature const& Exclusive() const;
39
40private:
47};
48
49//------------------------------------------------------------------------------
52inline
53FilterSet::FilterSet(const std::initializer_list<AttributeId> inclusive, const std::initializer_list<AttributeId> exclusive) :
54 inclusive(inclusive),
55 exclusive(exclusive),
56 inclusiveComponents(inclusive)
57{
58 // empty
59}
60
61//------------------------------------------------------------------------------
64inline
66 inclusive(inclusive),
67 exclusive(),
68 inclusiveComponents(inclusive)
69{
70 // empty
71};
72
73//------------------------------------------------------------------------------
76inline
78 inclusive(inclusive),
79 exclusive(exclusive),
80 inclusiveComponents(inclusive)
81{
82 // empty
83}
84//------------------------------------------------------------------------------
87inline
88FilterSet::FilterSet(const TableSignature& inclusive, const TableSignature& exclusive, const Util::FixedArray<AttributeId>& inclusiveComponents) :
89 inclusive(inclusive),
90 exclusive(exclusive),
91 inclusiveComponents(inclusiveComponents)
92{
93}
94;
95
96//------------------------------------------------------------------------------
99inline TableSignature const&
101{
102 return this->inclusive;
103}
104
105//------------------------------------------------------------------------------
108inline TableSignature const&
110{
111 return this->exclusive;
112}
113
114//------------------------------------------------------------------------------
119{
120 return this->inclusiveComponents;
121}
122
123} // namespace MemDb
Definition filterset.h:20
TableSignature exclusive
categories must NOT contain any components in this array
Definition filterset.h:44
Util::FixedArray< AttributeId > inclusiveComponents
components that are in the inclusive set
Definition filterset.h:46
TableSignature inclusive
categories must include all components in this signature
Definition filterset.h:42
Util::FixedArray< AttributeId > const & PropertyIds() const
get a fixed array of all the components contained in the inclusive set
Definition filterset.h:118
TableSignature const & Exclusive() const
get the exclusive signature mask
Definition filterset.h:109
TableSignature const & Inclusive() const
get the inclusive signature mask
Definition filterset.h:100
FilterSet()=default
default constructor
Basically a bitfield with packed ComponentIds.
Definition tablesignature.h:26
Implements a fixed size one-dimensional array.
Definition fixedarray.h:20
Attribute.
Definition attribute.h:26