Skip to content

Class Virus

template <typename TSeq>

ClassList > Virus

Virus .More...

  • #include <virus-bones.hpp>

Public Functions

Type Name
EPI_TYPENAME_TRAITS (TSeq, int)
Virus ()
Virus (std::string name="unknown virus")
Virus (std::string name, epiworld_double prevalence, bool as_proportion)
virtual std::unique_ptr< Virus< TSeq > > clone_ptr () const
void distribute (Model< TSeq > * model)
Get information about the prevalence of the virus.
Agent< TSeq > * get_agent ()
int get_date () const
int get_id () const
epiworld_double get_incubation (Model< TSeq > * model)
std::string get_name () const
epiworld_double get_prob_death (Model< TSeq > * model)
epiworld_double get_prob_infecting (Model< TSeq > * model)
epiworld_double get_prob_recovery (Model< TSeq > * model)
void get_queue (epiworld_fast_int * init, epiworld_fast_int * end, epiworld_fast_int * removed=nullptr) const
void get_state (epiworld_fast_int * init, epiworld_fast_int * end, epiworld_fast_int * removed=nullptr) const
void mutate (Model< TSeq > * model)
bool operator!= (const Virus< TSeq > & other) const
bool operator== (const Virus< TSeq > & other) const
bool operator== (const Virus< std::vector< int > > & other) const
void post_recovery (Model< TSeq > * model)
void print () const
void set_agent (Agent< TSeq > * p)
void set_date (int d)
void set_distribution (VirusToAgentFun< TSeq > fun)
void set_id (int idx)
void set_incubation (std::string param)
void set_incubation (epiworld_double * prob) = delete
void set_incubation (epiworld_double prob)
void set_incubation_fun (VirusFun< TSeq > fun)
void set_mutation (MutFun< TSeq > fun)
void set_name (std::string name)
void set_post_immunity (epiworld_double prob)
void set_post_immunity (std::string param)
void set_post_immunity (epiworld_double * prob) = delete
void set_post_recovery (PostRecoveryFun< TSeq > fun)
void set_prob_death (std::string param)
void set_prob_death (epiworld_double * prob) = delete
void set_prob_death (epiworld_double prob)
void set_prob_death_fun (VirusFun< TSeq > fun)
void set_prob_infecting (std::string param)
void set_prob_infecting (epiworld_double * prob) = delete
void set_prob_infecting (epiworld_double prob)
void set_prob_infecting_fun (VirusFun< TSeq > fun)
void set_prob_recovery (std::string param)
void set_prob_recovery (epiworld_double * prob) = delete
void set_prob_recovery (epiworld_double prob)
void set_prob_recovery_fun (VirusFun< TSeq > fun)
void set_queue (epiworld_fast_int init, epiworld_fast_int end, epiworld_fast_int removed=-99)
void set_sequence (TSeq sequence)
void set_sequence (int sequence)
void set_state (epiworld_fast_int init, epiworld_fast_int end, epiworld_fast_int removed=-99)
virtual ~Virus () = default

Detailed Description

Template parameters:

  • TSeq

Raw transmisibility of a virus should be a function of its genetic sequence. Nonetheless, transmisibility can be reduced as a result of having one or more tools to fight the virus. Because of this, transmisibility should be a function of the agent.

Public Functions Documentation

function EPI_TYPENAME_TRAITS [2/2]

Virus::EPI_TYPENAME_TRAITS (
    TSeq,
    int
) 

function Virus [1/3]

inline Virus::Virus () 

function Virus [2/3]

inline Virus::Virus (
    std::string name="unknown virus"
) 

function Virus [3/3]

inline Virus::Virus (
    std::string name,
    epiworld_double prevalence,
    bool as_proportion
) 

function clone_ptr

inline virtual std::unique_ptr< Virus < TSeq > > Virus::clone_ptr () const

function distribute

Get information about the prevalence of the virus.

inline void Virus::distribute (
    Model < TSeq > * model
) 


function get_agent

inline Agent < TSeq > * Virus::get_agent () 

function get_date

inline int Virus::get_date () const

function get_id

inline int Virus::get_id () const

function get_incubation

inline epiworld_double Virus::get_incubation (
    Model < TSeq > * model
) 

function get_name

inline std::string Virus::get_name () const

function get_prob_death

inline epiworld_double Virus::get_prob_death (
    Model < TSeq > * model
) 

function get_prob_infecting

inline epiworld_double Virus::get_prob_infecting (
    Model < TSeq > * model
) 

function get_prob_recovery

inline epiworld_double Virus::get_prob_recovery (
    Model < TSeq > * model
) 

function get_queue

inline void Virus::get_queue (
    epiworld_fast_int * init,
    epiworld_fast_int * end,
    epiworld_fast_int * removed=nullptr
) const

function get_state

inline void Virus::get_state (
    epiworld_fast_int * init,
    epiworld_fast_int * end,
    epiworld_fast_int * removed=nullptr
) const

function mutate

inline void Virus::mutate (
    Model < TSeq > * model
) 

function operator!=

inline bool Virus::operator!= (
    const Virus < TSeq > & other
) const

function operator==

inline bool Virus::operator== (
    const Virus < TSeq > & other
) const

function operator==

inline bool Virus::operator== (
    const Virus < std::vector< int > > & other
) const

function post_recovery

inline void Virus::post_recovery (
    Model < TSeq > * model
) 

function print

inline void Virus::print () const

function set_agent

inline void Virus::set_agent (
    Agent < TSeq > * p
) 

function set_date

inline void Virus::set_date (
    int d
) 

function set_distribution

inline void Virus::set_distribution (
    VirusToAgentFun < TSeq > fun
) 

function set_id

inline void Virus::set_id (
    int idx
) 

function set_incubation [1/3]

inline void Virus::set_incubation (
    std::string param
) 

function set_incubation [2/3]

void Virus::set_incubation (
    epiworld_double * prob
) = delete

function set_incubation [3/3]

inline void Virus::set_incubation (
    epiworld_double prob
) 

function set_incubation_fun

inline void Virus::set_incubation_fun (
    VirusFun < TSeq > fun
) 

function set_mutation

inline void Virus::set_mutation (
    MutFun < TSeq > fun
) 

function set_name

inline void Virus::set_name (
    std::string name
) 

function set_post_immunity [1/3]

inline void Virus::set_post_immunity (
    epiworld_double prob
) 

function set_post_immunity [2/3]

inline void Virus::set_post_immunity (
    std::string param
) 

function set_post_immunity [3/3]

void Virus::set_post_immunity (
    epiworld_double * prob
) = delete

function set_post_recovery

inline void Virus::set_post_recovery (
    PostRecoveryFun < TSeq > fun
) 

function set_prob_death [1/3]

inline void Virus::set_prob_death (
    std::string param
) 

function set_prob_death [2/3]

void Virus::set_prob_death (
    epiworld_double * prob
) = delete

function set_prob_death [3/3]

inline void Virus::set_prob_death (
    epiworld_double prob
) 

function set_prob_death_fun

inline void Virus::set_prob_death_fun (
    VirusFun < TSeq > fun
) 

function set_prob_infecting [1/3]

inline void Virus::set_prob_infecting (
    std::string param
) 

function set_prob_infecting [2/3]

void Virus::set_prob_infecting (
    epiworld_double * prob
) = delete

function set_prob_infecting [3/3]

inline void Virus::set_prob_infecting (
    epiworld_double prob
) 

function set_prob_infecting_fun

inline void Virus::set_prob_infecting_fun (
    VirusFun < TSeq > fun
) 

function set_prob_recovery [1/3]

inline void Virus::set_prob_recovery (
    std::string param
) 

function set_prob_recovery [2/3]

void Virus::set_prob_recovery (
    epiworld_double * prob
) = delete

function set_prob_recovery [3/3]

inline void Virus::set_prob_recovery (
    epiworld_double prob
) 

function set_prob_recovery_fun

inline void Virus::set_prob_recovery_fun (
    VirusFun < TSeq > fun
) 

function set_queue

inline void Virus::set_queue (
    epiworld_fast_int init,
    epiworld_fast_int end,
    epiworld_fast_int removed=-99
) 

function set_sequence [1/2]

inline void Virus::set_sequence (
    TSeq sequence
) 

function set_sequence [2/2]

inline void Virus::set_sequence (
    int sequence
) 

function set_state

inline void Virus::set_state (
    epiworld_fast_int init,
    epiworld_fast_int end,
    epiworld_fast_int removed=-99
) 

function ~Virus

virtual Virus::~Virus () = default


The documentation for this class was generated from the following file epiworld-src/include/epiworld/virus-bones.hpp