Itasca C++ Interface
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Modules Pages
imodellist.h
1 #pragma once
2 
3 #include "base/src/variant.h"
4 
5 namespace itasca {
6 
7  class IModelList {
8  public:
9  // Information to describe a property in a model.
10  struct PropInfo {
11  QString name_;
13  bool advanced_ = false;
14  bool readOnly_ = false;
15  };
16  // the string signifying no model assignment
17  static const char *noModelAssigned() { return "unassigned"; }
18  // Information to describe a model.
19  struct ModelInfo {
20  QString keyword_;
21  QString fullName_;
22  bool advanced_ = false;
23  bool creep_ = false;
24  bool liquefaction_ = false;
25  std::vector<PropInfo> properties_;
26  QStringList states_;
27  };
28  // Used to return info about model/prop info and values in a region of the model.
29  struct ModelQueryInfo {
30  QString keyword_; // QString() if more than one model found.
31  std::vector<PropInfo> properties_; // empty if more than one model found.
32  std::vector<Variant> values_; // void type of value null if more than one value of the given property found.
33  void clear() { keyword_ = QString(); properties_.clear(); values_.clear(); }
34  };
35  virtual QStringList getAllModelKeywords() const=0;
36  virtual ModelInfo getModelInfo(const QString &keyword) const=0;
37  };
38 
39 } // namespace itasca
40 // EoF
41 
namespace Itasca
Definition: basememory.cpp:9
Definition: imodellist.h:7
A simpler (and slightly faster) version of a QVariant, added for interfaces that do not use Qt.
64 bit floating point value.
Definition: variant.h:79
Definition: imodellist.h:29
Type
Indicates the type of the variant. 18 types are predefined.
Definition: variant.h:70
Definition: imodellist.h:10
Definition: imodellist.h:19