Home
last modified time | relevance | path

Searched refs:adaptor (Results 1 – 25 of 241) sorted by relevance

12345678910

/external/antlr/antlr-3.4/runtime/C/src/
Dantlr3basetreeadaptor.c44 static pANTLR3_BASE_TREE nilNode (pANTLR3_BASE_TREE_ADAPTOR adaptor);
45 static pANTLR3_BASE_TREE dbgNil (pANTLR3_BASE_TREE_ADAPTOR adaptor);
46 static pANTLR3_BASE_TREE dupTree (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t);
47 static pANTLR3_BASE_TREE dbgDupTree (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t);
48 static pANTLR3_BASE_TREE dupTreeTT (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t, pANT…
49 static void addChild (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t, pANTLR3_BASE_TR…
50 static void dbgAddChild (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t, pANTLR3_BASE…
51 static pANTLR3_BASE_TREE becomeRoot (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE newRoo…
52 static pANTLR3_BASE_TREE dbgBecomeRoot (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE newR…
53 static pANTLR3_BASE_TREE rulePostProcessing (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE …
[all …]
Dantlr3commontreeadaptor.c46 static pANTLR3_BASE_TREE dupNode (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE treeNod…
48 static pANTLR3_BASE_TREE dbgCreate (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_COMMON_TOKEN pay…
49 static pANTLR3_COMMON_TOKEN createToken (pANTLR3_BASE_TREE_ADAPTOR adaptor, ANTLR3_UINT32 tokenT…
50 static pANTLR3_COMMON_TOKEN createTokenFromToken (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_COMMON…
51 static pANTLR3_COMMON_TOKEN getToken (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t);
52 static pANTLR3_STRING getText (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t);
53 static ANTLR3_UINT32 getType (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t);
54 static pANTLR3_BASE_TREE getChild (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t, ANTL…
55 static ANTLR3_UINT32 getChildCount (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE t);
56 static void replaceChildren (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_TREE parent, ANT…
[all …]
/external/antlr/antlr-3.4/runtime/C/include/
Dantlr3basetreeadaptor.h73 void * (*nilNode) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor);
76 void * (*dupTree) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor, void * tree);
77 …void * (*dupTreeTT) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor, void * t, void * …
79 …void (*addChild) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor, void * t, void * child);
80 …void (*addChildToken) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor, void * t, pANTLR3_CO…
81 …void (*setParent) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor, void * child, void * pa…
82 void * (*getParent) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor, void * child);
84 …void * (*errorNode) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor, pANTLR3_TOKEN_STREAM …
85 ANTLR3_BOOLEAN (*isNilNode) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor, void * t);
87 …void * (*becomeRoot) (struct ANTLR3_BASE_TREE_ADAPTOR_struct * adaptor, void * newRoot, v…
[all …]
/external/smali/smali/src/main/java/org/jf/smali/
DsmaliParser.java301 protected TreeAdaptor adaptor = new CommonTreeAdaptor(); field in smaliParser
303 public void setTreeAdaptor(TreeAdaptor adaptor) { in setTreeAdaptor() argument
304 this.adaptor = adaptor; in setTreeAdaptor()
307 return adaptor; in getTreeAdaptor()
514 RewriteRuleTokenStream stream_EOF=new RewriteRuleTokenStream(adaptor,"token EOF"); in smali_file()
515 RewriteRuleSubtreeStream stream_field=new RewriteRuleSubtreeStream(adaptor,"rule field"); in smali_file()
516 …RewriteRuleSubtreeStream stream_annotation=new RewriteRuleSubtreeStream(adaptor,"rule annotation"); in smali_file()
517 …RewriteRuleSubtreeStream stream_super_spec=new RewriteRuleSubtreeStream(adaptor,"rule super_spec"); in smali_file()
518 …RewriteRuleSubtreeStream stream_implements_spec=new RewriteRuleSubtreeStream(adaptor,"rule impleme… in smali_file()
519 …RewriteRuleSubtreeStream stream_source_spec=new RewriteRuleSubtreeStream(adaptor,"rule source_spec… in smali_file()
[all …]
/external/antlr/antlr-3.4/runtime/CSharp3/Sources/Antlr3.Runtime.Debug/
DDebugTreeAdaptor.cs56 protected ITreeAdaptor adaptor; field in Antlr.Runtime.Debug.DebugTreeAdaptor
58 public DebugTreeAdaptor( IDebugEventListener dbg, ITreeAdaptor adaptor ) in DebugTreeAdaptor() argument
61 this.adaptor = adaptor; in DebugTreeAdaptor()
71 object node = adaptor.Create( payload ); in Create()
79 object node = adaptor.ErrorNode( input, start, stop, e ); in ErrorNode()
89 object t = adaptor.DupTree( tree ); in DupTree()
101 int n = adaptor.GetChildCount( t ); in SimulateTreeConstruction()
104 object child = adaptor.GetChild( t, i ); in SimulateTreeConstruction()
112 object d = adaptor.DupNode( treeNode ); in DupNode()
119 object d = adaptor.DupNode(type, treeNode); in DupNode()
[all …]
DTraceDebugEventListener.cs43 ITreeAdaptor adaptor; field in Antlr.Runtime.Debug.TraceDebugEventListener
45 public TraceDebugEventListener( ITreeAdaptor adaptor ) in TraceDebugEventListener() argument
47 this.adaptor = adaptor; in TraceDebugEventListener()
75 int ID = adaptor.GetUniqueID( t ); in ConsumeNode()
76 string text = adaptor.GetText( t ); in ConsumeNode()
77 int type = adaptor.GetType( t ); in ConsumeNode()
83 int ID = adaptor.GetUniqueID( t ); in LT()
84 string text = adaptor.GetText( t ); in LT()
85 int type = adaptor.GetType( t ); in LT()
96 Console.Out.WriteLine( "nilNode " + adaptor.GetUniqueID( t ) ); in NilNode()
[all …]
/external/antlr/antlr-3.4/runtime/CSharp2/Sources/Antlr3.Runtime/Antlr.Runtime.Debug/
DDebugTreeAdaptor.cs54 protected ITreeAdaptor adaptor; field in Antlr.Runtime.Debug.DebugTreeAdaptor
56 public DebugTreeAdaptor(IDebugEventListener dbg, ITreeAdaptor adaptor) { in DebugTreeAdaptor() argument
58 this.adaptor = adaptor; in DebugTreeAdaptor()
66 object node = adaptor.Create(payload); in Create()
73 object node = adaptor.ErrorNode(input, start, stop, e); in ErrorNode()
81 object t = adaptor.DupTree(tree); in DupTree()
92 int n = adaptor.GetChildCount(t); in SimulateTreeConstruction()
94 object child = adaptor.GetChild(t, i); in SimulateTreeConstruction()
101 object d = adaptor.DupNode(treeNode); in DupNode()
107 object node = adaptor.Nil(); in Nil()
[all …]
DTraceDebugEventListener.cs41 ITreeAdaptor adaptor; field in Antlr.Runtime.Debug.TraceDebugEventListener
43 public TraceDebugEventListener(ITreeAdaptor adaptor) { in TraceDebugEventListener() argument
44 this.adaptor = adaptor; in TraceDebugEventListener()
66 int ID = adaptor.GetUniqueID(t); in ConsumeNode()
67 string text = adaptor.GetText(t); in ConsumeNode()
68 int type = adaptor.GetType(t); in ConsumeNode()
73 int ID = adaptor.GetUniqueID(t); in LT()
74 string text = adaptor.GetText(t); in LT()
75 int type = adaptor.GetType(t); in LT()
85 Console.Out.WriteLine("nilNode " + adaptor.GetUniqueID(t)); in NilNode()
[all …]
/external/antlr/antlr-3.4/runtime/ObjC/Framework/examples/simplecTreeParser/
DSimpleCParser.java52 protected TreeAdaptor adaptor = new CommonTreeAdaptor(); field in SimpleCParser
54 public void setTreeAdaptor(TreeAdaptor adaptor) { in setTreeAdaptor() argument
55 this.adaptor = adaptor; in setTreeAdaptor()
58 return adaptor; in getTreeAdaptor()
86 root_0 = (Object)adaptor.nil(); in program()
109 adaptor.addChild(root_0, declaration1.getTree()); in program()
128 retval.tree = (Object)adaptor.rulePostProcessing(root_0); in program()
129 adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop); in program()
135 retval.tree = (Object)adaptor.errorNode(input, retval.start, input.LT(-1), re); in program()
168 RewriteRuleTokenStream stream_21=new RewriteRuleTokenStream(adaptor,"token 21"); in declaration()
[all …]
/external/antlr/antlr-3.4/runtime/ObjC/Framework/examples/simplecTreeParser/output1/
DSimpleCParser.java52 protected TreeAdaptor adaptor = new CommonTreeAdaptor(); field in SimpleCParser
54 public void setTreeAdaptor(TreeAdaptor adaptor) { in setTreeAdaptor() argument
55 this.adaptor = adaptor; in setTreeAdaptor()
58 return adaptor; in getTreeAdaptor()
86 root_0 = (Object)adaptor.nil(); in program()
109 adaptor.addChild(root_0, declaration1.getTree()); in program()
128 retval.tree = (Object)adaptor.rulePostProcessing(root_0); in program()
129 adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop); in program()
135 retval.tree = (Object)adaptor.errorNode(input, retval.start, input.LT(-1), re); in program()
168 RewriteRuleTokenStream stream_21=new RewriteRuleTokenStream(adaptor,"token 21"); in declaration()
[all …]
/external/antlr/antlr-3.4/runtime/Java/src/main/java/org/antlr/runtime/debug/
DDebugTreeAdaptor.java49 protected TreeAdaptor adaptor; field in DebugTreeAdaptor
51 public DebugTreeAdaptor(DebugEventListener dbg, TreeAdaptor adaptor) { in DebugTreeAdaptor() argument
53 this.adaptor = adaptor; in DebugTreeAdaptor()
61 Object node = adaptor.create(payload); in create()
69 Object node = adaptor.errorNode(input, start, stop, e); in errorNode()
77 Object t = adaptor.dupTree(tree); in dupTree()
88 int n = adaptor.getChildCount(t); in simulateTreeConstruction()
90 Object child = adaptor.getChild(t, i); in simulateTreeConstruction()
97 Object d = adaptor.dupNode(treeNode); in dupNode()
103 Object node = adaptor.nil(); in nil()
[all …]
DTraceDebugEventListener.java35 TreeAdaptor adaptor; field in TraceDebugEventListener
37 public TraceDebugEventListener(TreeAdaptor adaptor) { in TraceDebugEventListener() argument
38 this.adaptor = adaptor; in TraceDebugEventListener()
50 int ID = adaptor.getUniqueID(t); in consumeNode()
51 String text = adaptor.getText(t); in consumeNode()
52 int type = adaptor.getType(t); in consumeNode()
57 int ID = adaptor.getUniqueID(t); in LT()
58 String text = adaptor.getText(t); in LT()
59 int type = adaptor.getType(t); in LT()
65 public void nilNode(Object t) {System.out.println("nilNode "+adaptor.getUniqueID(t));} in nilNode()
[all …]
/external/antlr/antlr-3.4/tool/src/main/resources/org/antlr/codegen/templates/Ruby/
DASTDbg.stg6 attr_reader :adaptor
7 def adaptor=( adaptor )
8 @adaptor =
9 adaptor.is_a?( ANTLR3::Debug::TreeAdaptor ) ? adaptor :
10 ANTLR3::Debug::TreeAdaptor.wrap( adaptor, @debug_listener )
11 <grammar.directDelegates:{g|<g:delegateName()>.adaptor = @adaptor}; separator="\n">
14 alias tree_adaptor adaptor
15 alias tree_adaptor= adaptor=
24 :adaptor => adaptor,
33 @parserConstructor.init() ::= "self.adaptor = adaptor"
[all …]
/external/antlr/antlr-3.4/runtime/Python/antlr3/
Ddebug.py215 def __init__(self, dbg, adaptor): argument
217 self.adaptor = adaptor
225 node = self.adaptor.createWithPayload(payload)
230 node = self.adaptor.createFromToken(tokenType, fromToken, text)
235 node = self.adaptor.createFromType(tokenType, text)
249 t = self.adaptor.dupTree(tree)
260 for i in range(self.adaptor.getChildCount(t)):
261 child = self.adaptor.getChild(t, i)
267 d = self.adaptor.dupNode(treeNode)
273 node = self.adaptor.nil()
[all …]
Ddottreegen.py80 def toDOT(self, tree, adaptor=None, treeST=_treeST, edgeST=_edgeST): argument
81 if adaptor is None:
82 adaptor = CommonTreeAdaptor()
87 self.toDOTDefineNodes(tree, adaptor, treeST)
90 self.toDOTDefineEdges(tree, adaptor, treeST, edgeST)
94 def toDOTDefineNodes(self, tree, adaptor, treeST, knownNodes=None): argument
101 n = adaptor.getChildCount(tree)
110 parentNodeST = self.getNodeST(adaptor, tree)
116 child = adaptor.getChild(tree, i)
120 nodeST = self.getNodeST(adaptor, child)
[all …]
/external/antlr/antlr-3.4/runtime/CSharp3/Sources/Antlr3.Runtime.Test/BuildOptions/
DDebugGrammarParser.cs68 DebugEventSocketProxy proxy = new DebugEventSocketProxy( this, port, adaptor ); in DebugGrammarParser()
102 protected DebugTreeAdaptor adaptor; field in DebugGrammarParser
108 return adaptor;
112 this.adaptor = new DebugTreeAdaptor(dbg,adaptor);
158 root_0 = (CommonTree)adaptor.Nil(); in prog()
200 adaptor.AddChild(root_0, stat1.Tree); in prog()
224 retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0); in prog()
225 adaptor.SetTokenBoundaries(retval.tree, retval.start, retval.stop); in prog()
232 retval.tree = (CommonTree)adaptor.ErrorNode(input, retval.start, input.LT(-1), re); in prog()
286 RewriteRuleITokenStream stream_NEWLINE=new RewriteRuleITokenStream(adaptor,"token NEWLINE"); in stat()
[all …]
DProfileGrammarParser.cs106 protected DebugTreeAdaptor adaptor; field in ProfileGrammarParser
112 return adaptor;
116 this.adaptor = new DebugTreeAdaptor(dbg,adaptor);
162 root_0 = (CommonTree)adaptor.Nil(); in prog()
204 adaptor.AddChild(root_0, stat1.Tree); in prog()
228 retval.tree = (CommonTree)adaptor.RulePostProcessing(root_0); in prog()
229 adaptor.SetTokenBoundaries(retval.tree, retval.start, retval.stop); in prog()
236 retval.tree = (CommonTree)adaptor.ErrorNode(input, retval.start, input.LT(-1), re); in prog()
290 RewriteRuleITokenStream stream_NEWLINE=new RewriteRuleITokenStream(adaptor,"token NEWLINE"); in stat()
291 RewriteRuleITokenStream stream_ID=new RewriteRuleITokenStream(adaptor,"token ID"); in stat()
[all …]
/external/antlr/antlr-3.4/runtime/Ruby/lib/antlr3/
Ddot.rb91 def self.generate( tree, adaptor = nil, tree_template = TREE_TEMPLATE, argument
93 new.to_dot( tree, adaptor, tree_template, edge_template )
105 def to_dot( tree, adaptor = nil, tree_template = TREE_TEMPLATE, argument
107 adaptor ||= AST::CommonTreeAdaptor.new
110 define_nodes( tree, adaptor, tree_template )
113 define_edges( tree, adaptor, tree_template, edge_template )
117 def define_nodes( tree, adaptor, tree_template, known_nodes = nil ) argument
120 n = adaptor.child_count( tree )
124 parent_node_template = node_template_for( adaptor, child )
130 child = adaptor.child_of( tree, index )
[all …]
/external/antlr/antlr-3.4/runtime/Java/src/main/java/org/antlr/runtime/tree/
DTreeIterator.java42 protected TreeAdaptor adaptor; field in TreeIterator
61 public TreeIterator(TreeAdaptor adaptor, Object tree) { in TreeIterator() argument
62 this.adaptor = adaptor; in TreeIterator()
66 down = adaptor.create(Token.DOWN, "DOWN"); in TreeIterator()
67 up = adaptor.create(Token.UP, "UP"); in TreeIterator()
68 eof = adaptor.create(Token.EOF, "EOF"); in TreeIterator()
81 if ( adaptor.getChildCount(tree)>0 ) return true; in hasNext()
82 return adaptor.getParent(tree)!=null; // back at root? in hasNext()
88 if ( adaptor.getChildCount(tree)==0 ) { // single node tree (special) in next()
101 if ( adaptor.getChildCount(tree)>0 ) { in next()
[all …]
DTreeWizard.java54 protected TreeAdaptor adaptor; field in TreeWizard
122 public TreeWizard(TreeAdaptor adaptor) { in TreeWizard() argument
123 this.adaptor = adaptor; in TreeWizard()
126 public TreeWizard(TreeAdaptor adaptor, Map tokenNameToTypeMap) { in TreeWizard() argument
127 this.adaptor = adaptor; in TreeWizard()
131 public TreeWizard(TreeAdaptor adaptor, String[] tokenNames) { in TreeWizard() argument
132 this.adaptor = adaptor; in TreeWizard()
185 int ttype = adaptor.getType(t); in _index()
192 int n = adaptor.getChildCount(t); in _index()
194 Object child = adaptor.getChild(t, i); in _index()
[all …]
/external/antlr/antlr-3.4/runtime/JavaScript/src/org/antlr/runtime/tree/
DCommonTreeNodeStream.js17 org.antlr.runtime.tree.CommonTreeNodeStream = function(adaptor, argument
22 tree = adaptor;
23 adaptor = new org.antlr.runtime.tree.CommonTreeAdaptor();
40 this.adaptor = adaptor;
42 this.down = this.adaptor.create(Token.DOWN, "DOWN");
43 this.up = this.adaptor.create(Token.UP, "UP");
44 this.eof = this.adaptor.create(Token.EOF, "EOF");
90 var nil = this.adaptor.isNil(t);
95 var n = this.adaptor.getChildCount(t);
102 child = this.adaptor.getChild(t,c);
[all …]
/external/antlr/antlr-3.4/runtime/CSharp2/Sources/Antlr3.Runtime/Antlr.Runtime.Tree/
DBufferedTreeNodeStream.cs137 ITreeAdaptor adaptor; field in Antlr.Runtime.Tree.BufferedTreeNodeStream
157 public BufferedTreeNodeStream(ITreeAdaptor adaptor, object tree) in BufferedTreeNodeStream() argument
158 : this(adaptor, tree, DEFAULT_INITIAL_BUFFER_SIZE) { in BufferedTreeNodeStream()
161 public BufferedTreeNodeStream(ITreeAdaptor adaptor, object tree, int initialBufferSize) { in BufferedTreeNodeStream() argument
163 this.adaptor = adaptor; in BufferedTreeNodeStream()
165 down = adaptor.Create(TokenTypes.Down, "DOWN"); in BufferedTreeNodeStream()
166 up = adaptor.Create(TokenTypes.Up, "UP"); in BufferedTreeNodeStream()
167 eof = adaptor.Create(TokenTypes.EndOfFile, "EOF"); in BufferedTreeNodeStream()
204 return adaptor;
207 adaptor = value;
[all …]
DTreeIterator.cs42 protected ITreeAdaptor adaptor; field in Antlr.Runtime.Tree.TreeIterator
61 public TreeIterator(ITreeAdaptor adaptor, object tree) { in TreeIterator() argument
62 this.adaptor = adaptor; in TreeIterator()
66 down = adaptor.Create(TokenTypes.Down, "DOWN"); in TreeIterator()
67 up = adaptor.Create(TokenTypes.Up, "UP"); in TreeIterator()
68 eof = adaptor.Create(TokenTypes.EndOfFile, "EOF"); in TreeIterator()
93 if (adaptor.GetChildCount(tree) == 0) { in MoveNext()
108 if (adaptor.GetChildCount(tree) > 0) { in MoveNext()
109 tree = adaptor.GetChild(tree, 0); in MoveNext()
114 object parent = adaptor.GetParent(tree); in MoveNext()
[all …]
/external/antlr/antlr-3.4/runtime/CSharp3/Sources/Antlr3.Runtime/Tree/
DBufferedTreeNodeStream.cs146 ITreeAdaptor adaptor; field in Antlr.Runtime.Tree.BufferedTreeNodeStream
167 public BufferedTreeNodeStream( ITreeAdaptor adaptor, object tree ) in BufferedTreeNodeStream() argument
168 : this( adaptor, tree, DEFAULT_INITIAL_BUFFER_SIZE ) in BufferedTreeNodeStream()
172 public BufferedTreeNodeStream( ITreeAdaptor adaptor, object tree, int initialBufferSize ) in BufferedTreeNodeStream() argument
175 this.adaptor = adaptor; in BufferedTreeNodeStream()
177 down = adaptor.Create( TokenTypes.Down, "DOWN" ); in BufferedTreeNodeStream()
178 up = adaptor.Create( TokenTypes.Up, "UP" ); in BufferedTreeNodeStream()
179 eof = adaptor.Create( TokenTypes.EndOfFile, "EOF" ); in BufferedTreeNodeStream()
228 return adaptor;
232 adaptor = value;
[all …]
DTreeIterator.cs44 protected ITreeAdaptor adaptor; field in Antlr.Runtime.Tree.TreeIterator
65 public TreeIterator( ITreeAdaptor adaptor, object tree ) in TreeIterator() argument
67 this.adaptor = adaptor; in TreeIterator()
71 down = adaptor.Create( TokenTypes.Down, "DOWN" ); in TreeIterator()
72 up = adaptor.Create( TokenTypes.Up, "UP" ); in TreeIterator()
73 eof = adaptor.Create( TokenTypes.EndOfFile, "EOF" ); in TreeIterator()
102 if ( adaptor.GetChildCount( tree ) == 0 ) in MoveNext()
126 if ( adaptor.GetChildCount( tree ) > 0 ) in MoveNext()
128 tree = adaptor.GetChild( tree, 0 ); in MoveNext()
135 object parent = adaptor.GetParent( tree ); in MoveNext()
[all …]

12345678910