Class: SyntaxTree::Database::IndexingVisitor

Inherits:
FieldVisitor show all
Defined in:
lib/syntax_tree/database.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from BasicVisitor

valid_visit_methods, #visit, #visit_all, #visit_child_nodes, visit_method, visit_methods

Constructor Details

#initialize(database, filepath) ⇒ IndexingVisitor

Returns a new instance of IndexingVisitor.



10
11
12
13
14
# File 'lib/syntax_tree/database.rb', line 10

def initialize(database, filepath)
  @database = database
  @filepath = filepath
  @node_id = nil
end

Instance Attribute Details

#databaseObject (readonly)

Returns the value of attribute database.



8
9
10
# File 'lib/syntax_tree/database.rb', line 8

def database
  @database
end

#filepathObject (readonly)

Returns the value of attribute filepath.



8
9
10
# File 'lib/syntax_tree/database.rb', line 8

def filepath
  @filepath
end

#node_idObject (readonly)

Returns the value of attribute node_id.



8
9
10
# File 'lib/syntax_tree/database.rb', line 8

def node_id
  @node_id
end