1 // Created on: 1993-08-10
2 // Created by: Remi LEQUETTE
3 // Copyright (c) 1993-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 _BRep_PointRepresentation_HeaderFile
18 #define _BRep_PointRepresentation_HeaderFile
20 #include <Standard.hxx>
21 #include <Standard_Type.hxx>
23 #include <TopLoc_Location.hxx>
24 #include <Standard_Real.hxx>
25 #include <MMgt_TShared.hxx>
26 #include <Standard_Boolean.hxx>
27 class Standard_DomainError;
28 class TopLoc_Location;
34 class BRep_PointRepresentation;
35 DEFINE_STANDARD_HANDLE(BRep_PointRepresentation, MMgt_TShared)
37 //! Root class for the points representations.
38 //! Contains a location and a parameter.
39 class BRep_PointRepresentation : public MMgt_TShared
45 //! A point on a 3d curve.
46 Standard_EXPORT virtual Standard_Boolean IsPointOnCurve() const;
48 //! A point on a 2d curve on a surface.
49 Standard_EXPORT virtual Standard_Boolean IsPointOnCurveOnSurface() const;
51 //! A point on a surface.
52 Standard_EXPORT virtual Standard_Boolean IsPointOnSurface() const;
54 //! A point on the curve <C>.
55 Standard_EXPORT virtual Standard_Boolean IsPointOnCurve (const Handle(Geom_Curve)& C, const TopLoc_Location& L) const;
57 //! A point on the 2d curve <PC> on the surface <S>.
58 Standard_EXPORT virtual Standard_Boolean IsPointOnCurveOnSurface (const Handle(Geom2d_Curve)& PC, const Handle(Geom_Surface)& S, const TopLoc_Location& L) const;
60 //! A point on the surface <S>.
61 Standard_EXPORT virtual Standard_Boolean IsPointOnSurface (const Handle(Geom_Surface)& S, const TopLoc_Location& L) const;
63 const TopLoc_Location& Location() const;
65 void Location (const TopLoc_Location& L);
67 Standard_Real Parameter() const;
69 void Parameter (const Standard_Real P);
71 Standard_EXPORT virtual Standard_Real Parameter2() const;
73 Standard_EXPORT virtual void Parameter2 (const Standard_Real P);
75 Standard_EXPORT virtual const Handle(Geom_Curve)& Curve() const;
77 Standard_EXPORT virtual void Curve (const Handle(Geom_Curve)& C);
79 Standard_EXPORT virtual const Handle(Geom2d_Curve)& PCurve() const;
81 Standard_EXPORT virtual void PCurve (const Handle(Geom2d_Curve)& C);
83 Standard_EXPORT virtual const Handle(Geom_Surface)& Surface() const;
85 Standard_EXPORT virtual void Surface (const Handle(Geom_Surface)& S);
90 DEFINE_STANDARD_RTTIEXT(BRep_PointRepresentation,MMgt_TShared)
95 Standard_EXPORT BRep_PointRepresentation(const Standard_Real P, const TopLoc_Location& L);
102 TopLoc_Location myLocation;
103 Standard_Real myParameter;
109 #include <BRep_PointRepresentation.lxx>
115 #endif // _BRep_PointRepresentation_HeaderFile