示例#1
0
 def declaration_type(self):
     traversal = 'identifierToType()'
     projection = ['code']
     result = jutils.raw_lookup(self.node_selection, traversal, projection)
     if result:
         return result[0][0]
     else:
         return None
示例#2
0
 def traverse_to_using_conditions(self):
     traversal = 'symbolToUsingConditions()'
     result = jutils.raw_lookup(self.node_selection, traversal = traversal)
     return map(lambda x : Condition(x[0], x[1].get_properties()), result)
示例#3
0
 def return_value(self):
     traversal = 'calleeToReturnValue()'
     result = jutils.raw_lookup(self.node_selection, traversal = traversal)
     return map(lambda x : Symbol(x[0], x[1].get_properties()), result)
示例#4
0
文件: Node.py 项目: MLDroid/chucky-ng
 def load_properties(self):
     _, node = jutils.raw_lookup(self.node_selection)[0]
     self.properties = node.get_properties()
示例#5
0
 def api_symbol_nodes(self):
     traversal = 'functionToAPISymbolNodes()'
     result = jutils.raw_lookup(self.node_selection, traversal)
     return map(lambda x : ASTNode(x[0], x[1].get_properties()), result)
示例#6
0
 def load_properties(self):
     _, node = jutils.raw_lookup(self.node_selection)[0]
     self.properties = node.get_properties()
示例#7
0
 def api_symbol_nodes(self):
     traversal = 'functionToAPISymbolNodes()'
     result = jutils.raw_lookup(self.node_selection, traversal)
     return map(lambda x: ASTNode(x[0], x[1].get_properties()), result)
示例#8
0
 def children(self):
     traversal = 'children()'
     result = jutils.raw_lookup(self.node_selection, traversal = traversal)
     return map(lambda x : ASTNode(x[0], x[1].get_properties()), result)
示例#9
0
 def traverse_to_using_conditions(self):
     traversal = 'symbolToUsingConditions()'
     result = jutils.raw_lookup(self.node_selection, traversal=traversal)
     return map(lambda x: Condition(x[0], x[1].get_properties()), result)