// Copyright (c) 2005 INRIA Sophia-Antipolis (France). // All rights reserved. // // This file is part of CGAL (www.cgal.org) // // $URL: https://github.com/CGAL/cgal/blob/v5.1/Mesher_level/include/CGAL/Mesher_level_visitors.h $ // $Id: Mesher_level_visitors.h 0779373 2020-03-26T13:31:46+01:00 Sébastien Loriot // SPDX-License-Identifier: LGPL-3.0-or-later OR LicenseRef-Commercial // // // Author(s) : Laurent RINEAU #ifndef CGAL_MESHER_LEVEL_VISITORS_H #define CGAL_MESHER_LEVEL_VISITORS_H #include namespace CGAL { template class Null_mesh_visitor_level { Previous_level& previous; public: typedef Previous_level Previous_visitor; Null_mesh_visitor_level(Previous_level& p) : previous(p) { } Previous_level& previous_level() { return previous; } template void before_conflicts(E, P) const {} template void before_insertion(E, P, Z) const {} template void after_insertion(V) const {} template void after_no_insertion(E, P, Z) const {} }; // end class Null_mesh_visitor_level class Null_mesh_visitor { public: typedef Null_mesh_visitor Previous_visitor; const Null_mesh_visitor& previous_level() const { return *this; } template void before_conflicts(E, P) const {} template void before_insertion(E, P, Z) const {} template void after_insertion(V) const {} template void after_no_insertion(E, P, Z) const {} }; // end class Null_mesh_visitor template struct Combine_mesh_visitor { typedef Combine_mesh_visitor Previous_visitor; V1 v1; V2 v2; Combine_mesh_visitor(V1 v1_, V2 v2_) : v1(v1_), v2(v2_) { } Previous_visitor previous_level() { return Previous_visitor(v1.previous_level(), v2.previous_level()); } template void before_conflicts(E e, P p) { v1.before_conflicts(e, p); v2.before_conflicts(e, p); } template void before_insertion(E e, P p, Z z) { v1.before_insertion(e, p, z); v2.before_insertion(e, p, z); } template void after_insertion(V v) { v1.after_insertion(v); v2.after_insertion(v); } template void after_no_insertion(E e, P p, Z z) { v1.after_no_insertion(e, p, z); v2.after_no_insertion(e, p, z); } }; // end class Combine_mesh_visitor } // end namespace CGAL #include #endif // CGAL_MESHER_LEVEL_VISITORS_H