20 #ifndef SketchAPI_Ellipse_H_
21 #define SketchAPI_Ellipse_H_
23 #include "SketchAPI.h"
24 #include "SketchAPI_SketchEntity.h"
26 #include <SketchPlugin_Ellipse.h>
30 typedef std::pair<std::string, std::string> PairOfStrings;
45 double theCenterX,
double theCenterY,
46 double theFocusX,
double theFocusY,
47 double theMinorRadius);
52 const std::shared_ptr<GeomAPI_Pnt2d>& theCenter,
53 const std::shared_ptr<GeomAPI_Pnt2d>& theFocus,
54 double theMinorRadius);
64 const std::wstring& theExternalName);
95 double theFocusX,
double theFocusY,
96 double theMinorRadius);
102 double theMinorRadius);
114 void setCenter(
double theX,
double theY);
122 void setFocus(
double theX,
double theY);
138 const std::wstring&
center = std::wstring(),
139 const std::wstring&
firstFocus = std::wstring(),
141 const std::wstring& majorAxisStart = std::wstring(),
142 const std::wstring& majorAxisEnd = std::wstring(),
143 const std::wstring& minorAxisStart = std::wstring(),
144 const std::wstring& minorAxisEnd = std::wstring(),
145 const std::wstring& majorAxis = std::wstring(),
146 const std::wstring& minorAxis = std::wstring()) const;
158 static
void collectAuxiliaryFeatures(FeaturePtr theEllipse,
159 const PairOfStrings& theMajorAxis,
160 const PairOfStrings& theMinorAxis,
161 std::map<std::
string, FeaturePtr>& theAttrToFeature);
169 const FeaturePtr& theEllipse,
170 const std::list<PairOfStrings>& theAttributes,
171 const std::map<std::
string, FeaturePtr>& theAuxFeatures);
176 const FeaturePtr& theEllipse,
177 const std::list<PairOfStrings>& theAttributes,
178 const std::wstring& theCenter,
179 const std::wstring& theFirstFocus,
180 const std::wstring& theSecondFocus,
181 const std::wstring& theMajorAxisStart,
182 const std::wstring& theMajorAxisEnd,
183 const std::wstring& theMinorAxisStart,
184 const std::wstring& theMinorAxisEnd,
185 const std::wstring& theMajorAxis,
186 const std::wstring& theMinorAxis);
2D point defined by two coordinates
Definition: GeomAPI_Pnt2d.h:36
Attribute that contains 2D point coordinates.
Definition: GeomDataAPI_Point2D.h:37
Attribute that contains real value with double precision.
Definition: ModelAPI_AttributeDouble.h:34
Attribute that contains reference to the sub-shape of some result, the selected shape.
Definition: ModelAPI_AttributeSelection.h:35
Dump engine for the model.
Definition: ModelHighAPI_Dumper.h:81
Class for filling ModelAPI_AttributeSelection.
Definition: ModelHighAPI_Selection.h:49
Interface for Ellipse feature.
Definition: SketchAPI_Ellipse.h:36
virtual void dump(ModelHighAPI_Dumper &theDumper) const
Dump wrapped feature.
Definition: SketchAPI_Ellipse.cpp:377
virtual std::shared_ptr< ModelAPI_AttributeDouble > minorRadius() const
Minor radius.
Definition: SketchAPI_Ellipse.h:90
virtual std::shared_ptr< GeomDataAPI_Point2D > center() const
Center point.
Definition: SketchAPI_Ellipse.h:90
void setByExternalName(const std::wstring &theExternalName)
Set by external name.
Definition: SketchAPI_Ellipse.cpp:118
void setFocus(double theX, double theY)
Set focus.
Definition: SketchAPI_Ellipse.cpp:136
void setMinorRadius(double theRadius)
Set radius.
Definition: SketchAPI_Ellipse.cpp:148
virtual std::shared_ptr< GeomDataAPI_Point2D > minorAxisNegative() const
Start point of minor axis.
Definition: SketchAPI_Ellipse.h:90
std::list< std::shared_ptr< SketchAPI_SketchEntity > > construction(const std::wstring ¢er=std::wstring(), const std::wstring &firstFocus=std::wstring(), const std::wstring &secondFocus=std::wstring(), const std::wstring &majorAxisStart=std::wstring(), const std::wstring &majorAxisEnd=std::wstring(), const std::wstring &minorAxisStart=std::wstring(), const std::wstring &minorAxisEnd=std::wstring(), const std::wstring &majorAxis=std::wstring(), const std::wstring &minorAxis=std::wstring()) const
Create construction elements (focuses, axes etc.).
Definition: SketchAPI_Ellipse.cpp:274
void setByExternal(const ModelHighAPI_Selection &theExternal)
Set by external.
Definition: SketchAPI_Ellipse.cpp:112
virtual std::shared_ptr< GeomDataAPI_Point2D > secondFocus() const
Focus in negative direction of a major axis.
Definition: SketchAPI_Ellipse.h:90
void setByCenterFocusAndRadius(double theCenterX, double theCenterY, double theFocusX, double theFocusY, double theMinorRadius)
Set by center, focus and radius.
Definition: SketchAPI_Ellipse.cpp:90
virtual std::shared_ptr< GeomDataAPI_Point2D > minorAxisPositive() const
End point of minor axis.
Definition: SketchAPI_Ellipse.h:90
virtual std::shared_ptr< GeomDataAPI_Point2D > majorAxisPositive() const
End point of major axis.
Definition: SketchAPI_Ellipse.h:90
virtual std::shared_ptr< ModelAPI_AttributeDouble > majorRadius() const
Major radius.
Definition: SketchAPI_Ellipse.h:90
virtual std::shared_ptr< GeomDataAPI_Point2D > majorAxisNegative() const
Start point of major axis.
Definition: SketchAPI_Ellipse.h:90
virtual std::shared_ptr< ModelAPI_AttributeSelection > external() const
External.
Definition: SketchAPI_Ellipse.h:90
virtual ~SketchAPI_Ellipse()
Destructor.
Definition: SketchAPI_Ellipse.cpp:86
SketchAPI_Ellipse(const std::shared_ptr< ModelAPI_Feature > &theFeature)
Constructor without values.
Definition: SketchAPI_Ellipse.cpp:40
virtual std::shared_ptr< GeomDataAPI_Point2D > firstFocus() const
Focus in positive direction of a major axis.
Definition: SketchAPI_Ellipse.h:90
void setCenter(double theX, double theY)
Set center.
Definition: SketchAPI_Ellipse.cpp:124
Interface for Elliptic Arc feature.
Definition: SketchAPI_EllipticArc.h:34
Base class for Sketch feature interfaces.
Definition: SketchAPI_SketchEntity.h:38
static const std::string & MINOR_AXIS_END_ID()
2D point - end point of minor axis
Definition: SketchPlugin_Ellipse.h:80
static const std::string & FIRST_FOCUS_ID()
2D point - focus of the ellipse
Definition: SketchPlugin_Ellipse.h:48
static const std::string & MINOR_AXIS_START_ID()
2D point - start point of minor axis
Definition: SketchPlugin_Ellipse.h:74
static const std::string & ID()
Ellipse feature kind.
Definition: SketchPlugin_Ellipse.h:34
static const std::string & SECOND_FOCUS_ID()
2D point - second focus of the ellipse
Definition: SketchPlugin_Ellipse.h:54
static const std::string & MAJOR_AXIS_START_ID()
2D point - start point of major axis
Definition: SketchPlugin_Ellipse.h:61
static const std::string & MINOR_RADIUS_ID()
Minor radius of the ellipse.
Definition: SketchPlugin_Ellipse.h:94
static const std::string & CENTER_ID()
2D point - center of the ellipse
Definition: SketchPlugin_Ellipse.h:41
static const std::string & MAJOR_AXIS_END_ID()
2D point - end point of major axis
Definition: SketchPlugin_Ellipse.h:67
static const std::string & MAJOR_RADIUS_ID()
Major radius of the ellipse.
Definition: SketchPlugin_Ellipse.h:87
static const std::string & EXTERNAL_ID()
Reference to the external edge or vertex as a AttributeSelection.
Definition: SketchPlugin_SketchEntity.h:55