#include <TissueCell.hpp>
Public Member Functions | |
TissueCell (CellType cellType, CellMutationState mutationState, AbstractCellCycleModel *pCellCycleModel, bool archiving=false) | |
~TissueCell () | |
TissueCell (const TissueCell &otherCell) | |
TissueCell & | operator= (const TissueCell &otherCell) |
void | SetBirthTime (double birthTime) |
void | SetCellCycleModel (AbstractCellCycleModel *pCellCycleModel) |
AbstractCellCycleModel * | GetCellCycleModel () const |
void | InitialiseCellCycleModel () |
double | GetAge () const |
double | GetBirthTime () const |
CellType | GetCellType () const |
void | SetCellType (CellType cellType) |
CellMutationState | GetMutationState () const |
void | SetMutationState (CellMutationState mutationState) |
bool | ReadyToDivide () |
TissueCell | Divide () |
void | StartApoptosis () |
void | Kill () |
bool | HasApoptosisBegun () const |
double | TimeUntilDeath () const |
bool | IsDead () const |
void | SetLogged () |
bool | IsLogged () |
void | SetAncestor (unsigned ancestorIndex) |
unsigned | GetAncestor () const |
Protected Member Functions | |
void | CommonCopy (const TissueCell &otherCell) |
Protected Attributes | |
CellType | mCellType |
CellMutationState | mMutationState |
AbstractCellCycleModel * | mpCellCycleModel |
unsigned | mAncestor |
double | mDeathTime |
bool | mUndergoingApoptosis |
bool | mIsDead |
bool | mIsLogged |
Private Member Functions | |
template<class Archive> | |
void | serialize (Archive &archive, const unsigned int version) |
Private Attributes | |
bool | mCanDivide |
Friends | |
class | boost::serialization::access |
This class should not store any spatial information - TissueCells are linked to space by the Tissue classes.
Definition at line 50 of file TissueCell.hpp.
TissueCell::TissueCell | ( | CellType | cellType, | |
CellMutationState | mutationState, | |||
AbstractCellCycleModel * | pCellCycleModel, | |||
bool | archiving = false | |||
) |
Create a new tissue cell.
cellType | the type of cell this is | |
mutationState | the mutation state of the cell | |
pCellCycleModel | the cell cycle model to use to decide when the cell divides. This MUST be allocated using new, and will be deleted when the cell is destroyed. | |
archiving | whether this constructor is being called by the archiver - do things slightly differently! |
Definition at line 31 of file TissueCell.cpp.
References SimulationTime::Instance(), mAncestor, mCanDivide, mCellType, mDeathTime, mIsDead, mIsLogged, mMutationState, mpCellCycleModel, mUndergoingApoptosis, and AbstractCellCycleModel::SetCell().
Referenced by Divide().
TissueCell::~TissueCell | ( | ) |
Destructor, which frees the memory allocated for our cell cycle model.
Definition at line 102 of file TissueCell.cpp.
References mpCellCycleModel.
TissueCell::TissueCell | ( | const TissueCell & | otherCell | ) |
Create a new tissue cell that is a copy of an existing cell
otherCell | An existing TissueCell |
Definition at line 85 of file TissueCell.cpp.
References CommonCopy().
void TissueCell::serialize | ( | Archive & | archive, | |
const unsigned int | version | |||
) | [inline, private] |
Archive the member variables.
archive | ||
version |
Definition at line 66 of file TissueCell.hpp.
References mAncestor, mCanDivide, mCellType, mDeathTime, mIsDead, mIsLogged, mMutationState, mpCellCycleModel, and mUndergoingApoptosis.
void TissueCell::CommonCopy | ( | const TissueCell & | otherCell | ) | [protected] |
Contains code common to both the copy constructor and operator=.
otherCell | An existing TissueCell |
Definition at line 60 of file TissueCell.cpp.
References AbstractCellCycleModel::CreateCellCycleModel(), mAncestor, mCanDivide, mCellType, mDeathTime, mIsDead, mIsLogged, mMutationState, mpCellCycleModel, mUndergoingApoptosis, and AbstractCellCycleModel::SetCell().
Referenced by operator=(), and TissueCell().
TissueCell & TissueCell::operator= | ( | const TissueCell & | otherCell | ) |
Copy all the attributes of one cell to another.
otherCell | An existing TissueCell |
Definition at line 91 of file TissueCell.cpp.
References CommonCopy(), and mpCellCycleModel.
void TissueCell::SetBirthTime | ( | double | birthTime | ) |
Set the birth time of the cell - can be negative so that your cells have an age when a simulation begins
birthTime | The time the cell was born (in hours) |
Definition at line 142 of file TissueCell.cpp.
References mpCellCycleModel, and AbstractCellCycleModel::SetBirthTime().
Referenced by FixedDurationGenerationBasedCellCycleModelCellsGenerator< DIM >::GenerateBasic(), AbstractCellsGenerator< DIM >::GenerateForCrypt(), and FixedDurationGenerationBasedCellCycleModelCellsGenerator< DIM >::GenerateGivenLocationIndices().
void TissueCell::SetCellCycleModel | ( | AbstractCellCycleModel * | pCellCycleModel | ) |
Change the cell cycle model used. This takes effect immediately.
pCellCycleModel | pointer to the cell cycle model to use |
Definition at line 108 of file TissueCell.cpp.
References mpCellCycleModel, and AbstractCellCycleModel::SetCell().
AbstractCellCycleModel * TissueCell::GetCellCycleModel | ( | ) | const |
Returns a pointer to the TissueCell's cell cycle model.
Definition at line 119 of file TissueCell.cpp.
References mpCellCycleModel.
Referenced by MeshBasedTissue< DIM >::CheckTissueCellPointers(), Divide(), AbstractTissue< DIM >::GenerateCellResults(), and LinearSpringWithVariableSpringConstantsForce< DIM >::VariableSpringConstantMultiplicationFactor().
void TissueCell::InitialiseCellCycleModel | ( | ) |
Calls Initialise on the cell cycle model associated with this cell.
Definition at line 125 of file TissueCell.cpp.
References AbstractCellCycleModel::Initialise(), and mpCellCycleModel.
Referenced by AbstractCellsGenerator< DIM >::GenerateForCrypt().
double TissueCell::GetAge | ( | ) | const |
Get the cell's age from its cell cycle model.
Definition at line 130 of file TissueCell.cpp.
References AbstractCellCycleModel::GetAge(), and mpCellCycleModel.
Referenced by GeneralisedLinearSpringForce< DIM >::CalculateForceBetweenNodes().
double TissueCell::GetBirthTime | ( | ) | const |
Get the cell's birth time from its cell cycle model.
Definition at line 136 of file TissueCell.cpp.
References AbstractCellCycleModel::GetBirthTime(), and mpCellCycleModel.
CellType TissueCell::GetCellType | ( | ) | const |
Get method for mCellType.
Definition at line 154 of file TissueCell.cpp.
References mCellType.
Referenced by AbstractTissue< DIM >::GenerateCellResults(), TysonNovakCellCycleModel::InitialiseDaughterCell(), AbstractSimpleGenerationBasedCellCycleModel::ResetForDivision(), StochasticDurationGenerationBasedCellCycleModel::SetG1Duration(), SimpleWntCellCycleModel::SetG1Duration(), AbstractSimpleCellCycleModel::SetG1Duration(), AbstractSimpleCellCycleModel::UpdateCellCyclePhase(), and LinearSpringWithVariableSpringConstantsForce< DIM >::VariableSpringConstantMultiplicationFactor().
void TissueCell::SetCellType | ( | CellType | cellType | ) |
Set method for mCellType.
cellType |
Definition at line 148 of file TissueCell.cpp.
References mCellType.
Referenced by WntCellCycleModel::ChangeCellTypeDueToCurrentBetaCateninLevel(), IngeWntSwatCellCycleModel::ChangeCellTypeDueToCurrentBetaCateninLevel(), TysonNovakCellCycleModel::InitialiseDaughterCell(), SimpleWntCellCycleModel::InitialiseDaughterCell(), AbstractSimpleGenerationBasedCellCycleModel::InitialiseDaughterCell(), AbstractSimpleGenerationBasedCellCycleModel::ResetForDivision(), and SimpleWntCellCycleModel::UpdateCellCyclePhase().
CellMutationState TissueCell::GetMutationState | ( | ) | const |
Get method for mMutationState.
Definition at line 166 of file TissueCell.cpp.
References mMutationState.
Referenced by WntCellCycleModel::CreateDaughterCellCycleModel(), StochasticWntCellCycleModel::CreateDaughterCellCycleModel(), IngeWntSwatCellCycleModel::CreateDaughterCellCycleModel(), AbstractTissue< DIM >::GenerateCellResults(), WntCellCycleModel::Initialise(), IngeWntSwatCellCycleModel::Initialise(), WntCellCycleModel::SolveOdeToTime(), IngeWntSwatCellCycleModel::SolveOdeToTime(), SimpleWntCellCycleModel::UpdateCellCyclePhase(), and LinearSpringWithVariableSpringConstantsForce< DIM >::VariableSpringConstantMultiplicationFactor().
void TissueCell::SetMutationState | ( | CellMutationState | mutationState | ) |
Set method for mMutationState.
mutationState |
Definition at line 160 of file TissueCell.cpp.
References mMutationState.
bool TissueCell::ReadyToDivide | ( | ) |
Determine if this cell is ready to divide at the current simulation time. MUST be called before calling Divide().
Definition at line 240 of file TissueCell.cpp.
References IsDead(), mCanDivide, mCellType, mpCellCycleModel, mUndergoingApoptosis, and AbstractCellCycleModel::ReadyToDivide().
TissueCell TissueCell::Divide | ( | ) |
Divide this cell to produce a daughter cell. ReadyToDivide MUST have been called at the current time, and returned true.
Definition at line 254 of file TissueCell.cpp.
References AbstractCellCycleModel::CreateDaughterCellCycleModel(), GetAncestor(), GetCellCycleModel(), AbstractCellCycleModel::InitialiseDaughterCell(), IsDead(), mCanDivide, mCellType, mMutationState, mpCellCycleModel, AbstractCellCycleModel::ResetForDivision(), SetAncestor(), and TissueCell().
void TissueCell::StartApoptosis | ( | ) |
Makes the cell enter apoptosis and sets mDeathTime using the apoptosis time from the cancer parameters.
Definition at line 184 of file TissueCell.cpp.
References CancerParameters::GetApoptosisTime(), SimulationTime::GetTime(), CancerParameters::Instance(), SimulationTime::Instance(), IsDead(), mDeathTime, and mUndergoingApoptosis.
Referenced by RandomCellKiller< SPACE_DIM >::TestAndLabelSingleCellForApoptosis().
void TissueCell::Kill | ( | ) |
This labels the cell as dead, it does not delete the cell, it remains in the Tissue until AbstractTissue::RemoveDeadCells() is called.
Definition at line 222 of file TissueCell.cpp.
References mIsDead.
bool TissueCell::HasApoptosisBegun | ( | ) | const |
Returns whether the cell is undergoing apoptosis or not.
Definition at line 199 of file TissueCell.cpp.
References mUndergoingApoptosis.
Referenced by GeneralisedLinearSpringForce< DIM >::CalculateForceBetweenNodes(), AbstractTissue< DIM >::GenerateCellResults(), and RandomCellKiller< SPACE_DIM >::TestAndLabelSingleCellForApoptosis().
double TissueCell::TimeUntilDeath | ( | ) | const |
Definition at line 205 of file TissueCell.cpp.
References SimulationTime::GetTime(), SimulationTime::Instance(), mDeathTime, and mUndergoingApoptosis.
Referenced by GeneralisedLinearSpringForce< DIM >::CalculateForceBetweenNodes().
bool TissueCell::IsDead | ( | ) | const |
Return whether the cell is dead or undergoing apoptosis.
Definition at line 216 of file TissueCell.cpp.
References SimulationTime::Instance(), mDeathTime, mIsDead, and mUndergoingApoptosis.
Referenced by MeshBasedTissue< DIM >::CheckTissueCellPointers(), Divide(), ReadyToDivide(), and StartApoptosis().
void TissueCell::SetLogged | ( | ) |
Sets a flag to perform special output on this cell only.
Definition at line 172 of file TissueCell.cpp.
References mIsLogged.
bool TissueCell::IsLogged | ( | ) |
Definition at line 178 of file TissueCell.cpp.
References mIsLogged.
void TissueCell::SetAncestor | ( | unsigned | ancestorIndex | ) |
Give the TissueCell an index which it passes to its children.
ancestorIndex |
Definition at line 228 of file TissueCell.cpp.
References mAncestor.
Referenced by Divide().
unsigned TissueCell::GetAncestor | ( | ) | const |
Definition at line 234 of file TissueCell.cpp.
References mAncestor.
Referenced by Divide(), and AbstractTissue< DIM >::GenerateCellResults().
friend class boost::serialization::access [friend] |
Needed for serialization.
Definition at line 58 of file TissueCell.hpp.
bool TissueCell::mCanDivide [private] |
Caches the result of ReadyToDivide() so Divide() can look at it.
Definition at line 55 of file TissueCell.hpp.
Referenced by CommonCopy(), Divide(), ReadyToDivide(), serialize(), and TissueCell().
CellType TissueCell::mCellType [protected] |
The cell type - defined in CellTypes.hpp
Definition at line 87 of file TissueCell.hpp.
Referenced by CommonCopy(), Divide(), GetCellType(), ReadyToDivide(), serialize(), SetCellType(), and TissueCell().
CellMutationState TissueCell::mMutationState [protected] |
The cell's mutation state - defined in CellMutationStates.hpp
Definition at line 90 of file TissueCell.hpp.
Referenced by CommonCopy(), Divide(), GetMutationState(), serialize(), SetMutationState(), and TissueCell().
AbstractCellCycleModel* TissueCell::mpCellCycleModel [protected] |
The cell's cell-cycle model
Definition at line 93 of file TissueCell.hpp.
Referenced by CommonCopy(), Divide(), GetAge(), GetBirthTime(), GetCellCycleModel(), InitialiseCellCycleModel(), operator=(), ReadyToDivide(), serialize(), SetBirthTime(), SetCellCycleModel(), TissueCell(), and ~TissueCell().
unsigned TissueCell::mAncestor [protected] |
An index which is inherited by all children of this cell
Definition at line 96 of file TissueCell.hpp.
Referenced by CommonCopy(), GetAncestor(), serialize(), SetAncestor(), and TissueCell().
double TissueCell::mDeathTime [protected] |
When the cell will/did die
Definition at line 99 of file TissueCell.hpp.
Referenced by CommonCopy(), IsDead(), serialize(), StartApoptosis(), TimeUntilDeath(), and TissueCell().
bool TissueCell::mUndergoingApoptosis [protected] |
Whether the cell is currently in apoptosis - don't divide
Definition at line 102 of file TissueCell.hpp.
Referenced by CommonCopy(), HasApoptosisBegun(), IsDead(), ReadyToDivide(), serialize(), StartApoptosis(), TimeUntilDeath(), and TissueCell().
bool TissueCell::mIsDead [protected] |
Whether the cell is dead or not (they exist in the Tissue until they are removed by AbstractTissue::RemoveDeadCells()
Definition at line 105 of file TissueCell.hpp.
Referenced by CommonCopy(), IsDead(), Kill(), serialize(), and TissueCell().
bool TissueCell::mIsLogged [protected] |
Whether the cell is being tracked specially.
Definition at line 108 of file TissueCell.hpp.
Referenced by CommonCopy(), IsLogged(), serialize(), SetLogged(), and TissueCell().