37 #ifndef CHASTENODESLIST_HPP_
38 #define CHASTENODESLIST_HPP_
41 #include <boost/serialization/base_object.hpp>
43 #include "AbstractChasteRegion.hpp"
45 #include "ChastePoint.hpp"
53 template <
unsigned SPACE_DIM>
57 friend class boost::serialization::access;
64 template<
class Archive>
65 void serialize(Archive & archive,
const unsigned int version)
67 archive & boost::serialization::base_object<AbstractChasteRegion<SPACE_DIM> >(*this);
95 const std::vector< Node<SPACE_DIM>*>& rGetNodesList()
const;
107 unsigned GetSize()
const;
117 namespace serialization
120 template<
class Archive,
unsigned SPACE_DIM>
121 inline void save_construct_data(
124 const std::vector<Node<SPACE_DIM>* > node_list = t->
rGetNodesList();
131 std::vector <ChastePoint<SPACE_DIM>* > point_list;
133 for (
unsigned i = 0; i < node_list.size(); i++)
135 c_vector<double, SPACE_DIM> loc = node_list[i]->rGetLocation();
138 unsigned index = node_list[i]->GetIndex();
143 for (
unsigned i = 0; i < point_list.size(); i++)
145 delete point_list[i];
153 template<
class Archive,
unsigned SPACE_DIM>
154 inline void load_construct_data(
162 std::vector<Node<SPACE_DIM>* > node_list;
163 for (
unsigned i = 0; i < size; i++)
171 node_list.push_back(p_node);
void serialize(Archive &archive, const unsigned int version)
#define EXPORT_TEMPLATE_CLASS_SAME_DIMS(CLASS)
const std::vector< Node< SPACE_DIM > * > & rGetNodesList() const
std::vector< Node< SPACE_DIM > * > mListOfNodes