Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

ASTArray.hpp

Go to the documentation of this file.
00001 #ifndef INC_ASTArray_hpp__
00002 #define INC_ASTArray_hpp__
00003 
00004 /* ANTLR Translator Generator
00005  * Project led by Terence Parr at http://www.jGuru.com
00006  * Software rights: http://www.antlr.org/license.html
00007  *
00008  * $Id: ASTArray.hpp,v 1.1 2004/10/08 16:27:34 dfisher Exp $
00009  */
00010 
00011 #include <antlr/config.hpp>
00012 #include <antlr/AST.hpp>
00013 
00014 #ifdef ANTLR_CXX_SUPPORTS_NAMESPACE
00015 namespace antlr {
00016 #endif
00017 
00023 class ANTLR_API ASTArray {
00024 public:
00025         int size; // = 0;
00026         ANTLR_USE_NAMESPACE(std)vector<RefAST> array;
00027 
00028         ASTArray(int capacity)
00029         : size(0)
00030         , array(capacity)
00031         {
00032         }
00033 
00034         ASTArray* add(RefAST node)
00035         {
00036                 array[size++] = node;
00037                 return this;
00038         }
00039 };
00040 
00041 #ifdef ANTLR_CXX_SUPPORTS_NAMESPACE
00042 }
00043 #endif
00044 
00045 #endif //INC_ASTArray_hpp__

Generated on Wed Nov 3 12:58:51 2004 for Lemur Toolkit by doxygen1.2.18