Annotation of parser3/src/include/pa_vbool.h, revision 1.3

1.1       paf         1: /*
1.3     ! paf         2:   $Id: pa_vbool.h,v 1.2 2001/03/08 12:19:19 paf Exp $
1.1       paf         3: */
                      4: 
                      5: #ifndef PA_VBOOL_H
                      6: #define PA_VBOOL_H
                      7: 
                      8: #include "pa_value.h"
                      9: #include "pa_common.h"
                     10: 
                     11: #define MAX_BOOL_AS_STRING 20
                     12: 
                     13: class VBool : public Value {
                     14: public: // Value
                     15: 
                     16:        // all: for error reporting after fail(), etc
                     17:        const char *type() const { return "bool"; }
1.2       paf        18:        // bool: fvalue
                     19:        bool get_bool() { return fvalue; };
                     20:        // bool: fvalue
                     21:        double get_double() { return fvalue; };
1.1       paf        22: 
                     23: public: // usage
                     24: 
                     25:        VBool(Pool& apool, bool avalue/*=false*/) : Value(apool), 
1.2       paf        26:                fvalue(avalue) {
1.1       paf        27:        }
                     28: 
                     29: private:
                     30: 
1.2       paf        31:        bool fvalue;
1.1       paf        32: 
                     33: };
                     34: 
                     35: #endif

E-mail: