ANTLR Support Libraries 2.7.1+
BitSet.hpp
Go to the documentation of this file.
1 #ifndef INC_BitSet_hpp__
2 #define INC_BitSet_hpp__
3 
4 /* ANTLR Translator Generator
5  * Project led by Terence Parr at http://www.jGuru.com
6  * Software rights: http://www.antlr.org/license.html
7  *
8  * $Id: //depot/code/org.antlr/release/antlr-2.7.7/lib/cpp/antlr/BitSet.hpp#2 $
9  */
10 
11 #include <antlr/config.hpp>
12 #include <vector>
13 #include <stdexcept>
14 
15 #ifdef ANTLR_CXX_SUPPORTS_NAMESPACE
16 namespace antlr {
17 #endif
18 
41 private:
43 
44 public:
45  BitSet( unsigned int nbits=64 );
46  BitSet( const unsigned long* bits_, unsigned int nlongs);
47  ~BitSet();
48 
49  void add( unsigned int el );
50 
51  bool member( unsigned int el ) const;
52 
53  ANTLR_USE_NAMESPACE(std)vector<unsigned int> toArray() const;
54 };
55 
56 #ifdef ANTLR_CXX_SUPPORTS_NAMESPACE
57 }
58 #endif
59 
60 #endif //INC_BitSet_hpp__
Definition: ANTLRException.hpp:15
#define ANTLR_API
Definition: config.hpp:22
Definition: BitSet.hpp:40
#define ANTLR_USE_NAMESPACE(_x_)
Definition: config.hpp:18
std ::vector< bool > storage
Definition: BitSet.hpp:42