Class: ANTLR3::AST::Wizard::PatternAdaptor

Inherits:
CommonTreeAdaptor show all
Defined in:
lib/antlr3/tree/wizard.rb

Overview

A customized TreeAdaptor used by AST::Wizards to build tree patterns.

Constant Summary

Constant Summary

Constants included from Constants

Constants::BUILT_IN_TOKEN_NAMES, Constants::DEFAULT, Constants::DOWN, Constants::EOF, Constants::EOF_TOKEN, Constants::EOR_TOKEN_TYPE, Constants::HIDDEN, Constants::INVALID_TOKEN, Constants::INVALID_TOKEN_TYPE, Constants::MEMO_RULE_FAILED, Constants::MEMO_RULE_UNKNOWN, Constants::MIN_TOKEN_TYPE, Constants::SKIP_TOKEN, Constants::UP

Instance Attribute Summary

Attributes included from TokenFactory

#token_class

Instance Method Summary collapse

Methods inherited from CommonTreeAdaptor

#become_root, #create, #create_error_node, #create_flat_list, #create_from_token, #create_from_type, #each_child, #empty?, #initialize, #rule_post_processing

Methods included from TreeAdaptor

#add_child, #child_count, #child_index, #child_of, #copy_node, #copy_tree, #delete_child, #each_ancestor, #each_child, #empty?, #flat_list?, #parent, #replace_children, #rule_post_processing, #set_child_index, #set_parent, #set_token_boundaries, #text_of, #token, #token_start_index, #token_stop_index, #type_name, #type_of, #unique_id

Methods included from Error

#EarlyExit, #FailedPredicate, #MismatchedNotSet, #MismatchedRange, #MismatchedSet, #MismatchedToken, #MismatchedTreeNode, #MissingToken, #NoViableAlternative, #RewriteCardinalityError, #RewriteEarlyExit, #RewriteEmptyStream, #UnwantedToken

Methods included from TokenFactory

#create_token

Constructor Details

This class inherits a constructor from ANTLR3::AST::CommonTreeAdaptor

Instance Method Details

#create_with_payload(payload) ⇒ Object



321
322
323
# File 'lib/antlr3/tree/wizard.rb', line 321

def create_with_payload( payload )
  return Pattern.new( payload )
end