#include <cDomainRational.h>
List of all members.
Detailed Description
Definition at line 52 of file cDomainRational.h.
Constructor & Destructor Documentation
The constructor for rational number domains.
- Parameters:
-
dfMantissa | the domain for the mantisse of the rational domain |
dfExponent | the domain for the exponent of the rational domain |
fib::cDomainRational::cDomainRational |
( |
const TiXmlElement * |
pXmlElement, |
|
|
intFib & |
outStatus |
|
) |
| |
This constructor restores a domain in the XML -format from an TinyXml element.
- Parameters:
-
pXmlNode | a pointer to the TinyXml node wher the domain is stored in |
outStatus | an integervalue with the errorvalue possible errorvalues are:
- 0 loading successful
- -1 loading error, invalid pXmlElement
- -2 loading error, invalid data in pXmlElement
- 1 loading warning, invalid data in pXmlElement, error could be corrected
- 2 loading warning, invalid data in pXmlElement, maybe the loaded object is wrong
|
The copyconstructor for natural numer domains.
- Parameters:
-
domain | the rational number domain to copy |
Member Function Documentation
void fib::cDomainRational::decomposeDoubleFib |
( |
const doubleFib |
dNumber, |
|
|
longFib & |
lInOutMantissa, |
|
|
longFib & |
lInOutExponent |
|
) |
| const |
|
protected |
Decompses a doubleFib number into it's mantissa and exponent part.
- Parameters:
-
dNumber | the number to decompose |
lInOutMantissa | a pointer to the longFib field wher the mantissa should be stored |
lInOutExponent | a pointer to the longFib field wher the exponent should be stored |
virtual unsignedIntFib fib::cDomainRational::getCompressedSize |
( |
| ) |
const |
|
virtual |
This method evaluades the size of the domain in bits in the compressed file form.
- See also:
- store()
- Returns:
- the size of the domain in bits in the compressed form
Implements fib::cDomain.
virtual unsignedIntFib fib::cDomainRational::getCompressedSizeForValue |
( |
| ) |
const |
|
virtual |
This method evaluades the size of values in the domain in bits in the compressed file form.
- See also:
- store()
- Returns:
- the size of the domain in bits in the compressed form
Implements fib::cDomainSingle.
doubleFib fib::cDomainRational::getMaximum |
( |
| ) |
const |
|
virtual |
This method returns the biggest value in the domain.
- Returns:
- the biggest value in the domain
Implements fib::cDomainSingle.
virtual doubleFib fib::cDomainRational::getMinimum |
( |
| ) |
const |
|
virtual |
This method returns the smalest value in the domain.
- Returns:
- the smalest value in the domain
Implements fib::cDomainSingle.
virtual doubleFib fib::cDomainRational::getNull |
( |
| ) |
const |
|
virtual |
This method returns the nullvalue of the domain. The nullvalue is the value 0 rounded to an value in the domain.
- Returns:
- the nullvalue of the domain
Implements fib::cDomainSingle.
virtual string fib::cDomainRational::getType |
( |
| ) |
const |
|
virtual |
- Returns:
- the type of the domain as an string
Implements fib::cDomain.
virtual bool fib::cDomainRational::isElement |
( |
const doubleFib |
dValue | ) |
const |
|
virtual |
This method checks if the given value is an element of the domain. If the value dValue is an element of the domain true is returned, else false.
- Parameters:
-
dValue | the value for which to check, if it is an element of the domain |
- Returns:
- if the value dValue is an element of the domain true true is returned, else false
Implements fib::cDomainSingle.
virtual bool fib::cDomainRational::isInBoundaries |
( |
const doubleFib |
dValue | ) |
const |
|
virtual |
This method checks if the given value is inside the domain boundaries. If the value dValue is inside of the domain boundaries true is returned, else false. A value is inside of the vector domain boudaries, if it is greater than the minimum value and lower than the maximum value.
- Parameters:
-
dValue | the value for which to check, if it is inside of the domain boundaries |
- Returns:
- if the vector dValue is inside of the domain boundaries true is returned, else false
Implements fib::cDomainSingle.
This method restores a domain from a bitstream, wher it is stored in the compressed fib -format.
- See also:
- store
- Parameters:
-
iBitStream | the stream where the domain is stored in, because the stream is an cReadBits, any number of bits can be readed from it |
- Returns:
- an integervalue with the errorvalue possible errorvalues are:
- 0 loading successful
- -1 loading error, invalid pXmlElement
- -2 loading error, invalid data in pXmlElement
- 1 loading warning, invalid data in pXmlElement, error could be corrected
- 2 loading warning, invalid data in pXmlElement, maybe the loaded object is wrong
Implements fib::cDomain.
This method restores the a unscaled integer value of the domain from the stream iBitStream, wher it is stored in the compressed fib -format.
- See also:
- storeValue
-
restoreValue
-
storeUnscaledValue
-
cFibElement::restore
- Parameters:
-
iBitStream | the stream where this value is stored to in, because this stream is an cReadBits, any number of bits can be readed from it |
outStatus | An reference to an integervalue where the errorvalue can be stored to. If the pointer is NULL no errorvalue will be given back. possible errorvalues are:
- 0 loading successful
- -1 loading error, invalid stream
- -2 loading error, invalid data in stream
- 1 loading warning, invalid data in stream, error could be corrected
- 2 loading warning, invalid data in stream, maybe the loaded object is wrong
|
- Returns:
- the restored value
Implements fib::cDomainRationalBasis.
virtual intFib fib::cDomainRational::restoreXml |
( |
const TiXmlElement * |
pXmlElement | ) |
|
|
virtual |
This method restores a domain in the XML -format from an TinyXml element.
- Parameters:
-
pXmlNode | a pointer to the TinyXml node wher the domain is stored in |
- Returns:
- an integervalue with the errorvalue possible errorvalues are:
- 0 loading successful
- -1 loading error, invalid pXmlElement
- -2 loading error, invalid data in pXmlElement
- 1 loading warning, invalid data in pXmlElement, error could be corrected
- 2 loading warning, invalid data in pXmlElement, maybe the loaded object is wrong
Implements fib::cDomain.
This method round the given value dValue to an value in the domain of this object. The rounded vale will be the value with the minimal distance to the given value dValue. If more of these exists the smales will be returned.
- Parameters:
-
dValue | the value which should be rounded |
- Returns:
- the rounded value of dValue
Implements fib::cDomainSingle.
virtual bool fib::cDomainRational::store |
( |
ostream & |
stream, |
|
|
char & |
cRestBits, |
|
|
unsigned char & |
uiRestBitPosition |
|
) |
| const |
|
virtual |
This method stores this domain in the compressed fib -format into the given stream. It is needed because the stream can yust store byts but the size of fib -elements can be any number of bits. Because of that ther have to be a possibility to exchange the missing bits betwean the fib -elements.
- See also:
- cFibElement::store
- Parameters:
-
stream | the stream where this domain should be stored to |
cRestBits | the not yet writen bits which should be stored |
uiRestBitPosition | the number of bits in the cRestBits which should be writen respectively containing valid information |
- Returns:
- true if the domain is stored, else false
Implements fib::cDomain.
virtual bool fib::cDomainRational::storeValue |
( |
doubleFib |
dValue, |
|
|
ostream & |
stream, |
|
|
char & |
cRestBits, |
|
|
unsigned char & |
uiRestBitPosition |
|
) |
| const |
|
virtual |
This method stores the given value dValue in the compressed fib -format for the domain into the given stream. It is needed because the stream can yust store byts but the size of fib -elements can be any number of bits. Because of that ther have to be a possibility to exchange the missing bits betwean the fib -elements.
- See also:
- cFibElement::store
- Parameters:
-
dValue | the value to store |
stream | the stream where this domain should be stored to |
cRestBits | the not yet writen bits which should be stored |
uiRestBitPosition | the number of bits in the cRestBits which should be writen respectively containing valid information |
- Returns:
- true if the domain is stored, else false
Implements fib::cDomainRationalBasis.
virtual bool fib::cDomainRational::storeXml |
( |
ostream & |
ostream | ) |
const |
|
virtual |
This method stores this domain in the XML -format into the given stream.
- Parameters:
-
ostream | the stream where domains should be stored to |
- Returns:
- true if this domain are stored, else false
Implements fib::cDomain.
The documentation for this class was generated from the following file: