From b646c6cbf8c1730b528f4b0165e68c1e6c745cfb Mon Sep 17 00:00:00 2001 From: hartmann Date: Fri, 14 Jun 2002 13:17:41 +0000 Subject: [PATCH] Change the clear_user_flags/pointers function back to non-const. Add 8 new functions connected with save/load_user_pointers. git-svn-id: https://svn.dealii.org/trunk@6130 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/deal.II/include/grid/tria.h | 75 ++++++++++++++++++++++++----- 1 file changed, 63 insertions(+), 12 deletions(-) diff --git a/deal.II/deal.II/include/grid/tria.h b/deal.II/deal.II/include/grid/tria.h index 73976f5081..490c6452c7 100644 --- a/deal.II/deal.II/include/grid/tria.h +++ b/deal.II/deal.II/include/grid/tria.h @@ -2055,15 +2055,10 @@ class Triangulation : public TriaDimensionInfo, * @name User flag handling */ /*@{*/ - /** - * Clear all user pointers. - */ - void clear_user_pointers () const; - /** * Clear all user flags. */ - void clear_user_flags () const; + void clear_user_flags (); /** * Save all user flags. See the general @@ -2164,6 +2159,62 @@ class Triangulation : public TriaDimensionInfo, void load_user_flags_hex (const std::vector &v); /*@}*/ + /** + * Clear all user pointers. + */ + void clear_user_pointers (); + + /** + * Save all user pointers. The + * output vector is resized if + * necessary. + */ + void save_user_pointers (std::vector &v) const; + + /** + * Read the information stored by + * @p{save_user_pointers}. + */ + void load_user_pointers (const std::vector &v); + + /** + * Save the user pointers on + * lines. The output vector is + * resized if necessary. + */ + void save_user_pointers_line (std::vector &v) const; + + /** + * Load the user pointers located + * on lines. + */ + void load_user_pointers_line (const std::vector &v); + + /** + * Save the user pointers on + * quads. The output vector is + * resized if necessary. + */ + void save_user_pointers_quad (std::vector &v) const; + + /** + * Load the user pointers located + * on quads. + */ + void load_user_pointers_quad (const std::vector &v); + + /** + * Save the user pointers on + * hexes. The output vector is + * resized if necessary. + */ + void save_user_pointers_hex (std::vector &v) const; + + /** + * Load the user pointers located + * on hexs. + */ + void load_user_pointers_hex (const std::vector &v); /* ------------------------------------ */ /** @@ -3288,12 +3339,12 @@ template <> void Triangulation<3>::create_triangulation (const std::vector void Triangulation<1>::distort_random (const double factor, const bool keep_boundary); -template <> void Triangulation<1>::clear_user_pointers () const; -template <> void Triangulation<1>::clear_user_flags () const; -template <> void Triangulation<2>::clear_user_pointers () const; -template <> void Triangulation<2>::clear_user_flags () const; -template <> void Triangulation<3>::clear_user_pointers () const; -template <> void Triangulation<3>::clear_user_flags () const; +template <> void Triangulation<1>::clear_user_pointers (); +template <> void Triangulation<1>::clear_user_flags (); +template <> void Triangulation<2>::clear_user_pointers (); +template <> void Triangulation<2>::clear_user_flags (); +template <> void Triangulation<3>::clear_user_pointers (); +template <> void Triangulation<3>::clear_user_flags (); template <> void Triangulation<1>::save_user_flags_quad (std::ostream &) const; template <> void Triangulation<1>::save_user_flags_quad (std::vector &) const; template <> void Triangulation<1>::load_user_flags_quad (std::istream &); -- 2.39.5