phylopomp
Phylodynamics for POMPs
|
Encodes a genealogical node. More...
#include <node.h>
Public Member Functions | |
size_t | bytesize (void) const |
size of binary serialization More... | |
node_t (name_t u=0, slate_t t=R_NaReal) | |
basic constructor for node class More... | |
node_t (const node_t &p)=delete | |
copy constructor More... | |
node_t (node_t &&p)=delete | |
move constructor More... | |
node_t & | operator= (const node_t &p)=delete |
copy assignment operator More... | |
node_t & | operator= (node_t &&p)=delete |
move assignment operator More... | |
~node_t (void) | |
destructor More... | |
ball_t * | green_ball (void) const |
pointer to my green ball More... | |
ball_t *& | green_ball (void) |
set green ball More... | |
name_t | deme (void) const |
view deme More... | |
name_t & | deme (void) |
set deme More... | |
name_t | lineage (void) const |
view lineage More... | |
name_t | lineage (const ball_t *g) const |
view lineage associated with a green ball More... | |
name_t & | lineage (void) |
set lineage More... | |
node_t * | parent (void) const |
bool | holds_own (void) const |
bool | is_root (void) const |
bool | dead_root (void) const |
int | nchildren (void) const |
number of descendants More... | |
void | lineage_incr (int *incr, int *sat, int *etype) const |
std::string | describe (void) const |
human-readable info More... | |
std::string | yaml (std::string tab="") const |
machine-readable info More... | |
SEXP | structure (void) const |
R list description. More... | |
std::string | newick (const slate_t &tnow, const slate_t &tpar) const |
Newick format. More... | |
Public Member Functions inherited from pocket_t | |
size_t | bytesize (void) const |
size of binary serialization More... | |
void | repair_owners (const std::unordered_map< name_t, node_t * > &node_name, std::unordered_map< name_t, ball_t * > *ball_name) |
~pocket_t (void) | |
destructor More... | |
bool | holds (ball_t *b) const |
does this node hold the given ball? More... | |
bool | holds (color_t c) const |
does this node hold a ball of this color? More... | |
ball_t * | last_ball (void) const |
retrieve the last ball More... | |
ball_t * | ball (const color_t c) const |
retrieve the first ball of the specified color. More... | |
ball_t * | other (const ball_t *b) const |
return a pointer to another ball More... | |
std::string | describe (void) const |
human-readable info More... | |
SEXP | structure (void) const |
R list description. More... | |
std::string | yaml (std::string tab="") const |
human/machine-readable info More... | |
Data Fields | |
name_t | uniq |
slate_t | slate |
Private Member Functions | |
void | clean (void) |
Private Attributes | |
ball_t * | _green_ball |
name_t | _lineage |
Friends | |
raw_t * | operator>> (const node_t &p, raw_t *o) |
binary serialization of node_t More... | |
raw_t * | operator>> (raw_t *o, node_t &p) |
binary deserialization of node_t More... | |
Additional Inherited Members | |
Protected Member Functions inherited from pocket_t | |
void | repair_holder (node_t *p) |
Encodes a genealogical node.
Each node has:
|
delete |
copy constructor
|
delete |
move constructor
|
inline |
|
inline |
|
inlineprivate |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
lineage count, saturation, and event-type types are:
Definition at line 151 of file node.h.
|
inline |
Newick format.
Definition at line 215 of file node.h.
|
inline |
|
inline |
R list description.
Definition at line 202 of file node.h.
|
inline |
machine-readable info
Definition at line 190 of file node.h.
binary serialization of node_t