OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
KeyValuesExtractor.h
Go to the documentation of this file.
1#pragma once
4
5#include <map>
6#include <list>
7#include <memory>
8#include <stdint.h>
9#include "OTCore/Variable.h"
11
13{
14public:
15 KeyValuesExtractor() = default;
17 KeyValuesExtractor(const KeyValuesExtractor& other) = delete;
18 KeyValuesExtractor(const KeyValuesExtractor&& other) = delete;
21
24 void loadAllRangeSelectionInformation(const MetadataAssemblyData& _assemblyData, std::map<std::string, std::shared_ptr<IVisualisationTable>>& _allTablesByName);
25
26
27 std::map<std::string, std::list<ot::Variable>>* getFields() { return &m_fields; };
28
29 uint64_t getNumberOfFields() const;
30
31private:
32
33 bool isRangeWithinTableDimensions(std::shared_ptr<EntityTableSelectedRanges> _range, const ot::GenericDataStructMatrix& _tableData);
34
38 std::vector<std::string> extractFieldsFromRange(std::shared_ptr<EntityTableSelectedRanges> _range, const ot::GenericDataStructMatrix& _tableData, std::map<std::string, std::map<std::uint32_t, ot::Variable>>& _outAllSortedFields);
39
42 bool transformSelectedDataIntoSelectedDataType(std::map<std::string, std::list<ot::Variable>>& _allFields, std::map<std::string, std::string>& _rangeTypesByRangeNames, const char _decimalSeparator);
43
44 void cleanFieldKey(std::string& _key);
45
46 std::map<std::string,std::list<ot::Variable>> m_fields;
47};
48
49
Container for groups of TableSelectionEntities that describe the same metadata categorization.
Definition KeyValuesExtractor.h:13
KeyValuesExtractor(const KeyValuesExtractor &&other)=delete
uint64_t getNumberOfFields() const
Definition KeyValuesExtractor.cpp:85
~KeyValuesExtractor()=default
KeyValuesExtractor(const KeyValuesExtractor &other)=delete
KeyValuesExtractor & operator=(const KeyValuesExtractor &other)=delete
void loadAllRangeSelectionInformation(const MetadataAssemblyData &_assemblyData, std::map< std::string, std::shared_ptr< IVisualisationTable > > &_allTablesByName)
Tries to transforms the selections into the selected data types.
Definition KeyValuesExtractor.cpp:8
KeyValuesExtractor()=default
std::map< std::string, std::list< ot::Variable > > * getFields()
Definition KeyValuesExtractor.h:27
KeyValuesExtractor & operator=(const KeyValuesExtractor &&other)=delete
Definition MetadataAssemblyData.h:13