OpenLexocad  27.0
PropertyValue.h
Go to the documentation of this file.
1 #pragma once
2 #pragma warning(disable : 4251)
3 
4 #include <Base/Type.h>
5 #include <Core/Variant.h>
6 #include <Core/core_defines2.h>
7 
8 #include <unordered_map>
9 
10 
11 namespace Core
12 {
13 class Property;
14 
15 class CORE_EXPORT PropertyValue // Wraps property type and Core::Variant value
16 {
17 public:
18  PropertyValue() : propertyName(""), propertyType(Base::Type::badType()), value(Core::Variant()) {}
19 
20  PropertyValue(const std::string& name, Base::Type t, const Core::Variant& v) : propertyName(name), propertyType(t), value(v) {}
21 
22  std::string propertyName;
25 };
26 
27 
28 typedef std::unordered_map<std::string, Core::Property*> PropertyMap;
29 typedef std::unordered_map<std::string, PropertyValue> PropertyValueMap;
30 
31 } // namespace Core
PropertyValue(const std::string &name, Base::Type t, const Core::Variant &v)
Definition: PropertyValue.h:20
#define CORE_EXPORT
Definition: core_defines2.h:10
Core::PropertyText name
Definition: CoreDocument.h:143
PropertyValue()
Definition: PropertyValue.h:18
Core::Variant value
Definition: PropertyValue.h:24
std::string propertyName
Definition: PropertyValue.h:22
Definition: Type.h:56
Definition: Variant.h:90
std::unordered_map< std::string, Core::Property * > PropertyMap
Definition: PropertyValue.h:28
std::unordered_map< std::string, PropertyValue > PropertyValueMap
Definition: PropertyValue.h:29
Definition: Base.h:19
Definition: AbstractXMLReader.h:8
Base::Type propertyType
Definition: PropertyValue.h:23
Definition: PropertyValue.h:15