1#ifndef INC_ASTNULLType_hpp__
2#define INC_ASTNULLType_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/ASTNULLType.hpp#2 $
9 */
10
11#include <antlr/config.hpp>
12#include <antlr/AST.hpp>
13#include <vector>
14#include <string>
15#include <istream>
16#include <ostream>
17
18#ifdef ANTLR_CXX_SUPPORTS_NAMESPACE
19namespace antlr {
20#endif
21
22/** There is only one instance of this class **/
23class ANTLR_API ASTNULLType : public AST {
24public:
25	const char* typeName( void ) const;
26	RefAST clone( void ) const;
27
28	void addChild(RefAST c);
29	size_t getNumberOfChildren() const;
30	void setFirstChild(RefAST c);
31	void setNextSibling(RefAST n);
32
33	bool equals(RefAST t) const;
34	bool equalsList(RefAST t) const;
35	bool equalsListPartial(RefAST t) const;
36	bool equalsTree(RefAST t) const;
37	bool equalsTreePartial(RefAST t) const;
38
39	ANTLR_USE_NAMESPACE(std)vector<RefAST> findAll(RefAST tree);
40	ANTLR_USE_NAMESPACE(std)vector<RefAST> findAllPartial(RefAST subtree);
41
42	RefAST getFirstChild() const;
43	RefAST getNextSibling() const;
44
45	ANTLR_USE_NAMESPACE(std)string getText() const;
46	int getType() const;
47
48	void initialize(int t, const ANTLR_USE_NAMESPACE(std)string& txt);
49	void initialize(RefAST t);
50	void initialize(RefToken t);
51	void initialize(ANTLR_USE_NAMESPACE(std)istream& infile);
52
53	void setText(const ANTLR_USE_NAMESPACE(std)string& text);
54	void setType(int ttype);
55	ANTLR_USE_NAMESPACE(std)string toString() const;
56	ANTLR_USE_NAMESPACE(std)string toStringList() const;
57	ANTLR_USE_NAMESPACE(std)string toStringTree() const;
58
59	bool attributesToStream( ANTLR_USE_NAMESPACE(std)ostream &out ) const;
60	void toStream( ANTLR_USE_NAMESPACE(std)ostream &out ) const;
61};
62
63#ifdef ANTLR_CXX_SUPPORTS_NAMESPACE
64}
65#endif
66
67#endif //INC_ASTNULLType_hpp__
68