Salome HOME
Minor changes with classes renaming and virtual destructors declarations.
[modules/shaper.git] / src / PartSetPlugin / PartSetPlugin_Point.cxx
1 // File:        PartSetPlugin_Point.cxx
2 // Created:     27 Mar 2014
3 // Author:      Mikhail PONIKAROV
4
5 #include "PartSetPlugin_Point.h"
6 #include "ModelAPI_PluginManager.h"
7 #include "ModelAPI_Document.h"
8 #include "ModelAPI_Data.h"
9 #include "ModelAPI_AttributeDouble.h"
10
11 using namespace std;
12
13 PartSetPlugin_Point::PartSetPlugin_Point()
14 {
15 }
16
17 void PartSetPlugin_Point::initAttributes()
18 {
19   data()->addAttribute(POINT_ATTR_X, ModelAPI_AttributeDouble::type());
20   data()->addAttribute(POINT_ATTR_Y, ModelAPI_AttributeDouble::type());
21   data()->addAttribute(POINT_ATTR_Z, ModelAPI_AttributeDouble::type());
22 }
23
24 // this is for debug only
25 #include <iostream>
26 void PartSetPlugin_Point::execute() 
27 {
28   // TODO: create a real shape for the point using OCC layer
29   cout<<"X="<<data()->real(POINT_ATTR_X)->value()<<" Y="<<data()->real(POINT_ATTR_Y)->value()
30       <<" Z="<<data()->real(POINT_ATTR_Z)->value()<<endl;
31 }