OmniSciDB  2e3a973ef4
Types.h
Go to the documentation of this file.
1 /*
2  * Copyright 2020 OmniSci, Inc.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #pragma once
18 
19 #include <map>
20 #include <string>
21 #include <tuple>
22 #include <unordered_map>
23 
26 #include "Catalog/DictDescriptor.h"
27 #include "Catalog/ForeignServer.h"
28 #include "Catalog/LinkDescriptor.h"
30 
31 namespace Catalog_Namespace {
32 
33 using TableDescriptorMap = std::map<std::string, TableDescriptor*>;
34 using TableDescriptorMapById = std::map<int, TableDescriptor*>;
35 using LogicalToPhysicalTableMapById = std::map<int32_t, std::vector<int32_t>>;
36 using ColumnKey = std::tuple<int, std::string>;
37 using ColumnDescriptorMap = std::map<ColumnKey, ColumnDescriptor*>;
38 using ColumnIdKey = std::tuple<int, int>;
39 using ColumnDescriptorMapById = std::map<ColumnIdKey, ColumnDescriptor*>;
40 using DictDescriptorMapById = std::map<DictRef, std::unique_ptr<DictDescriptor>>;
42  std::map<std::string, std::shared_ptr<DashboardDescriptor>>;
43 using LinkDescriptorMap = std::map<std::string, LinkDescriptor*>;
44 using LinkDescriptorMapById = std::map<int, LinkDescriptor*>;
46  std::unordered_map<const TableDescriptor*, const ColumnDescriptor*>;
47 using ForeignServerMap =
48  std::map<std::string, std::shared_ptr<foreign_storage::ForeignServer>>;
50  std::map<int, std::shared_ptr<foreign_storage::ForeignServer>>;
51 } // namespace Catalog_Namespace
std::unordered_map< const TableDescriptor *, const ColumnDescriptor * > DeletedColumnPerTableMap
Definition: Types.h:46
std::tuple< int, std::string > ColumnKey
Definition: Types.h:36
std::map< ColumnKey, ColumnDescriptor * > ColumnDescriptorMap
Definition: Types.h:37
std::map< std::string, std::shared_ptr< foreign_storage::ForeignServer > > ForeignServerMap
Definition: Types.h:48
std::map< int32_t, std::vector< int32_t > > LogicalToPhysicalTableMapById
Definition: Types.h:35
std::map< ColumnIdKey, ColumnDescriptor * > ColumnDescriptorMapById
Definition: Types.h:39
std::map< int, TableDescriptor * > TableDescriptorMapById
Definition: Types.h:34
std::map< std::string, LinkDescriptor * > LinkDescriptorMap
Definition: Types.h:43
std::map< int, std::shared_ptr< foreign_storage::ForeignServer > > ForeignServerMapById
Definition: Types.h:50
std::map< std::string, std::shared_ptr< DashboardDescriptor > > DashboardDescriptorMap
Definition: Types.h:42
std::map< int, LinkDescriptor * > LinkDescriptorMapById
Definition: Types.h:44
std::map< DictRef, std::unique_ptr< DictDescriptor > > DictDescriptorMapById
Definition: Types.h:40
std::map< std::string, TableDescriptor * > TableDescriptorMap
Definition: Types.h:33
std::tuple< int, int > ColumnIdKey
Definition: Types.h:38