-// Copyright (C) 2019-2020 CEA/DEN, EDF R&D
+// Copyright (C) 2019-2023 CEA, EDF
//
// 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
{
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;
/// Multiplicities of B-spline knots
GEOMAPI_EXPORT std::list<int> mults() const;
-};
-//! Pointer on the object
-typedef std::shared_ptr<GeomAPI_BSpline> GeomBSplinePtr;
+ /// Return \c true if the curve is periodic
+ GEOMAPI_EXPORT bool isPeriodic() const;
+
+ /// Convert any curve into a B-spline curve
+ GEOMAPI_EXPORT static GeomBSplinePtr convertToBSpline (const GeomCurvePtr& theCurve);
+};
#endif