1 2 /* Web Polygraph http://www.web-polygraph.org/ 3 * Copyright 2003-2011 The Measurement Factory 4 * Licensed under the Apache License, Version 2.0 */ 5 6 #ifndef POLYGRAPH__PGL_PGLBOOLSYM_H 7 #define POLYGRAPH__PGL_PGLBOOLSYM_H 8 9 #include "pgl/PglExprSym.h" 10 11 class BoolSym: public ExpressionSym { 12 public: 13 static String TheType; 14 15 public: 16 BoolSym(bool aVal); 17 val()18 bool val() const { return theVal; } val(bool v)19 void val(bool v) { theVal = v; } 20 21 virtual bool isA(const String &type) const; 22 23 virtual ExpressionSym *unOper(const Oper &op) const; 24 virtual ExpressionSym *bnOper(const Oper &op, const SynSym &exp) const; 25 26 virtual ostream &print(ostream &os, const String &pfx) const; 27 28 protected: 29 virtual SynSym *dupe(const String &dType) const; 30 31 protected: 32 bool theVal; 33 }; 34 35 #endif 36