indexedFace.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | www.openfoam.com
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8  Copyright (C) 2013-2016 OpenFOAM Foundation
9 -------------------------------------------------------------------------------
10 License
11  This file is part of OpenFOAM.
12 
13  OpenFOAM is free software: you can redistribute it and/or modify it
14  under the terms of the GNU General Public License as published by
15  the Free Software Foundation, either version 3 of the License, or
16  (at your option) any later version.
17 
18  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21  for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25 
26 Class
27  CGAL::indexedFace
28 
29 Description
30  An indexed form of CGAL::Triangulation_face_base_2<K> used to keep
31  track of the vertices in the triangulation.
32 
33 \*---------------------------------------------------------------------------*/
34 
35 #ifndef Foam_CGAL_indexedFace_H
36 #define Foam_CGAL_indexedFace_H
37 
38 #include "indexedVertex.H"
39 
40 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
41 
42 namespace CGAL
43 {
44 
45 /*---------------------------------------------------------------------------*\
46  Class indexedFace Declaration
47 \*---------------------------------------------------------------------------*/
48 
49 template<class Gt, class Fb=CGAL::Triangulation_face_base_2<Gt>>
50 class indexedFace
51 :
52  public Fb
53 {
54  // Private data
55 
56  //- The index for this triangle face
57  // -1: triangle and changed and associated data needs updating
58  // >=0: index of triangles, set by external update algorithm
59  int index_;
60 
61 
62 public:
63 
64  enum faceTypes
65  {
66  UNCHANGED = 0,
67  CHANGED = -1,
69  };
70 
71  typedef typename Fb::Vertex_handle Vertex_handle;
72  typedef typename Fb::Face_handle Face_handle;
73 
74  template<class TDS2>
75  struct Rebind_TDS
76  {
77  typedef typename Fb::template Rebind_TDS<TDS2>::Other Fb2;
79  };
80 
81 
82  // Constructors
83 
84  inline indexedFace();
85 
86  inline indexedFace
87  (
88  Vertex_handle v0,
89  Vertex_handle v1,
90  Vertex_handle v2
91  );
92 
93  inline indexedFace
94  (
95  Vertex_handle v0,
96  Vertex_handle v1,
97  Vertex_handle v2,
98  Face_handle n0,
99  Face_handle n1,
100  Face_handle n2
101  );
102 
103 
104  // Member Functions
105 
106  inline void set_vertex(int i, Vertex_handle v);
107 
108  inline void set_vertices();
109 
110  inline void set_vertices
111  (
112  Vertex_handle v0,
113  Vertex_handle v1,
114  Vertex_handle v2
115  );
116 
117  inline int& faceIndex();
118 
119  inline int faceIndex() const;
120 
121 };
122 
123 
124 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
125 
126 } // End namespace CGAL
127 
128 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
129 
130 #include "indexedFaceI.H"
131 
132 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
133 
134 #endif
135 
136 // ************************************************************************* //
Fb::Face_handle Face_handle
Definition: indexedFace.H:68
Specializations for CGAL-related routines.
Definition: indexedCell.H:60
void set_vertex(int i, Vertex_handle v)
Definition: indexedFaceI.H:63
Fb::Vertex_handle Vertex_handle
Definition: indexedFace.H:67
Fb::template Rebind_TDS< TDS2 >::Other Fb2
Definition: indexedFace.H:73
indexedFace< Gt, Fb2 > Other
Definition: indexedFace.H:74
An indexed form of CGAL::Triangulation_face_base_2<K> used to keep track of the vertices in the trian...
Definition: indexedFace.H:43