Salome HOME
Updated copyright comment
[modules/shaper.git] / src / SketchAPI / SketchAPI_MacroArc.h
index c24e24750f74bec9aa1fe57b45c711fd4d2e5f56..fb684eeb1607951f0eeb2ec7eaeb43bacdc3e24b 100644 (file)
@@ -1,8 +1,21 @@
-// Copyright (C) 2014-20xx CEA/DEN, EDF R&D -->
-
-// File:        SketchAPI_MacroArc.h
-// Created:     09 June 2016
-// Author:      Dmitry Bobylev
+// 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 SketchAPI_MacroArc_H_
 #define SketchAPI_MacroArc_H_
@@ -75,11 +88,7 @@ public:
   SKETCHAPI_EXPORT
   virtual ~SketchAPI_MacroArc();
 
-  void test() {
-    SketchPlugin_MacroArc::ID();
-  }
-
-  INTERFACE_12(SketchPlugin_MacroArc::ID(),
+  INTERFACE_14(SketchPlugin_MacroArc::ID(),
                arcType, SketchPlugin_MacroArc::ARC_TYPE(),
                ModelAPI_AttributeString, /** Arc type */,
                center, SketchPlugin_MacroArc::CENTER_POINT_ID(),
@@ -98,6 +107,10 @@ public:
                ModelAPI_AttributeRefAttr, /** Tangent point */,
                endPoint3, SketchPlugin_MacroArc::END_POINT_3_ID(),
                GeomDataAPI_Point2D, /** End point */,
+               transversalPoint, SketchPlugin_MacroArc::TRANSVERSAL_POINT_ID(),
+               ModelAPI_AttributeRefAttr, /** Transversal point */,
+               endPoint4, SketchPlugin_MacroArc::END_POINT_4_ID(),
+               GeomDataAPI_Point2D, /** End point */,
                reversed, SketchPlugin_MacroArc::REVERSED_ID(),
                ModelAPI_AttributeBoolean, /** Reversed flag */,
                radius, SketchPlugin_MacroArc::RADIUS_ID(),
@@ -105,8 +118,6 @@ public:
                angle, SketchPlugin_MacroArc::ANGLE_ID(),
                ModelAPI_AttributeDouble, /** Angle */)
 
-private:
-
   /// Set by center and start, end point.
   SKETCHAPI_EXPORT
   void setByCenterStartEnd(double theCenterX, double theCenterY,
@@ -144,6 +155,18 @@ private:
   void setByTangent(const ModelHighAPI_RefAttr& theTangentPoint,
                     const std::shared_ptr<GeomAPI_Pnt2d>& theEnd,
                     bool theInversed);
+
+  /// Set by tangent and end point.
+  SKETCHAPI_EXPORT
+  void setByTransversal(const ModelHighAPI_RefAttr& theTransversalPoint,
+                        double theEndX, double theEndY,
+                        bool theInversed);
+
+  /// Set by tangent and end point.
+  SKETCHAPI_EXPORT
+  void setByTransversal(const ModelHighAPI_RefAttr& theTransversalPoint,
+                        const std::shared_ptr<GeomAPI_Pnt2d>& theEnd,
+                        bool theInversed);
 };
 
 /// Pointer on Arc object.