aGrUM  0.13.2
gum::BNReader< GUM_SCALAR > Class Template Referenceabstract

Pure virtual class for reading a BN from a file. More...

#include <agrum/BN/io/BNReader.h>

+ Inheritance diagram for gum::BNReader< GUM_SCALAR >:

Public Member Functions

 BNReader (BayesNet< GUM_SCALAR > *bn, const std::string &filename)
 Constructor A reader is defined for reading a defined file. More...
 
virtual ~BNReader ()
 Default destructor. More...
 
virtual Size proceed ()=0
 Reads a Bayesian Network from the file referenced by filePath into` parameter bayesNet. More...
 

Detailed Description

template<typename GUM_SCALAR>
class gum::BNReader< GUM_SCALAR >

Pure virtual class for reading a BN from a file.

Every class used to read the content of a Bayesian Network from a stream, or a file must be a subclass of BNReader.

Definition at line 52 of file BNReader.h.

Constructor & Destructor Documentation

template<typename GUM_SCALAR >
gum::BNReader< GUM_SCALAR >::BNReader ( BayesNet< GUM_SCALAR > *  bn,
const std::string &  filename 
)

Constructor A reader is defined for reading a defined file.

Hence the 2 args of the constructor. Note that the BN has to be built outside the reader. There is no delegation to create/destroy the BN from inside the reader.

template<typename GUM_SCALAR >
virtual gum::BNReader< GUM_SCALAR >::~BNReader ( )
virtual

Default destructor.

Member Function Documentation

template<typename GUM_SCALAR >
virtual Size gum::BNReader< GUM_SCALAR >::proceed ( )
pure virtual

Reads a Bayesian Network from the file referenced by filePath into` parameter bayesNet.

Returns
Returns the number of error during the parsing (0 if none).

Implemented in gum::BIFReader< GUM_SCALAR >, gum::BIFXMLBNReader< GUM_SCALAR >, gum::UAIReader< GUM_SCALAR >, gum::NetReader< GUM_SCALAR >, gum::DSLReader< GUM_SCALAR >, and gum::O3prmBNReader< GUM_SCALAR >.


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