1 // Name : ConstructionAPI_Plane.cpp
5 // 27/05/16 - Sergey POKHODENKO - Creation of the file
7 //--------------------------------------------------------------------------------------
8 #include "ConstructionAPI_Plane.h"
9 //--------------------------------------------------------------------------------------
10 #include <ModelHighAPI_Double.h>
11 #include <ModelHighAPI_Selection.h>
12 //--------------------------------------------------------------------------------------
13 ConstructionAPI_Plane::ConstructionAPI_Plane(
14 const std::shared_ptr<ModelAPI_Feature> & theFeature)
15 : ModelHighAPI_Interface(theFeature)
20 ConstructionAPI_Plane::ConstructionAPI_Plane(
21 const std::shared_ptr<ModelAPI_Feature> & theFeature,
22 const ModelHighAPI_Selection & theFace,
23 const ModelHighAPI_Double & theDistance)
24 : ModelHighAPI_Interface(theFeature)
27 setFaceAndDistance(theFace, theDistance);
30 ConstructionAPI_Plane::ConstructionAPI_Plane(
31 const std::shared_ptr<ModelAPI_Feature> & theFeature,
32 const ModelHighAPI_Double & theA,
33 const ModelHighAPI_Double & theB,
34 const ModelHighAPI_Double & theC,
35 const ModelHighAPI_Double & theD)
36 : ModelHighAPI_Interface(theFeature)
39 setGeneralEquation(theA, theB, theC, theD);
42 ConstructionAPI_Plane::~ConstructionAPI_Plane()
47 void ConstructionAPI_Plane::setFaceAndDistance(
48 const ModelHighAPI_Selection & theFace,
49 const ModelHighAPI_Double & theDistance)
51 theFace.fillAttribute(myface);
52 theDistance.fillAttribute(mydistance);
57 void ConstructionAPI_Plane::setGeneralEquation(
58 const ModelHighAPI_Double & theA,
59 const ModelHighAPI_Double & theB,
60 const ModelHighAPI_Double & theC,
61 const ModelHighAPI_Double & theD)
63 theA.fillAttribute(myA);
64 theB.fillAttribute(myB);
65 theC.fillAttribute(myC);
66 theD.fillAttribute(myD);