ufe  4.2
Universal Front End is a DCC-agnostic component that will allow a DCC to browse and edit data in multiple data models
value.h
Go to the documentation of this file.
1 #line 1 "S:/jenkins/workspace/ECP/ufe/ufe-full-python3.10-windows/ufe/include/value.h"
2 #ifndef _ufeValue
3 #define _ufeValue
4 
5 // =======================================================================
6 // Copyright 2021 Autodesk, Inc. All rights reserved.
7 //
8 // This computer source code and related instructions and comments are the
9 // unpublished confidential and proprietary information of Autodesk, Inc.
10 // and are protected under applicable copyright and trade secret law. They
11 // may not be disclosed to, copied or used by any third party without the
12 // prior written consent of Autodesk, Inc.
13 // =======================================================================
14 
15 #include "common/ufeExport.h"
16 
17 #include <memory>
18 #include <string>
19 #include <unordered_map>
20 
21 UFE_NS_DEF {
22 
24 
35 public:
37  Value();
38 
43  template<typename T> Value(const T& v);
44 
46  Value(const Value&);
47 
49  Value(Value&&) noexcept;
50 
52  Value& operator=(const Value& v);
53 
55  Value& operator=(Value&&) noexcept;
56 
58  ~Value();
59 
62  template<typename T> T get() const;
63 
68  template<typename T> T safeGet(T arg) const;
69 
71  bool empty() const;
72 
74  std::string typeName() const;
75 
77  template<typename T> bool isType() const;
78 
80  bool operator==(const Value& rhs) const;
82  bool operator!=(const Value& rhs) const;
84 
85 private:
86 
87  struct Imp;
88 
89  std::unique_ptr<Imp> _imp;
90 };
91 
92 using ValueDictionary = std::unordered_map<std::string, Value>;
93 
94 }
95 
96 #endif /* _ufeValue */
std::string string(const Path &path)
Definition of macros for symbol visibility.
std::unordered_map< std::string, Value > ValueDictionary
Definition: value.h:92
Value class that can hold a wide set of types.
Definition: value.h:34
#define UFE_NS_DEF
Definition: ufe.h:35
std::unique_ptr< Imp > _imp
Definition: value.h:87
#define UFE_SDK_DECL
Definition: ufeExport.h:36