VAPOR3 3.9.4
PMetadataClasses.h
Go to the documentation of this file.
1#pragma once
2
3#include "PSection.h"
4#include "VContainer.h"
5#include "VSection.h"
6#include <vapor/DC.h>
7
8class QTreeWidget;
9class QTreeWidgetItem;
10class PStringDropdown;
17
18namespace VAPoR {
19 class ControlExec;
20 class RenderParams;
21 class DataMgr;
22}
23
28 Q_OBJECT
29
31
32public:
34
35protected:
36 bool requireDataMgr() const override { return true; }
37 void updateGUI() const override;
38};
39
45class PMetadataSection : public PWidget {
46 Q_OBJECT
47
49 VSection* _section;
50 VDimensionMetadataTree* _dimTree;
51 VVariableMetadataTree* _varTree;
54 PStringDropdown* _metadataDataset;
55 PIntegerSliderEdit* _metadataTimestep;
56
57public:
59
60 static const std::string SelectedDatasetTag;
61 static const std::string MetadataTimestepTag;
62
63protected:
64 void updateGUI() const override;
65};
66
71class VMetadataTree : public VSectionGroup, public Updateable {
72 Q_OBJECT
73
74public:
76 virtual void Update(VAPoR::ParamsBase* p, VAPoR::ParamsMgr* pm, VAPoR::DataMgr* dm) override;
77
78signals:
80
81protected:
82
83 QTreeWidget* _tree;
85 size_t _ts;
87 std::vector<std::string> _topLevelBranches;
88
89 virtual void _gatherBranches(std::vector<std::string> &branches, VAPoR::ParamsBase* rp = nullptr) const = 0;
90 virtual void _generateMetadata(QTreeWidgetItem* item) const = 0;
92};
93
97 Q_OBJECT
98
99public:
101
102protected:
103 void _gatherBranches(std::vector<std::string> &branches, VAPoR::ParamsBase* p = nullptr) const override;
104 void _generateMetadata(QTreeWidgetItem* item) const override;
105
106 void _generateCoordVarInfo(QTreeWidgetItem* parent, const QString& qCoordVar) const;
107 void _generateAttributeInfo(QTreeWidgetItem* parent, const VAPoR::DC::BaseVar baseVar) const;
108};
109
113 Q_OBJECT
114
115public:
117
118protected:
119 void _gatherBranches(std::vector<std::string> &branches, VAPoR::ParamsBase* p = nullptr) const override;
120};
121
125 Q_OBJECT
126
127public:
129
130protected:
131 void _gatherBranches(std::vector<std::string> &branches, VAPoR::ParamsBase* p) const override;
132 void _generateMetadata(QTreeWidgetItem* item) const override;
133};
134
138 Q_OBJECT
139
140public:
142 //void Update(VAPoR::ParamsBase* p, VAPoR::ParamsMgr* pm, VAPoR::DataMgr* dm) override;
143
144protected:
145 void _gatherBranches(std::vector<std::string> &dims, VAPoR::ParamsBase* p) const override;
146 void _generateMetadata(QTreeWidgetItem* item) const override;
147};
148
152 Q_OBJECT
153
154public:
156
157protected:
158 void _gatherBranches(std::vector<std::string> &vars, VAPoR::ParamsBase* p) const override;
159 void _generateMetadata(QTreeWidgetItem* item) const override;
160};
static const std::string MetadataTimestepTag
void updateGUI() const override
PMetadataSection(VAPoR::ControlExec *ce)
static const std::string SelectedDatasetTag
void updateGUI() const override
bool requireDataMgr() const override
Provides an interface that standardizes objects that support params updates.
Definition: Updateable.h:13
Provides API for VAPOR visualizer User Interfaces (UIs)
Base class for storing variable metadata.
Definition: DC.h:754
A cache based data reader.
Definition: DataMgr.h:110
Nodes with state in Xml tree representation.
Definition: ParamsBase.h:50
A singleton class for managing Params instances.
Definition: ParamsMgr.h:53
void _gatherBranches(std::vector< std::string > &branches, VAPoR::ParamsBase *p) const override
void _generateMetadata(QTreeWidgetItem *item) const override
void _gatherBranches(std::vector< std::string > &dims, VAPoR::ParamsBase *p) const override
void _generateMetadata(QTreeWidgetItem *item) const override
void _gatherBranches(std::vector< std::string > &vars, VAPoR::ParamsBase *p) const override
void _generateMetadata(QTreeWidgetItem *item) const override
bool _checkNeedUpdate(VAPoR::ParamsBase *p, VAPoR::DataMgr *dm)
std::vector< std::string > _topLevelBranches
virtual void _gatherBranches(std::vector< std::string > &branches, VAPoR::ParamsBase *rp=nullptr) const =0
virtual void _generateMetadata(QTreeWidgetItem *item) const =0
QTreeWidget * _tree
VAPoR::DataMgr * _dm
virtual void Update(VAPoR::ParamsBase *p, VAPoR::ParamsMgr *pm, VAPoR::DataMgr *dm) override
void _timestepRejected()
void _gatherBranches(std::vector< std::string > &branches, VAPoR::ParamsBase *p=nullptr) const override
VSection that implements the standardized widget group interface. Use this one when possible.
Definition: VSection.h:46
void _generateMetadata(QTreeWidgetItem *item) const override
void _generateAttributeInfo(QTreeWidgetItem *parent, const VAPoR::DC::BaseVar baseVar) const
void _generateCoordVarInfo(QTreeWidgetItem *parent, const QString &qCoordVar) const
void _gatherBranches(std::vector< std::string > &branches, VAPoR::ParamsBase *p=nullptr) const override