Salome HOME
Copyright update 2022
[modules/shaper.git] / src / GeomAPI / GeomAPI_BSpline.h
index 95468bec452e447402013653e038af3e95fb636d..b9f7b96bef3d4392673af94485ff236ecac27d10 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2019-2020  CEA/DEN, EDF R&D
+// Copyright (C) 2019-2022  CEA/DEN, EDF R&D
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 #include <memory>
 
 class GeomAPI_Pnt;
+class GeomAPI_BSpline;
+
+//! Pointer on the object
+typedef std::shared_ptr<GeomAPI_BSpline> GeomBSplinePtr;
 
 /**\class GeomAPI_BSpline
  * \ingroup DataModel
@@ -36,7 +40,7 @@ class GeomAPI_BSpline : public GeomAPI_Interface
 {
 public:
   /// Creation of B-spline defined by a curve
-  GEOMAPI_EXPORT GeomAPI_BSpline(const GeomCurvePtr& theCurve);
+  GEOMAPI_EXPORT GeomAPI_BSpline (const GeomCurvePtr& theCurve);
 
   /// Degree of B-spline curve
   GEOMAPI_EXPORT int degree() const;
@@ -55,9 +59,9 @@ public:
 
   /// Return \c true if the curve is periodic
   GEOMAPI_EXPORT bool isPeriodic() const;
-};
 
-//! Pointer on the object
-typedef std::shared_ptr<GeomAPI_BSpline> GeomBSplinePtr;
+  /// Convert any curve into a B-spline curve
+  GEOMAPI_EXPORT static GeomBSplinePtr convertToBSpline (const GeomCurvePtr& theCurve);
+};
 
 #endif