1 // Name : ModelHighAPI_RefAttr.h
5 // 08/06/16 - Sergey POKHODENKO - Creation of the file
7 #ifndef SRC_MODELHIGHAPI_MODELHIGHAPI_REFATTR_H_
8 #define SRC_MODELHIGHAPI_MODELHIGHAPI_REFATTR_H_
10 //--------------------------------------------------------------------------------------
11 #include "ModelHighAPI.h"
15 //--------------------------------------------------------------------------------------
16 class ModelAPI_Attribute;
17 class ModelAPI_AttributeRefAttr;
18 class ModelAPI_AttributeRefAttrList;
19 class ModelAPI_Object;
20 class ModelHighAPI_Interface;
21 //--------------------------------------------------------------------------------------
22 /**\class ModelHighAPI_RefAttr
24 * \brief Class for filling ModelAPI_AttributeRefAttr
26 class ModelHighAPI_RefAttr
29 /// Default constructor
31 ModelHighAPI_RefAttr();
32 /// Constructor for attribute
34 ModelHighAPI_RefAttr(const std::shared_ptr<ModelAPI_Attribute> & theValue);
35 /// Constructor for object
37 ModelHighAPI_RefAttr(const std::shared_ptr<ModelAPI_Object> & theValue);
38 /// Constructor for Interface (use result() for object)
40 ModelHighAPI_RefAttr(const std::shared_ptr<ModelHighAPI_Interface> & theValue);
43 virtual ~ModelHighAPI_RefAttr();
45 /// Fill attribute values
47 virtual void fillAttribute(const std::shared_ptr<ModelAPI_AttributeRefAttr> & theAttribute) const;
49 /// Append to list attribute
51 virtual void appendToList(const std::shared_ptr<ModelAPI_AttributeRefAttrList> & theAttribute) const;
53 /// Check the object is empty
58 enum VariantType { VT_ATTRIBUTE, VT_OBJECT } myVariantType;
59 std::shared_ptr<ModelAPI_Attribute> myAttribute;
60 std::shared_ptr<ModelAPI_Object> myObject;
63 //--------------------------------------------------------------------------------------
64 //--------------------------------------------------------------------------------------
65 #endif /* SRC_MODELHIGHAPI_MODELHIGHAPI_REFATTR_H_ */