00001 // See the file LICENSE in the some directory as this file for legal 00002 // notices about this software. 00003 #ifndef DEV_W3_ORG__2001_BLINDFOLD_SRC_SIMPLEVARIABLESCOPE_H 00004 #define DEV_W3_ORG__2001_BLINDFOLD_SRC_SIMPLEVARIABLESCOPE_H 00005 // $Id: SimpleVariableScope_8h-source.html,v 1.5 2001/10/10 20:40:58 sandro Exp $ 00006 #include "config.h" 00007 #include "Triple.h" 00008 #include "VariableScope.h" 00009 00019 class SimpleVariableScope : public VariableScope { 00020 00021 public: 00022 00023 // STANDARD MEMBER FUNCTIONS 00024 SimpleVariableScope(); 00025 SimpleVariableScope(const SimpleVariableScope& other); 00026 const SimpleVariableScope& operator=(const SimpleVariableScope& other); 00027 bool operator==(const SimpleVariableScope& other) const; 00028 bool operator<(const SimpleVariableScope& other) const; 00029 size_t hash() const; 00030 friend std::ostream& operator<<(std::ostream& s, const SimpleVariableScope& me); 00031 std::ostream& print_to(std::ostream& stream) const; 00032 virtual ~SimpleVariableScope(); 00033 00034 // (RE)IMPLEMENTATION OF INHERITED MEMBERS 00035 virtual size_t getNumVars() const; 00036 virtual Symbol getVar(size_t index) const; 00037 virtual Symbol getVar(const char* name, bool* added_ptr=0); 00038 virtual size_t getVarIndex(const char* name); 00039 virtual bool contains(const Triple& t) const; 00040 00041 // CLASS-SPECIFIC PUBLIC INTERFACE 00042 00043 private: 00044 00045 protected: 00046 00047 SymbolTable table; 00048 00049 }; 00050 00051 STANDARD_EXTERNAL(SimpleVariableScope) 00052 00053 #endif /* DEV_W3_ORG__2001_BLINDFOLD_SRC_SIMPLEVARIABLESCOPE_H */ // -*-C++-*-