Class: NodeVisitor::Adapter
- Inherits:
-
Object
- Object
- NodeVisitor::Adapter
- Defined in:
- lib/node_visitor/adapter.rb
Overview
Abstract Adapter class
Instance Method Summary collapse
-
#get_children(node) ⇒ Array<Node>
Get the children of node.
-
#get_node_type(node) ⇒ Symbol
Get the type of node.
-
#is_node?(node) ⇒ Boolean
Check if it is a node.
Instance Method Details
#get_children(node) ⇒ Array<Node>
Get the children of node
21 22 23 |
# File 'lib/node_visitor/adapter.rb', line 21 def get_children(node) raise NotImplementedError, 'get_children is not implemented' end |
#get_node_type(node) ⇒ Symbol
Get the type of node
14 15 16 |
# File 'lib/node_visitor/adapter.rb', line 14 def get_node_type(node) raise NotImplementedError, 'get_node_type is not implemented' end |
#is_node?(node) ⇒ Boolean
Check if it is a node
7 8 9 |
# File 'lib/node_visitor/adapter.rb', line 7 def is_node?(node) raise NotImplementedError, 'get_node_type is not implemented' end |