1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
3 // File: GeomData_Dir.h
4 // Created: 24 Apr 2014
5 // Author: Mikhail PONIKAROV
7 #ifndef GeomData_Dir_H_
8 #define GeomData_Dir_H_
11 #include "GeomDataAPI_Dir.h"
12 #include <TDataStd_RealArray.hxx>
13 #include <TDF_Label.hxx>
18 /**\class GeomData_Dir
20 * \brief Attribute that contains direction.
22 class GeomData_Dir : public GeomDataAPI_Dir
24 Handle_TDataStd_RealArray myCoords; ///< X, Y and Z doubles as real array attribute [0; 2]
26 /// Defines the double value
27 GEOMDATA_EXPORT virtual void setValue(const double theX, const double theY, const double theZ);
28 /// Defines the direction
29 GEOMDATA_EXPORT virtual void setValue(const std::shared_ptr<GeomAPI_Dir>& theDir);
31 /// Returns the X double value
32 GEOMDATA_EXPORT virtual double x() const;
33 /// Returns the Y double value
34 GEOMDATA_EXPORT virtual double y() const;
35 /// Returns the Z double value
36 GEOMDATA_EXPORT virtual double z() const;
37 /// Returns the direction of this attribute
38 GEOMDATA_EXPORT virtual std::shared_ptr<GeomAPI_Dir> dir();
41 /// Initializes attributes
42 GEOMDATA_EXPORT GeomData_Dir(TDF_Label& theLabel);
44 friend class Model_Data;