From: Daniel Arndt Date: Thu, 3 Jun 2021 13:40:25 +0000 (-0400) Subject: Remove deprecated CellAccessor::active() X-Git-Tag: v9.4.0-rc1~1282^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2eb3d544f8c76ffa069f63d433be1e2e90c32774;p=dealii.git Remove deprecated CellAccessor::active() --- diff --git a/contrib/python-bindings/source/cell_accessor_wrapper.cc b/contrib/python-bindings/source/cell_accessor_wrapper.cc index 18a2042885..db46907472 100644 --- a/contrib/python-bindings/source/cell_accessor_wrapper.cc +++ b/contrib/python-bindings/source/cell_accessor_wrapper.cc @@ -679,11 +679,11 @@ namespace python CellAccessorWrapper::active() const { if ((dim == 2) && (spacedim == 2)) - return internal::cell_cast<2, 2>(cell_accessor)->active(); + return internal::cell_cast<2, 2>(cell_accessor)->is_active(); else if ((dim == 2) && (spacedim == 3)) - return internal::cell_cast<2, 3>(cell_accessor)->active(); + return internal::cell_cast<2, 3>(cell_accessor)->is_active(); else - return internal::cell_cast<3, 3>(cell_accessor)->active(); + return internal::cell_cast<3, 3>(cell_accessor)->is_active(); } diff --git a/doc/news/changes/incompatibilities/20210603DanielArndt b/doc/news/changes/incompatibilities/20210603DanielArndt new file mode 100644 index 0000000000..bc0582d8f5 --- /dev/null +++ b/doc/news/changes/incompatibilities/20210603DanielArndt @@ -0,0 +1,3 @@ +Removed: The deprecated member function CellAccessor::active() has been removed. +
+(Daniel Arndt, 2021/06/03) diff --git a/include/deal.II/grid/tria_accessor.h b/include/deal.II/grid/tria_accessor.h index 7556f1c90c..ece9c4c881 100644 --- a/include/deal.II/grid/tria_accessor.h +++ b/include/deal.II/grid/tria_accessor.h @@ -3637,23 +3637,6 @@ public: * @{ */ - /** - * Test that the cell has no children (this is the criterion for whether a - * cell is called "active"). - * - * See the - * @ref GlossActive "glossary" - * for more information. - * - * @deprecated This function is deprecated. Use the is_active() - * function instead, which satisfies the naming scheme of other - * functions inquiring about yes/no properties of cells (e.g., - * is_ghost(), is_locally_owned(), etc.). - */ - DEAL_II_DEPRECATED - bool - active() const; - /** * Test that the cell has no children (this is the criterion for whether a * cell is called "active"). diff --git a/include/deal.II/grid/tria_accessor.templates.h b/include/deal.II/grid/tria_accessor.templates.h index 33589f3ff4..d857cc3984 100644 --- a/include/deal.II/grid/tria_accessor.templates.h +++ b/include/deal.II/grid/tria_accessor.templates.h @@ -3659,15 +3659,6 @@ CellAccessor::neighbor(const unsigned int face_no) const -template -inline bool -CellAccessor::active() const -{ - return !this->has_children(); -} - - - template inline bool CellAccessor::is_active() const diff --git a/tests/base/mpi_noncontiguous_partitioner_02.cc b/tests/base/mpi_noncontiguous_partitioner_02.cc index ff1eb448fb..4814fba27f 100644 --- a/tests/base/mpi_noncontiguous_partitioner_02.cc +++ b/tests/base/mpi_noncontiguous_partitioner_02.cc @@ -75,7 +75,7 @@ test(const MPI_Comm &comm, const bool do_revert, const unsigned int dir) // ... has (symm) for (const auto &cell : dof_handler.active_cell_iterators()) - if (cell->active() && cell->is_locally_owned()) + if (cell->is_active() && cell->is_locally_owned()) { auto c = cell->center(); for (unsigned int i = 0; i < dim; i++) diff --git a/tests/matrix_free/compute_diagonal_01.cc b/tests/matrix_free/compute_diagonal_01.cc index 27b02694e9..8df8881a98 100644 --- a/tests/matrix_free/compute_diagonal_01.cc +++ b/tests/matrix_free/compute_diagonal_01.cc @@ -33,7 +33,8 @@ test() tria.refine_global(); for (auto &cell : tria.active_cell_iterators()) - if (cell->active() && cell->is_locally_owned() && cell->center()[0] < 0.0) + if (cell->is_active() && cell->is_locally_owned() && + cell->center()[0] < 0.0) cell->set_refine_flag(); tria.execute_coarsening_and_refinement(); diff --git a/tests/matrix_free/compute_diagonal_04.cc b/tests/matrix_free/compute_diagonal_04.cc index 83635df1b3..257c097442 100644 --- a/tests/matrix_free/compute_diagonal_04.cc +++ b/tests/matrix_free/compute_diagonal_04.cc @@ -32,7 +32,8 @@ test() tria.refine_global(); for (auto &cell : tria.active_cell_iterators()) - if (cell->active() && cell->is_locally_owned() && cell->center()[0] < 0.0) + if (cell->is_active() && cell->is_locally_owned() && + cell->center()[0] < 0.0) cell->set_refine_flag(); tria.execute_coarsening_and_refinement(); diff --git a/tests/multigrid-global-coarsening/mg_transfer_a_01.cc b/tests/multigrid-global-coarsening/mg_transfer_a_01.cc index 2cc30638c5..621f8e8b8d 100644 --- a/tests/multigrid-global-coarsening/mg_transfer_a_01.cc +++ b/tests/multigrid-global-coarsening/mg_transfer_a_01.cc @@ -68,7 +68,7 @@ do_test(const FiniteElement &fe_fine, const FiniteElement &fe_coarse) tria.refine_global(); for (auto &cell : tria.active_cell_iterators()) - if (cell->active() && cell->center()[0] < 0.5) + if (cell->is_active() && cell->center()[0] < 0.5) cell->set_refine_flag(); tria.execute_coarsening_and_refinement(); }; diff --git a/tests/multigrid-global-coarsening/mg_transfer_a_02.cc b/tests/multigrid-global-coarsening/mg_transfer_a_02.cc index 3fe7d77bff..f9ba6d81af 100644 --- a/tests/multigrid-global-coarsening/mg_transfer_a_02.cc +++ b/tests/multigrid-global-coarsening/mg_transfer_a_02.cc @@ -55,7 +55,7 @@ do_test(const FiniteElement &fe_fine, const FiniteElement &fe_coarse) tria.refine_global(); for (auto &cell : tria.active_cell_iterators()) - if (cell->active() && cell->center()[0] < 0.5) + if (cell->is_active() && cell->center()[0] < 0.5) cell->set_refine_flag(); tria.execute_coarsening_and_refinement(); }; diff --git a/tests/multigrid-global-coarsening/mg_transfer_a_03.cc b/tests/multigrid-global-coarsening/mg_transfer_a_03.cc index 2509e5b814..c956650683 100644 --- a/tests/multigrid-global-coarsening/mg_transfer_a_03.cc +++ b/tests/multigrid-global-coarsening/mg_transfer_a_03.cc @@ -55,7 +55,7 @@ do_test(const FiniteElement &fe_fine, const FiniteElement &fe_coarse) tria.refine_global(); for (auto &cell : tria.active_cell_iterators()) - if (cell->active() && cell->center()[0] < 0.5) + if (cell->is_active() && cell->center()[0] < 0.5) cell->set_refine_flag(); tria.execute_coarsening_and_refinement(); }; diff --git a/tests/multigrid-global-coarsening/mg_transfer_p_01.cc b/tests/multigrid-global-coarsening/mg_transfer_p_01.cc index ee719fb57e..91561c5327 100644 --- a/tests/multigrid-global-coarsening/mg_transfer_p_01.cc +++ b/tests/multigrid-global-coarsening/mg_transfer_p_01.cc @@ -70,7 +70,7 @@ do_test(const FiniteElement &fe_fine, const FiniteElement &fe_coarse) tria.refine_global(); for (auto &cell : tria.active_cell_iterators()) - if (cell->active() && cell->center()[0] < 0.5) + if (cell->is_active() && cell->center()[0] < 0.5) cell->set_refine_flag(); tria.execute_coarsening_and_refinement(); diff --git a/tests/multigrid-global-coarsening/mg_transfer_p_03.cc b/tests/multigrid-global-coarsening/mg_transfer_p_03.cc index 106c0691a2..aaa1e21d70 100644 --- a/tests/multigrid-global-coarsening/mg_transfer_p_03.cc +++ b/tests/multigrid-global-coarsening/mg_transfer_p_03.cc @@ -57,7 +57,7 @@ do_test(const FiniteElement &fe_fine, const FiniteElement &fe_coarse) tria.refine_global(); for (auto &cell : tria.active_cell_iterators()) - if (cell->active() && cell->center()[0] < 0.5) + if (cell->is_active() && cell->center()[0] < 0.5) cell->set_refine_flag(); tria.execute_coarsening_and_refinement(); diff --git a/tests/multigrid-global-coarsening/mg_transfer_p_04.cc b/tests/multigrid-global-coarsening/mg_transfer_p_04.cc index 5950610258..004ee665a9 100644 --- a/tests/multigrid-global-coarsening/mg_transfer_p_04.cc +++ b/tests/multigrid-global-coarsening/mg_transfer_p_04.cc @@ -94,7 +94,7 @@ do_test(const FiniteElement &fe_fine, const FiniteElement &fe_coarse) tria.refine_global(); for (auto &cell : tria.active_cell_iterators()) - if (cell->active() && cell->center()[0] < 0.5) + if (cell->is_active() && cell->center()[0] < 0.5) cell->set_refine_flag(); tria.execute_coarsening_and_refinement(); }; diff --git a/tests/multigrid/mg_data_out_01.cc b/tests/multigrid/mg_data_out_01.cc index 3cf902a492..42dbc27f22 100644 --- a/tests/multigrid/mg_data_out_01.cc +++ b/tests/multigrid/mg_data_out_01.cc @@ -36,7 +36,8 @@ print(DataOut &data_out, const Triangulation &tria) for (auto cell = p.first(tria); cell.state() == IteratorState::valid; cell = p.second(tria, cell)) { - deallog << " cell lvl=" << cell->level() << " active=" << cell->active() + deallog << " cell lvl=" << cell->level() + << " active=" << cell->is_active() << " id=" << cell->id().to_string() << std::endl; } } diff --git a/tests/multigrid/mg_data_out_02.cc b/tests/multigrid/mg_data_out_02.cc index 72d0e23506..b6ee6d2593 100644 --- a/tests/multigrid/mg_data_out_02.cc +++ b/tests/multigrid/mg_data_out_02.cc @@ -37,7 +37,8 @@ print(DataOut &data_out, const Triangulation &tria) for (auto cell = p.first(tria); cell.state() == IteratorState::valid; cell = p.second(tria, cell)) { - deallog << " cell lvl=" << cell->level() << " active=" << cell->active() + deallog << " cell lvl=" << cell->level() + << " active=" << cell->is_active() << " owner=" << static_cast(cell->level_subdomain_id()) << " id=" << cell->id().to_string() << std::endl; }