Gadget
Public Member Functions | Protected Attributes | List of all members
LikelihoodPtrVector Class Reference

This class implements a dynamic vector of Likelihood values. More...

#include <likelihoodptrvector.h>

Collaboration diagram for LikelihoodPtrVector:
Collaboration graph

Public Member Functions

 LikelihoodPtrVector ()
 This is the default LikelihoodPtrVector constructor. More...
 
 LikelihoodPtrVector (const LikelihoodPtrVector &initial)
 This is the LikelihoodPtrVector constructor that creates a copy of an existing LikelihoodPtrVector. More...
 
 ~LikelihoodPtrVector ()
 This is the LikelihoodPtrVector destructor. More...
 
void resize (Likelihood *value)
 This will add one new entry to the vector. More...
 
void Delete (int pos)
 This will delete an entry from the vector. More...
 
int Size () const
 This will return the size of the vector. More...
 
Likelihood *& operator[] (int pos)
 This will return the value of an element of the vector. More...
 
Likelihood *const & operator[] (int pos) const
 This will return the value of an element of the vector. More...
 

Protected Attributes

Likelihood ** v
 This is the vector of Likelihood values. More...
 
int size
 This is the size of the vector. More...
 

Detailed Description

This class implements a dynamic vector of Likelihood values.

Constructor & Destructor Documentation

◆ LikelihoodPtrVector() [1/2]

LikelihoodPtrVector::LikelihoodPtrVector ( )
inline

This is the default LikelihoodPtrVector constructor.

◆ LikelihoodPtrVector() [2/2]

LikelihoodPtrVector::LikelihoodPtrVector ( const LikelihoodPtrVector initial)

This is the LikelihoodPtrVector constructor that creates a copy of an existing LikelihoodPtrVector.

Parameters
initialis the LikelihoodPtrVector to copy

◆ ~LikelihoodPtrVector()

LikelihoodPtrVector::~LikelihoodPtrVector ( )

This is the LikelihoodPtrVector destructor.

Note
This will free all the memory allocated to all the elements of the vector

Member Function Documentation

◆ Delete()

void LikelihoodPtrVector::Delete ( int  pos)

This will delete an entry from the vector.

Parameters
posis the element of the vector to be deleted
Note
This will free the memory allocated to the deleted element of the vector

◆ operator[]() [1/2]

Likelihood*& LikelihoodPtrVector::operator[] ( int  pos)
inline

This will return the value of an element of the vector.

Parameters
posis the element of the vector to be returned
Returns
the value of the specified element

◆ operator[]() [2/2]

Likelihood* const& LikelihoodPtrVector::operator[] ( int  pos) const
inline

This will return the value of an element of the vector.

Parameters
posis the element of the vector to be returned
Returns
the value of the specified element

◆ resize()

void LikelihoodPtrVector::resize ( Likelihood value)

This will add one new entry to the vector.

Parameters
valueis the value that will be entered for the new entry

◆ Size()

int LikelihoodPtrVector::Size ( ) const
inline

This will return the size of the vector.

Returns
the size of the vector

Member Data Documentation

◆ size

int LikelihoodPtrVector::size
protected

This is the size of the vector.

◆ v

Likelihood** LikelihoodPtrVector::v
protected

This is the vector of Likelihood values.


The documentation for this class was generated from the following files: