ETISS 0.8.0
Extendable Translating Instruction Set Simulator (version 0.8.0)
Public Member Functions | Public Attributes | List of all members
etiss::error::Error Class Referenceabstract

base error class for simple handling of errors More...

#include <ErrorDefinition.h>

Inheritance diagram for etiss::error::Error:
Inheritance graph
[legend]
Collaboration diagram for etiss::error::Error:
Collaboration graph
[legend]

Public Member Functions

 Error (bool persistent, int id=-1, const std::string &name="")
 
virtual ~Error ()
 
virtual void apply (uint64_t &var)=0
 
virtual void apply (uint32_t &var)
 
virtual void apply (uint16_t &var)
 
virtual void apply (uint8_t &var)
 
virtual const std::vector< unsigned > affectedBits ()=0
 

Public Attributes

const bool persistent_
 
int id_
 
std::string name_
 

Detailed Description

base error class for simple handling of errors

Attention
any class is required to implement virtual void apply(uint64_t & var) AND provide a templated function template<typename T> fapply(T & var) that applies the error.
currently no variable largt than uint64_t can be used

Definition at line 76 of file ErrorDefinition.h.

Constructor & Destructor Documentation

◆ Error()

etiss::error::Error::Error ( bool  persistent,
int  id = -1,
const std::string &  name = "" 
)
Parameters
idif id is negative the a new negative id from a global id pool will be used. the pool may assign the same id if the total number of error instances during progam execution exceds 2^(sizeof(int)*8-1)

Definition at line 79 of file ErrorDefinition.cpp.

◆ ~Error()

etiss::error::Error::~Error ( )
virtual

Definition at line 83 of file ErrorDefinition.cpp.

Member Function Documentation

◆ affectedBits()

virtual const std::vector<unsigned> etiss::error::Error::affectedBits ( )
pure virtual

◆ apply() [1/4]

void etiss::error::Error::apply ( uint16_t var)
virtual

Definition at line 91 of file ErrorDefinition.cpp.

References apply(), uint16_t, and uint64_t.

Here is the call graph for this function:

◆ apply() [2/4]

void etiss::error::Error::apply ( uint32_t var)
virtual

Definition at line 85 of file ErrorDefinition.cpp.

References apply(), uint32_t, and uint64_t.

Here is the call graph for this function:

◆ apply() [3/4]

virtual void etiss::error::Error::apply ( uint64_t var)
pure virtual

Implemented in etiss::error::StuckLow, etiss::error::StuckHigh, and etiss::error::BitFlip.

Referenced by apply().

Here is the caller graph for this function:

◆ apply() [4/4]

void etiss::error::Error::apply ( uint8_t var)
virtual

Definition at line 97 of file ErrorDefinition.cpp.

References apply(), uint64_t, and uint8_t.

Here is the call graph for this function:

Member Data Documentation

◆ id_

int etiss::error::Error::id_

Definition at line 80 of file ErrorDefinition.h.

◆ name_

std::string etiss::error::Error::name_

Definition at line 81 of file ErrorDefinition.h.

◆ persistent_

const bool etiss::error::Error::persistent_

Definition at line 79 of file ErrorDefinition.h.


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