1 // Created on: 1991-10-04
2 // Created by: Remi GILET
3 // Copyright (c) 1991-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
6 // This file is part of Open CASCADE Technology software library.
8 // This library is free software; you can redistribute it and/or modify it under
9 // the terms of the GNU Lesser General Public License version 2.1 as published
10 // by the Free Software Foundation, with special exception defined in the file
11 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 // distribution for complete text of the license and disclaimer of any warranty.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
17 #ifndef _GccInt_Bisec_HeaderFile
18 #define _GccInt_Bisec_HeaderFile
20 #include <Standard.hxx>
21 #include <Standard_Type.hxx>
23 #include <MMgt_TShared.hxx>
24 #include <GccInt_IType.hxx>
25 class Standard_DomainError;
35 DEFINE_STANDARD_HANDLE(GccInt_Bisec, MMgt_TShared)
37 //! The deferred class GccInt_Bisec is the root class for
38 //! elementary bisecting loci between two simple geometric
39 //! objects (i.e. circles, lines or points).
40 //! Bisecting loci between two geometric objects are such
41 //! that each of their points is at the same distance from the
42 //! two geometric objects. It is typically a curve, such as a
43 //! line, circle or conic.
44 //! Generally there is more than one elementary object
45 //! which is the solution to a bisecting loci problem: each
46 //! solution is described with one elementary bisecting
47 //! locus. For example, the bisectors of two secant straight
48 //! lines are two perpendicular straight lines.
49 //! The GccInt package provides concrete implementations
50 //! of the following elementary derived bisecting loci:
51 //! - lines, circles, ellipses, hyperbolas and parabolas, and
52 //! - points (not used in this context).
53 //! The GccAna package provides numerous algorithms for
54 //! computing the bisecting loci between circles, lines or
55 //! points, whose solutions are these types of elementary bisecting locus.
56 class GccInt_Bisec : public MMgt_TShared
62 //! Returns the type of bisecting object (line, circle,
63 //! parabola, hyperbola, ellipse, point).
64 Standard_EXPORT virtual GccInt_IType ArcType() const = 0;
66 //! Returns the bisecting line when ArcType returns Pnt.
67 //! An exception DomainError is raised if ArcType is not a Pnt.
68 Standard_EXPORT virtual gp_Pnt2d Point() const;
70 //! Returns the bisecting line when ArcType returns Lin.
71 //! An exception DomainError is raised if ArcType is not a Lin.
72 Standard_EXPORT virtual gp_Lin2d Line() const;
74 //! Returns the bisecting line when ArcType returns Cir.
75 //! An exception DomainError is raised if ArcType is not a Cir.
76 Standard_EXPORT virtual gp_Circ2d Circle() const;
78 //! Returns the bisecting line when ArcType returns Hpr.
79 //! An exception DomainError is raised if ArcType is not a Hpr.
80 Standard_EXPORT virtual gp_Hypr2d Hyperbola() const;
82 //! Returns the bisecting line when ArcType returns Par.
83 //! An exception DomainError is raised if ArcType is not a Par.
84 Standard_EXPORT virtual gp_Parab2d Parabola() const;
86 //! Returns the bisecting line when ArcType returns Ell.
87 //! An exception DomainError is raised if ArcType is not an Ell.
88 Standard_EXPORT virtual gp_Elips2d Ellipse() const;
93 DEFINE_STANDARD_RTTIEXT(GccInt_Bisec,MMgt_TShared)
113 #endif // _GccInt_Bisec_HeaderFile