Patch level : 12.0 no patch
Files correlati : Aggiunte cotan eliminati i longdouble per il debug git-svn-id: svn://10.65.10.50/branches/R_10_00@23763 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
2e06fbd35f
commit
d0a48beb9f
@ -3,381 +3,40 @@
|
||||
#include <strings.h>
|
||||
|
||||
const real ZERO(0.0);
|
||||
const real PUNTO_UNO(UNO/DIECI);
|
||||
const real PUNTO_DUE(DUE/DIECI);
|
||||
const real PUNTO_TRE(TRE/DIECI);
|
||||
const real PUNTO_QUATTRO(DUE/CINQUE);
|
||||
const real MEZZO(UNO/DUE);
|
||||
const real PUNTO_SEI(TRE/CINQUE);
|
||||
const real PUNTO_SETTE(SETTE/DIECI);
|
||||
const real PUNTO_OTTO(QUATTRO/CINQUE);
|
||||
const real PUNTO_NOVE(NOVE/DIECI);
|
||||
const real UNO(1.0);
|
||||
const real DUE(2.0);
|
||||
const real TRE(3.0);
|
||||
const real QUATTRO(4.0);
|
||||
const real CINQUE(5.0);
|
||||
const real SEI(6.0);
|
||||
const real SETTE(7.0);
|
||||
const real OTTO(8.0);
|
||||
const real NOVE(9.0);
|
||||
const real DIECI(10.0);
|
||||
const real UNDICI(11.0);
|
||||
const real DODICI(12.0);
|
||||
const real TREDICI(13.0);
|
||||
const real QUATTORDICI(14.0);
|
||||
const real QUINDICI(15.0);
|
||||
const real SEDICI(16.0);
|
||||
const real DICIASSETTE(17.0);
|
||||
const real DICIOTTO(18.0);
|
||||
const real DICIANNOVE(19.0);
|
||||
const real VENTI(20.0);
|
||||
const real VENTUNO(21.0);
|
||||
const real VENTIDUE(22.0);
|
||||
const real CINQUANTA(50.0);
|
||||
const real CENTO(100.0);
|
||||
|
||||
#ifdef __LONGDOUBLE__
|
||||
|
||||
#include <math.h>
|
||||
|
||||
#ifdef WIN32
|
||||
|
||||
#include <stdio.h>
|
||||
inline long double _atold(const char* str)
|
||||
{
|
||||
long double num = 0.0;
|
||||
sscanf(str, "%Lf", &num);
|
||||
return num;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
real::real () : _dec(0.0)
|
||||
{ }
|
||||
|
||||
real::real (const real& b) : _dec(b._dec)
|
||||
{ }
|
||||
|
||||
real::real (long double a) : _dec(a)
|
||||
{ }
|
||||
|
||||
void real::set_int64(__int64 b)
|
||||
{
|
||||
_dec = (long double)b;
|
||||
}
|
||||
|
||||
bool real::is_real (const char *s)
|
||||
{
|
||||
if (s && *s)
|
||||
{
|
||||
const long double n = _atold(s);
|
||||
if (n == 0.0)
|
||||
{
|
||||
for(; *s; s++)
|
||||
{
|
||||
if (strchr("0. ", *s) == NULL)
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
real::real (const char *s)
|
||||
{
|
||||
_dec = (s && *s) ? _atold(s) : 0.0;
|
||||
}
|
||||
|
||||
real& real::operator = (const real& b)
|
||||
{
|
||||
_dec = b._dec;
|
||||
return *this;
|
||||
}
|
||||
|
||||
real& real::operator = (long double b)
|
||||
{
|
||||
_dec = b;
|
||||
return *this;
|
||||
}
|
||||
|
||||
real& real::operator += (long double b)
|
||||
{
|
||||
_dec += b;
|
||||
return *this;
|
||||
}
|
||||
|
||||
real& real::operator -= (long double b)
|
||||
{
|
||||
_dec -= b;
|
||||
return *this;
|
||||
}
|
||||
|
||||
real& real::operator *= (long double b)
|
||||
{
|
||||
_dec *= b;
|
||||
return *this;
|
||||
}
|
||||
|
||||
real& real::operator /= (long double b)
|
||||
{
|
||||
CHECK(b != 0.0, "Division by zero");
|
||||
_dec /= b;
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
// @doc EXTERNAL
|
||||
|
||||
// @mfunc Ritorna il segno del reale
|
||||
//
|
||||
// @rdesc Ritorna i seguenti valori:
|
||||
//
|
||||
// @flag <lt> 0 | Se il numero e' minore di 0
|
||||
// @flag = 0 | Se il numero e' uguale a 0
|
||||
// @flag <gt> 0 | Se il numero e' maggiore di 0
|
||||
int real::sign () const
|
||||
{
|
||||
const int s = _dec > 0.0 ? +1 : (_dec < 0.0 ? -1 : 0);
|
||||
return s;
|
||||
}
|
||||
|
||||
real real::operator - () const
|
||||
{
|
||||
real n(-_dec);
|
||||
return n;
|
||||
}
|
||||
|
||||
long real::integer () const
|
||||
{
|
||||
return (long)floorl(_dec);
|
||||
}
|
||||
|
||||
// Certified 91%
|
||||
// @doc EXTERNAL
|
||||
|
||||
// @mfunc Trasforma un reale in stringa
|
||||
//
|
||||
// @rdesc Ritorna la stringa nella lunghezza richiesta
|
||||
const char *real::string (
|
||||
int len, // @parm Lunghezza della stringa (compreso decimali)
|
||||
int dec, // @parm Numero di decimali (default UNDEFINED)
|
||||
char pad) const // @parm Carattere di riempimento (default ' ')
|
||||
// @parm char * | picture | Formato della stringa
|
||||
|
||||
// @syntax string (int len, int dec, char pad);
|
||||
// @syntax string (const char *picture);
|
||||
//
|
||||
// @comm Nel primo caso ritorna una stringa lunga <p len> con <p dec> decimali e
|
||||
// inserisce nella stringa stessa il carattere <p pad> nel caso la
|
||||
// lunghezza richiesta sia maggiore di quella che risulterebbe per la
|
||||
// completa rappresentazione del reale.
|
||||
// <nl>Nel secondo caso ritorna la stringa con il formato stabilito in
|
||||
// <p picture>.
|
||||
|
||||
{
|
||||
TString16 fmt("%");
|
||||
if (pad != ' ') fmt << '0';
|
||||
if (len != 0) fmt << len;
|
||||
if (dec != UNDEFINED) fmt << '.' << dec;
|
||||
fmt << "Lf";
|
||||
|
||||
TString& tmp = get_tmp_string();
|
||||
char* __string = tmp.get_buffer(len);
|
||||
|
||||
sprintf(__string, fmt, _dec);
|
||||
|
||||
if (len == 0 && dec == UNDEFINED && strchr(__string, '.') != NULL)
|
||||
{
|
||||
int cut = strlen (__string);
|
||||
for (int i = cut-1; i >= 0; i--)
|
||||
{
|
||||
if (__string[i] == '0')
|
||||
cut--;
|
||||
else
|
||||
{
|
||||
if(__string[i] == '.')
|
||||
cut--;
|
||||
break;
|
||||
}
|
||||
}
|
||||
__string[cut] = '\0';
|
||||
}
|
||||
return __string;
|
||||
}
|
||||
|
||||
// Childish algorithm faster and more accurate than powl(10.0, pow)
|
||||
HIDDEN void ipow10(int pow, double& m, double& d)
|
||||
{
|
||||
m = d = 1.0;
|
||||
if (pow > 0)
|
||||
{
|
||||
for (int i = pow; i > 0; i--)
|
||||
{
|
||||
m *= 10.0;
|
||||
d *= 0.1;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int i = pow; i < 0; i++)
|
||||
{
|
||||
m *= 0.1;
|
||||
d *= 10.0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int real::precision() const
|
||||
{
|
||||
const TFixed_string s(string());
|
||||
const int d = s.find('.');
|
||||
const int p = d < 0 ? 0 : (s.len()-d-1);
|
||||
return p;
|
||||
}
|
||||
|
||||
|
||||
// @doc EXTERNAL
|
||||
|
||||
// @mfunc real& | real | round | Arrotonda al numero di decimali passati
|
||||
real& real::round (
|
||||
int prec) // @parm Numero di decimali a cui arrotondare il numero (default 0)
|
||||
|
||||
// @comm Nel caso <p prec> sia:
|
||||
//
|
||||
// @flag <gt> 0 | Arrotonda al decimale
|
||||
// @flag = 0 | Arrotonda all'intero
|
||||
// @flag <lt> 0 | Arrotonda al valore passato (es. -3 arrotonda alle mille)
|
||||
{
|
||||
if (abs(prec) < 20)
|
||||
{
|
||||
double m, d;
|
||||
if (prec != 0)
|
||||
{
|
||||
ipow10(prec, m, d);
|
||||
if (prec < 0)
|
||||
_dec /= d;
|
||||
else
|
||||
_dec *= m;
|
||||
}
|
||||
|
||||
if (_dec >= 0.0)
|
||||
_dec = floorl(_dec + 0.5);
|
||||
else
|
||||
_dec = ceill(_dec - 0.5);
|
||||
|
||||
if (prec != 0)
|
||||
{
|
||||
if (prec < 0)
|
||||
_dec *= d;
|
||||
else
|
||||
_dec /= m;
|
||||
}
|
||||
}
|
||||
return *this;
|
||||
}
|
||||
|
||||
real& real::ceil (int prec)
|
||||
{
|
||||
double m, d;
|
||||
if (prec != 0)
|
||||
{
|
||||
ipow10(prec, m, d);
|
||||
_dec *= m;
|
||||
}
|
||||
_dec = ceill(_dec);
|
||||
if (prec != 0)
|
||||
// _dec *= d; Risulta stranamente molto impreciso!
|
||||
_dec /= m;
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
||||
real& real::floor (int prec)
|
||||
{
|
||||
double m, d;
|
||||
if (prec != 0)
|
||||
{
|
||||
ipow10(prec, m, d);
|
||||
_dec *= m;
|
||||
}
|
||||
_dec = floorl(_dec);
|
||||
if (prec != 0)
|
||||
// _dec *= d; Risulta stranamente molto impreciso!
|
||||
_dec /= m;
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
||||
real& real::trunc(int prec)
|
||||
{
|
||||
double m, d;
|
||||
if (prec != 0)
|
||||
{
|
||||
ipow10(prec, m, d);
|
||||
_dec *= m;
|
||||
}
|
||||
_dec = floorl(_dec);
|
||||
if (prec != 0)
|
||||
// _dec *= d; Risulta stranamente molto impreciso!
|
||||
_dec /= m;
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
// @doc EXTERNAL
|
||||
|
||||
// @func Scambia il numero reale <p a> con il numero real <p b>
|
||||
void swap (
|
||||
real& a, // @parm Primo numero da scambiare
|
||||
real& b) // @parm Secondo numero da scambiare
|
||||
|
||||
{
|
||||
const real n = a;
|
||||
a = b;
|
||||
b = n;
|
||||
}
|
||||
|
||||
long double operator%(const real& a, const real& b)
|
||||
{
|
||||
const long double times = floorl(a / b);
|
||||
const long double resto = (double)a - (double)b * times;
|
||||
return resto;
|
||||
}
|
||||
|
||||
long double sqr(long double a)
|
||||
{
|
||||
return a*a;
|
||||
}
|
||||
|
||||
long double exp10(long double a)
|
||||
{
|
||||
return powl(10.0, a);
|
||||
}
|
||||
|
||||
#if _MSC_VER < 1300
|
||||
|
||||
long double sqrt(long double a)
|
||||
{
|
||||
return sqrtl(a);
|
||||
}
|
||||
|
||||
long double pow(long double a, long double b)
|
||||
{
|
||||
return powl(a, b);
|
||||
}
|
||||
|
||||
long double exp(long double a)
|
||||
{
|
||||
return expl(a);
|
||||
}
|
||||
|
||||
long double log10(long double a)
|
||||
{
|
||||
return log10l(a);
|
||||
}
|
||||
|
||||
long double log(long double a)
|
||||
{
|
||||
return logl(a);
|
||||
}
|
||||
|
||||
long double sin(long double a)
|
||||
{
|
||||
return sinl(a);
|
||||
}
|
||||
|
||||
long double cos(long double a)
|
||||
{
|
||||
return cosl(a);
|
||||
}
|
||||
|
||||
long double tan(long double a)
|
||||
{
|
||||
return tanl(a);
|
||||
}
|
||||
|
||||
long double abs(long double a)
|
||||
{
|
||||
return fabsl(a);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
#else
|
||||
|
||||
#include <gm.h>
|
||||
//#include <ctype.h>
|
||||
//#include <stdlib.h>
|
||||
@ -1254,8 +913,6 @@ const char* real::format(const char *picture) const
|
||||
return (const char *) f;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
// Funzioni comuni dei due real
|
||||
|
||||
TObject* real::dup () const
|
||||
@ -1511,6 +1168,15 @@ HIDDEN int get_picture_decimals (const TString& picture, char& decsep)
|
||||
return decimali;
|
||||
}
|
||||
|
||||
long double real::ld() const
|
||||
{
|
||||
TString20 str = string();
|
||||
long double num;
|
||||
|
||||
sscanf(str, "%Lf", &num);
|
||||
return num;
|
||||
}
|
||||
|
||||
const char* real::string(const char *picture) const
|
||||
{
|
||||
if (*picture == '\0')
|
||||
@ -1868,12 +1534,3 @@ int TImporto::compare(const TSortable& s) const
|
||||
const int res = d.sign();
|
||||
return res;
|
||||
}
|
||||
|
||||
bool TImporto::is_zero() const
|
||||
{
|
||||
#ifdef __LONGDOUBLE__
|
||||
return fabsl(_valore) < 0.00001;
|
||||
#else
|
||||
return _valore.is_zero();
|
||||
#endif
|
||||
}
|
||||
|
@ -12,168 +12,40 @@
|
||||
class real;
|
||||
|
||||
extern const real ZERO;
|
||||
extern const real PUNTO_UNO;
|
||||
extern const real PUNTO_DUE;
|
||||
extern const real PUNTO_TRE;
|
||||
extern const real PUNTO_QUATTRO;
|
||||
extern const real MEZZO;
|
||||
extern const real PUNTO_SEI;
|
||||
extern const real PUNTO_SETTE;
|
||||
extern const real PUNTO_OTTO;
|
||||
extern const real PUNTO_NOVE;
|
||||
extern const real UNO;
|
||||
extern const real DUE;
|
||||
extern const real TRE;
|
||||
extern const real QUATTRO;
|
||||
extern const real CINQUE;
|
||||
extern const real SEI;
|
||||
extern const real SETTE;
|
||||
extern const real OTTO;
|
||||
extern const real NOVE;
|
||||
extern const real DIECI;
|
||||
extern const real UNDICI;
|
||||
extern const real DODICI;
|
||||
extern const real TREDICI;
|
||||
extern const real QUATTORDICI;
|
||||
extern const real QUINDICI;
|
||||
extern const real SEDICI;
|
||||
extern const real DICIASSETTE;
|
||||
extern const real DICIOTTO;
|
||||
extern const real DICIANNOVE;
|
||||
extern const real VENTI;
|
||||
extern const real VENTUNO;
|
||||
extern const real VENTIDUE;
|
||||
extern const real CINQUANTA;
|
||||
extern const real CENTO;
|
||||
|
||||
#ifdef __LONGDOUBLE__
|
||||
|
||||
// @doc EXTERNAL
|
||||
|
||||
// @class real | Classe per la gestione dei numeri reali
|
||||
//
|
||||
// @base public | TObject
|
||||
class real : public TObject
|
||||
|
||||
// @comm Questa classe utilizza i long double definiti per Visual C++. Esiste un'altra classe
|
||||
// real: per accedere scegliere il tasto successivo (<gt><gt>) dalla barra dei bottoni
|
||||
|
||||
// @author:(INTERNAL) Guido
|
||||
{
|
||||
// @access:(INTERNAL) Private Member
|
||||
|
||||
// @cmember:(INTERNAL) Numero reale
|
||||
long double _dec;
|
||||
|
||||
// @access Protected Member
|
||||
protected:
|
||||
// @cmember Permette di stampare l'oggetto
|
||||
virtual void print_on(ostream& out) const;
|
||||
|
||||
// @cmember Duplica il numero reale (vedi classe <c TObject>)
|
||||
virtual TObject* dup() const;
|
||||
// @cmember Traduce in lettere il numero reale
|
||||
const char* literals() const;
|
||||
// @cmember Inserisce i punti separatori delle migliaia e riempe i decimali
|
||||
// alla lunghezza passata (es: 3.000,20)
|
||||
const char* points(int decimals = 0) const;
|
||||
|
||||
// @access Public Member
|
||||
public:
|
||||
// @cmember long double | operator long double | | Ritorna il numero reale
|
||||
operator long double () const
|
||||
{ return _dec; }
|
||||
|
||||
// @cmember Trasforma un numero dal formato inglese (decimali con punto) in
|
||||
// formato italiano (decimali con virgola)
|
||||
static const char* eng2ita(char* s);
|
||||
// @cmember Trasforma un numero dal formato italiano (decimali con virgola) in
|
||||
// formato inglese (decimali con punto)
|
||||
static const char* ita2eng(const char* s);
|
||||
// @cmember Controlla se si tratta di un numero reale (TRUE se vero)
|
||||
static bool is_real(const char* n);
|
||||
// @cmember Controlla se si tratta di un numero naturale (TRUE se vero)
|
||||
static bool is_natural(const char* n);
|
||||
// @cmember Controlla se si tratta di uno zero (TRUE se vero)
|
||||
static bool is_null(const char* n);
|
||||
// @cmember Trasforma un reale in stringa
|
||||
const char* string(int len = 0, int dec = UNDEFINED, char pad = ' ') const;
|
||||
// @cmember Trasforma un reale in stringa (chiama <mf real::string>),
|
||||
// ma ritorna il formato italiano
|
||||
const char* stringa(int len = 0, int dec = UNDEFINED, char pad = ' ') const;
|
||||
// @cmember Trasforma un reale in stringa (chiama <mf real::string>),
|
||||
// ma ritorna il formato atteso da Excel
|
||||
const char* stringe(int len = 0, int dec = UNDEFINED, char pad = ' ') const;
|
||||
// @cmember Ritorna la stringa con il formato passato
|
||||
const char* string(const char* picture) const;
|
||||
// @cmember Ritorna la stringa con il formato passato
|
||||
const char* format(const char *picture) const;
|
||||
|
||||
// @cmember Ritorna la precisione del reale (numero di decimali)
|
||||
int precision() const;
|
||||
// @cmember Controlla se si tratta di un reale uguale a 0
|
||||
bool is_zero() const { return _dec == ZERO; }
|
||||
// @cmember Controlla se si tratta di un reale diverso da 0
|
||||
bool not_zero() const { return !is_zero();}
|
||||
// @cmember Ritorna il segno del reale
|
||||
int sign() const;
|
||||
// @cmember Trasforma il reale in intero (operator int era troppo pericoloso)
|
||||
long integer() const;
|
||||
|
||||
// @cmember Arrotonda al numero di decimali passati
|
||||
real& round(int prec = 0) ;
|
||||
// @cmember Tronca al numero di decimali passati (default 0)
|
||||
real& trunc(int prec = 0) ;
|
||||
// @cmember Arrotonda al numero successivo (della precisione passata)
|
||||
real& ceil(int prec = 0);
|
||||
// @cmember Arrotonda al numero precedente (della precisione passata)
|
||||
real& floor(int prec = 0);
|
||||
// @cmember Assegna un reale
|
||||
real& operator = (const real& a);
|
||||
// @cmember Assegna un reale
|
||||
real& operator =(long double a);
|
||||
// @cmember Assegna un __int64 ad un reale
|
||||
void set_int64(__int64 b);
|
||||
// @cmember Aggiunge ad un reale il valore passato (passato per indirizzo)
|
||||
real& operator +=(long double a);
|
||||
// @cmember Sottrae ad un reale il valore passato (passato per indirizzo)
|
||||
real& operator -=(long double b);
|
||||
// @cmember Moltiplica un reale per il valore passato (passato per indirizzo)
|
||||
real& operator *=(long double b);
|
||||
// @cmember Divide un reale per il valore passato (passato per indirizzo)
|
||||
real& operator /=(long double b);
|
||||
// @cmember Ritorna la negazione di un reale (TRUE se 0, altrimenti FALSE)
|
||||
bool operator !() const
|
||||
{ return _dec == ZERO; }
|
||||
// @cmember Ritorna il risultato della differenza tra due reali
|
||||
real operator -() const;
|
||||
|
||||
// @cmember Costruttore
|
||||
real();
|
||||
// @cmember Costruttore
|
||||
real(const real& b);
|
||||
// @cmember Costruttore
|
||||
real(long double a);
|
||||
// @cmember Costruttore
|
||||
real(const char* s);
|
||||
// @cmember Distruttore
|
||||
virtual ~real()
|
||||
{}
|
||||
};
|
||||
|
||||
inline long double fnc_min(long double a, long double b){ return a < b ? a : b; }
|
||||
inline long double fnc_max(long double a, long double b) { return a > b ? a : b; }
|
||||
|
||||
inline bool operator <(const real& a, const real& b) {return (double)a < (double)b;}
|
||||
inline bool operator <(double a, const real& b) {return a < (double)b;}
|
||||
inline bool operator >(const real& a, const real& b) {return (double)a > (double)b;}
|
||||
inline bool operator >(double a, const real& b) {return a > (double)b;}
|
||||
inline bool operator <=(const real& a, const real& b) {return (double)a <= (double)b;}
|
||||
inline bool operator <=(double a, const real& b) {return a <= (double)b;}
|
||||
inline bool operator >=(const real& a, const real& b) {return (double)a >= (double)b;}
|
||||
inline bool operator >=(double a, const real& b) {return a >= (double)b;}
|
||||
inline bool operator ==(const real& a, const real& b) {return (double)a == (double)b;}
|
||||
inline bool operator ==(double a, const real& b) {return a == (double)b;}
|
||||
inline bool operator !=(const real& a, const real& b) {return (double)a != (double)b;}
|
||||
inline bool operator !=(double a, const real& b) {return a != (double)b;}
|
||||
|
||||
inline real operator +(const real& a, const real& b) {return (double)a + (double)b;}
|
||||
inline real operator -(const real& a, const real& b) {return (double)a - (double)b;}
|
||||
inline real operator *(const real& a, const real& b) {return (double)a * (double)b;}
|
||||
inline real operator /(const real& a, const real& b) {return (double)a / (double)b;}
|
||||
|
||||
long double operator%(const real& a, const real& b);
|
||||
void swap(real& a, real& b) ;
|
||||
long double sqr(long double) ;
|
||||
long double exp10(long double) ;
|
||||
|
||||
#if _MSC_VER < 1300
|
||||
long double sqrt(long double) ;
|
||||
long double pow(long double, long double) ;
|
||||
long double exp(long double a) ;
|
||||
long double log10(long double a) ;
|
||||
long double log(long double a) ;
|
||||
long double sin(long double a) ;
|
||||
long double cos(long double a) ;
|
||||
long double tan(long double a) ;
|
||||
long double abs(long double a) ;
|
||||
#else
|
||||
#include <math.h>
|
||||
#endif
|
||||
|
||||
#else
|
||||
|
||||
#ifndef INCSTR_H
|
||||
#include <incstr.h>
|
||||
#endif
|
||||
@ -236,6 +108,8 @@ public:
|
||||
// @cmember Ritorna l'indirizzo del numero reale
|
||||
DEC* ptr() const
|
||||
{ return (DEC*)&_dec; }
|
||||
// @cmember Ritorna il numero reale convetito in long double
|
||||
long double ld() const;
|
||||
// @cmember Trasforma un reale in stringa
|
||||
const char* string(int len = 0, int dec = UNDEFINED, char pad = ' ') const;
|
||||
// @cmember Trasforma un reale in stringa (chiama <mf real::string>), ma
|
||||
@ -359,8 +233,6 @@ real cos(const real& a) ;
|
||||
real tan(const real& a) ;
|
||||
real abs(const real& a) ;
|
||||
|
||||
#endif
|
||||
|
||||
class TDistrib : public TObject
|
||||
|
||||
// @author:(INTERNAL) Villa
|
||||
@ -515,7 +387,7 @@ public:
|
||||
{ return _valore; }
|
||||
|
||||
// @cmember Controlla se l'importo e' 0 (in qualsiasi sezione, TRUE se 0)
|
||||
bool is_zero() const;
|
||||
bool is_zero() const { return _valore.is_zero(); }
|
||||
|
||||
// @cmember Assegna l'importo passato
|
||||
const TImporto& operator=(const TImporto& i)
|
||||
|
Loading…
x
Reference in New Issue
Block a user