1 // Created on: 1992-04-06
2 // Created by: Jacques GOUSSARD
3 // Copyright (c) 1992-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 #include <Standard_DomainError.hxx>
18 #include <Precision.hxx>
19 #include <IntPatch_Point.hxx>
22 inline void IntPatch_ALine::Replace (const Standard_Integer Index, const IntPatch_Point& Pnt)
27 inline void IntPatch_ALine::SetFirstPoint (const Standard_Integer IndFirst)
33 inline void IntPatch_ALine::SetLastPoint (const Standard_Integer IndLast)
39 inline Standard_Real IntPatch_ALine::FirstParameter (Standard_Boolean& IsIncluded) const
41 Standard_Real bid,first;
42 curv.Domain(first,bid);
43 IsIncluded = !curv.IsFirstOpen();
47 inline Standard_Real IntPatch_ALine::LastParameter (Standard_Boolean& IsIncluded) const
49 Standard_Real bid,last;
50 curv.Domain(bid,last);
51 IsIncluded = !curv.IsLastOpen();
55 inline gp_Pnt IntPatch_ALine::Value (const Standard_Real U)
57 return curv.Value(U);// Value leve l exception DomainError
60 inline Standard_Boolean IntPatch_ALine::D1(const Standard_Real U, gp_Pnt& P, gp_Vec& Du)
62 return curv.D1u(U,P,Du); // D1u leve l exception DomainError
65 inline Standard_Boolean IntPatch_ALine::FindParameter(const gp_Pnt& P, Standard_Real& Para) const
67 return curv.FindParameter(P,Para);
70 inline Standard_Boolean IntPatch_ALine::HasFirstPoint () const
75 inline Standard_Boolean IntPatch_ALine::HasLastPoint () const
80 inline const IntPatch_Point& IntPatch_ALine::FirstPoint () const
82 if (!fipt) {throw Standard_DomainError();}
86 inline const IntPatch_Point& IntPatch_ALine::LastPoint () const
88 if (!lapt) {throw Standard_DomainError();}
92 inline Standard_Integer IntPatch_ALine::NbVertex () const
97 inline const IntPatch_Point& IntPatch_ALine::Vertex (const Standard_Integer Index) const