39#include <boost/utility.hpp>
40#include <boost/shared_ptr.hpp>
41#include <boost/enable_shared_from_this.hpp>
44#include <boost/serialization/shared_ptr.hpp>
46#include "AbstractCellMutationState.hpp"
47#include "AbstractCellProliferativeType.hpp"
48#include "CellData.hpp"
49#include "CellVecData.hpp"
50#include "CellEdgeData.hpp"
53#include "AbstractCellCycleModel.hpp"
54#include "AbstractSrnModel.hpp"
55#include "CellPropertyCollection.hpp"
62typedef boost::shared_ptr<Cell> CellPtr;
91class Cell :
private boost::noncopyable,
public boost::enable_shared_from_this<Cell>
103 template<
class Archive>
104 void serialize(Archive & archive,
const unsigned int version)
171 Cell(boost::shared_ptr<AbstractCellProperty> pMutationState,
174 bool archiving=
false,
300 void SetMutationState(boost::shared_ptr<AbstractCellProperty> pMutationState);
320 void AddCellProperty(
const boost::shared_ptr<AbstractCellProperty>& rProperty);
329 template<
typename CLASS>
332 bool cell_has_property =
false;
338 if ((*property_iter)->IsType<CLASS>())
340 cell_has_property =
true;
341 (*property_iter)->DecrementCellCount();
346 if (cell_has_property)
356 template<
typename CLASS>
420 void SetAncestor(boost::shared_ptr<AbstractCellProperty> pCellAncestor);
445namespace serialization
450template<
class Archive>
451inline void save_construct_data(
452 Archive & ar,
const Cell * t,
const unsigned int file_version)
455 const boost::shared_ptr<AbstractCellMutationState> p_mutation_state = t->GetMutationState();
456 ar & p_mutation_state;
458 ar & p_cell_cycle_model;
462 ar & r_cell_property_collection;
468template<
class Archive>
469inline void load_construct_data(
470 Archive & ar,
Cell * t,
const unsigned int file_version)
473 boost::shared_ptr<AbstractCellMutationState> p_mutation_state;
474 ar & p_mutation_state;
477 ar & p_cell_cycle_model;
482 bool archiving =
true;
485 ar & cell_property_collection;
488 ::new(t)
Cell(p_mutation_state, p_cell_cycle_model, p_srn_model, archiving, cell_property_collection);
gcov doesn't like this file...
#define CHASTE_CLASS_EXPORT(T)
bool HasProperty(const boost::shared_ptr< AbstractCellProperty > &rProp) const
unsigned GetCellId() const
AbstractSrnModel * GetSrnModel() const
AbstractCellCycleModel * GetCellCycleModel() const
void InitialiseSrnModel()
void RemoveCellProperty()
AbstractSrnModel * mpSrnModel
AbstractCellCycleModel * mpCellCycleModel
bool HasCellVecData() const
void SetSrnModel(AbstractSrnModel *pSrnModel)
double mStartOfApoptosisTime
double GetBirthTime() const
double GetStartOfApoptosisTime() const
void AddCellProperty(const boost::shared_ptr< AbstractCellProperty > &rProperty)
void SetBirthTime(double birthTime)
boost::shared_ptr< AbstractCellProliferativeType > GetCellProliferativeType() const
CellPropertyCollection mCellPropertyCollection
bool mUndergoingApoptosis
void SetCellCycleModel(AbstractCellCycleModel *pCellCycleModel)
boost::shared_ptr< CellData > GetCellData() const
bool HasCellProperty() const
bool HasApoptosisBegun() const
unsigned GetAncestor() const
boost::shared_ptr< CellVecData > GetCellVecData() const
void serialize(Archive &archive, const unsigned int version)
void SetApoptosisTime(double apoptosisTime)
double GetApoptosisTime() const
CellPropertyCollection & rGetCellPropertyCollection()
friend class boost::serialization::access
boost::shared_ptr< CellEdgeData > GetCellEdgeData() const
void SetMutationState(boost::shared_ptr< AbstractCellProperty > pMutationState)
void SetCellProliferativeType(boost::shared_ptr< AbstractCellProperty > pProliferativeType)
void SetAncestor(boost::shared_ptr< AbstractCellProperty > pCellAncestor)
void StartApoptosis(bool setDeathTime=true)
double GetTimeUntilDeath() const
void InitialiseCellCycleModel()
boost::shared_ptr< AbstractCellMutationState > GetMutationState() const
void operator()(void const *) const