#include <boost/shared_ptr.hpp>
+//TODO[WB]: The conversion constructor should really be 'explicit'
+
namespace hp
{
/**
*/
MappingCollection (const Mapping<dim> &mapping);
+ /**
+ * Copy constructor.
+ */
+ MappingCollection (const MappingCollection<dim> &mapping_collection);
+
/**
* Adds a new mapping to the
* MappingCollection. The
template <int dim>
MappingCollection<dim>::MappingCollection ()
- {
- }
+ {}
+
template <int dim>
- MappingCollection<dim>::MappingCollection (const Mapping<dim> &mapping)
+ MappingCollection<dim>::
+ MappingCollection (const Mapping<dim> &mapping)
{
mappings
.push_back (boost::shared_ptr<const Mapping<dim> >(mapping.clone()));
}
+
+ template <int dim>
+ MappingCollection<dim>::
+ MappingCollection (const MappingCollection<dim> &mapping_collection)
+ :
+ Subscriptor (),
+ // copy the array
+ // of shared
+ // pointers. nothing
+ // bad should
+ // happen -- they
+ // simply all point
+ // to the same
+ // objects, and the
+ // last one to die
+ // will delete the
+ // mappings
+ mappings (mapping_collection.mappings)
+ {}
+
+
+
template <int dim>
inline
const Mapping<dim> &
In the beginning the Universe was created. This has made a lot of
people very angry and has been widely regarded as a bad move.
Douglas Adams