Salome HOME
Updated copyright comment
[modules/shaper.git] / src / GeomAPI / GeomAPI_Pnt2d.h
index 4470a2aa6d0a995170c2a6e44a09790bf0983438..cb1863f13f5d844fb0849ac093e19933a2480bc0 100644 (file)
@@ -1,12 +1,27 @@
-// File:        GeomAPI_Pnt2d.h
-// Created:     29 May 2014
-// Author:      Artem ZHIDKOV
+// Copyright (C) 2014-2024  CEA, EDF
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
 
 #ifndef GeomAPI_Pnt2d_H_
 #define GeomAPI_Pnt2d_H_
 
 #include <GeomAPI_Interface.h>
-#include <boost/shared_ptr.hpp>
+#include <memory>
 
 class GeomAPI_XY;
 class GeomAPI_Pnt;
@@ -17,38 +32,51 @@ class GeomAPI_Dir;
  * \brief 2D point defined by two coordinates
  */
 
-class GEOMAPI_EXPORT GeomAPI_Pnt2d : public GeomAPI_Interface
+class GeomAPI_Pnt2d : public GeomAPI_Interface
 {
  public:
   /// Creation of point by coordinates
+  GEOMAPI_EXPORT
   GeomAPI_Pnt2d(const double theX, const double theY);
   /// Creation of point by coordinates
-  GeomAPI_Pnt2d(const boost::shared_ptr<GeomAPI_XY>& theCoords);
+  GEOMAPI_EXPORT
+  GeomAPI_Pnt2d(const std::shared_ptr<GeomAPI_XY>& theCoords);
 
   /// returns X coordinate
+  GEOMAPI_EXPORT
   double x() const;
   /// returns Y coordinate
+  GEOMAPI_EXPORT
   double y() const;
 
   /// sets X coordinate
+  GEOMAPI_EXPORT
   void setX(const double theX);
   /// sets Y coordinate
+  GEOMAPI_EXPORT
   void setY(const double theY);
 
   /// Returns the 3D point
-  boost::shared_ptr<GeomAPI_Pnt> to3D(const boost::shared_ptr<GeomAPI_Pnt>& theOrigin,
-                                      const boost::shared_ptr<GeomAPI_Dir>& theDirX,
-                                      const boost::shared_ptr<GeomAPI_Dir>& theDirY);
+  GEOMAPI_EXPORT
+  std::shared_ptr<GeomAPI_Pnt> to3D(const std::shared_ptr<GeomAPI_Pnt>& theOrigin,
+                                      const std::shared_ptr<GeomAPI_Dir>& theDirX,
+                                      const std::shared_ptr<GeomAPI_Dir>& theDirY);
 
   /// returns coordinates of the point
-  const boost::shared_ptr<GeomAPI_XY> xy();
+  GEOMAPI_EXPORT
+  const std::shared_ptr<GeomAPI_XY> xy();
 
   /// Distance between two points
-  double distance(const boost::shared_ptr<GeomAPI_Pnt2d>& theOther) const;
+  GEOMAPI_EXPORT
+  double distance(const std::shared_ptr<GeomAPI_Pnt2d>& theOther) const;
 
   /// Returns whether the distance between two points is less then precision confusion
-  bool isEqual(const boost::shared_ptr<GeomAPI_Pnt2d>& theOther) const;
+  GEOMAPI_EXPORT
+  bool isEqual(const std::shared_ptr<GeomAPI_Pnt2d>& theOther) const;
 };
 
+//! Pointer on the object
+typedef std::shared_ptr<GeomAPI_Pnt2d> GeomPnt2dPtr;
+
 #endif