//---------------------------------------------------------------------------
// $Id$
//
-// Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by the deal.II authors
+// Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 by the deal.II authors
//
// This file is subject to QPL and may not be distributed
// without copyright and license information. Please refer
template <int dim, int spacedim> friend class DoFHandler;
template <int dim, int spacedim> friend class hp::DoFHandler;
- friend class internal::DoFHandler::Policy::Implementation;
- friend class internal::DoFHandler::Implementation;
- friend class internal::hp::DoFHandler::Implementation;
- friend class internal::DoFCellAccessor::Implementation;
+ friend struct internal::DoFHandler::Policy::Implementation;
+ friend struct internal::DoFHandler::Implementation;
+ friend struct internal::hp::DoFHandler::Implementation;
+ friend struct internal::DoFCellAccessor::Implementation;
};
template <int, int> friend class DoFHandler;
template <int, int> friend class hp::DoFHandler;
- friend class internal::DoFHandler::Policy::Implementation;
- friend class internal::DoFHandler::Implementation;
- friend class internal::hp::DoFHandler::Implementation;
- friend class internal::DoFCellAccessor::Implementation;
+ friend struct internal::DoFHandler::Policy::Implementation;
+ friend struct internal::DoFHandler::Implementation;
+ friend struct internal::hp::DoFHandler::Implementation;
+ friend struct internal::DoFCellAccessor::Implementation;
};
* function
*/
template <int dim, int spacedim> friend class DoFHandler;
- friend class internal::DoFCellAccessor::Implementation;
+ friend struct internal::DoFCellAccessor::Implementation;
};
//---------------------------------------------------------------------------
// $Id$
//
-// Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by the deal.II authors
+// Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 by the deal.II authors
//
// This file is subject to QPL and may not be distributed
// without copyright and license information. Please refer
* <tt>renumber_dofs(vector<unsigned int>)</tt> function with the array, which
* converts old into new degree of freedom indices.
*
- *
+ *
* <h3>Serializing (loading or storing) DoFHandler objects</h3>
*
* Like many other classes in deal.II, the DoFHandler class can stream
void load (Archive & ar, const unsigned int version);
BOOST_SERIALIZATION_SPLIT_MEMBER()
-
+
/**
* @todo Replace by ExcInternalError.
*/
*/
template <int, class> friend class DoFAccessor;
template <class> friend class DoFCellAccessor;
- friend class internal::DoFAccessor::Implementation;
- friend class internal::DoFCellAccessor::Implementation;
+ friend struct internal::DoFAccessor::Implementation;
+ friend struct internal::DoFCellAccessor::Implementation;
- friend class internal::DoFHandler::Implementation;
- friend class internal::DoFHandler::Policy::Implementation;
+ friend struct internal::DoFHandler::Implementation;
+ friend struct internal::DoFHandler::Policy::Implementation;
};
ar & number_cache;
ar & levels;
ar & faces;
-
+
// write out the number of triangulation cells and later check
// during loading that this number is indeed correct; same with something that
// identifies the FE and the policy
unsigned int n_cells = tria->n_cells();
std::string fe_name = selected_fe->get_name();
std::string policy_name = typeid(*policy).name();
-
+
ar & n_cells & fe_name & policy_name;
}
ar & block_info_object;
ar & vertex_dofs;
ar & number_cache;
-
+
// boost::serialization can restore pointers just fine, but if the
// pointer object still points to something useful, that object is
// not destroyed and we end up with a memory leak. consequently,
levels.resize (0);
delete faces;
faces = 0;
-
+
ar & levels;
ar & faces;
unsigned int n_cells;
std::string fe_name;
std::string policy_name;
-
- ar & n_cells & fe_name & policy_name;
- AssertThrow (n_cells == tria->n_cells(),
+ ar & n_cells & fe_name & policy_name;
+
+ AssertThrow (n_cells == tria->n_cells(),
ExcMessage ("The object being loaded into does not match the triangulation "
"that has been stored previously."));
AssertThrow (fe_name == selected_fe->get_name(),
* of this object.
*/
std::size_t memory_consumption () const;
-
+
/**
- * Read or write the data of this object to or
+ * Read or write the data of this object to or
* from a stream for the purpose of serialization
- */
+ */
template <class Archive>
- void serialize (Archive & ar,
+ void serialize (Archive & ar,
const unsigned int version);
};
std::size_t memory_consumption () const;
/**
- * Read or write the data of this object to or
+ * Read or write the data of this object to or
* from a stream for the purpose of serialization
- */
+ */
template <class Archive>
- void serialize (Archive & ar,
+ void serialize (Archive & ar,
const unsigned int version);
};
std::size_t memory_consumption () const;
/**
- * Read or write the data of this object to or
+ * Read or write the data of this object to or
* from a stream for the purpose of serialization
- */
+ */
template <class Archive>
- void serialize (Archive & ar,
+ void serialize (Archive & ar,
const unsigned int version);
};
}
template <int,int,int> friend class TriaAccessor;
friend class CellAccessor<dim, spacedim>;
- friend class internal::TriaAccessor::Implementation;
+ friend struct internal::TriaAccessor::Implementation;
friend class hp::DoFHandler<dim,spacedim>;
- friend class internal::Triangulation::Implementation;
+ friend struct internal::Triangulation::Implementation;
};
namespace Triangulation
{
template <class Archive>
- void NumberCache<1>::serialize (Archive & ar,
+ void NumberCache<1>::serialize (Archive & ar,
const unsigned int)
{
ar & n_levels;
ar & n_active_lines & n_active_lines_level;
}
-
+
template <class Archive>
- void NumberCache<2>::serialize (Archive & ar,
+ void NumberCache<2>::serialize (Archive & ar,
const unsigned int version)
{
this->NumberCache<1>::serialize (ar, version);
-
+
ar & n_quads & n_quads_level;
ar & n_active_quads & n_active_quads_level;
}
-
+
template <class Archive>
- void NumberCache<3>::serialize (Archive & ar,
+ void NumberCache<3>::serialize (Archive & ar,
const unsigned int version)
{
this->NumberCache<2>::serialize (ar, version);
-
+
ar & n_hexes & n_hexes_level;
ar & n_active_hexes & n_active_hexes_level;
}
-
+
}
}
template <int dim, int spacedim>
template <class Archive>
void
-Triangulation<dim,spacedim>::save (Archive & ar,
+Triangulation<dim,spacedim>::save (Archive & ar,
const unsigned int) const
{
// as discussed in the documentation, do
ar & faces;
ar & vertices;
ar & vertices_used;
-
+
ar & anisotropic_refinement;
ar & number_cache;
template <int dim, int spacedim>
template <class Archive>
void
-Triangulation<dim,spacedim>::load (Archive & ar,
+Triangulation<dim,spacedim>::load (Archive & ar,
const unsigned int)
{
// clear previous content. this also calls
// the respective signal
clear ();
-
+
// as discussed in the documentation, do
// not store the signals as well as
// boundary and manifold descrption
ar & faces;
ar & vertices;
ar & vertices_used;
-
+
ar & anisotropic_refinement;
ar & number_cache;
template <int, int> friend class Triangulation;
- friend class internal::Triangulation::Implementation;
- friend class internal::TriaAccessor::Implementation;
+ friend struct internal::Triangulation::Implementation;
+ friend struct internal::TriaAccessor::Implementation;
};
* refers to.
*/
Point<spacedim> center () const;
-
+
/**
* Pointer to the @p ith line
* bounding this object. Will
template <int, int> friend class Triangulation;
- friend class internal::Triangulation::Implementation;
-
+ friend struct internal::Triangulation::Implementation;
};
void create_active_fe_table ();
/**
- * Functions that will be triggered
- * through signals whenever the
+ * Functions that will be triggered
+ * through signals whenever the
* triangulation is modified.
- *
+ *
* Here they are used to
* administrate the the
* active_fe_fields during the
*/
void pre_refinement_action ();
void post_refinement_action ();
-
+
/**
* Compute identities between
* triangulation changes.
*/
std::vector<boost::signals2::connection> tria_listeners;
-
+
/**
* Make accessor objects friends.
*/
template <int, class> friend class dealii::DoFAccessor;
template <class> friend class dealii::DoFCellAccessor;
- friend class internal::DoFAccessor::Implementation;
- friend class internal::DoFCellAccessor::Implementation;
+ friend struct internal::DoFAccessor::Implementation;
+ friend struct internal::DoFCellAccessor::Implementation;
/**
* Likewise for DoFLevel
*/
template <int> friend class internal::hp::DoFLevel;
template <int> friend class internal::hp::DoFObjects;
- friend class internal::hp::DoFHandler::Implementation;
+ friend struct internal::hp::DoFHandler::Implementation;
};