class Arborist::SequenceTree

Defined in:

parse_tree.cr

Constructors

Instance Method Summary

Instance methods inherited from class Arborist::ParseTree

capture(name : String) : ParseTree capture, capture?(name : String) : ParseTree | Nil capture?, captures(name : String) : Array(ParseTree)
captures : Hash(String, Array(ParseTree))
captures
, child : ParseTree child, child? : ParseTree | Nil child?, children : Array(ParseTree) children, descendants : Array(ParseTree) descendants, enclosing_rule_name : String | Nil enclosing_rule_name, finishing_pos : Int32 finishing_pos, finishing_pos=(finishing_pos : Int32) finishing_pos=, input : CharArray input, input=(input : CharArray) input=, label : String | Nil label, label=(label : String | Nil) label=, labeled? labeled?, local_captures : Hash(String, Array(ParseTree)) local_captures, parent : ParseTree | Nil parent, parent=(parent : ParseTree | Nil) parent=, parse_tree_type_specific_attributes_to_msgpack(packer : MessagePack::Packer) parse_tree_type_specific_attributes_to_msgpack, postorder_traverse(&visit : ParseTree -> _)
postorder_traverse(visit : ParseTree -> _)
postorder_traverse
, preorder_traverse(visit : ParseTree -> _) preorder_traverse, recursively_populate_parents(parent : ParseTree | Nil = nil) recursively_populate_parents, root root, root? root?, s_exp(indent : Int32 = 0) : String s_exp, self_and_descendants : Array(ParseTree) self_and_descendants, set_label(label : Nil | String) set_label, simple_s_exp : String simple_s_exp, start_pos : Int32 start_pos, start_pos=(start_pos : Int32) start_pos=, syntax_tree : SyntaxTree syntax_tree, terminal? terminal?, text : String text, to_msgpack(packer : MessagePack::Packer) to_msgpack, visit(visitor : Visitor(R)) forall R visit

Constructor methods inherited from class Arborist::ParseTree

new new

Class methods inherited from class Arborist::ParseTree

to_msgpack(parse_tree : ParseTree) : Bytes to_msgpack

Constructor Detail

def self.new(seq : Array(Arborist::ParseTree), input : CharArray, start_pos, finishing_pos) #

[View source]

Instance Method Detail

def children : Array(ParseTree) #
Description copied from class Arborist::ParseTree

children returns the list of all actual/literal child ParseTree nodes in parse tree structure, rather than skipping some, as with #terms Another way of thinking about this is #children returns concrete children, #terms returns logical children.


[View source]
def label(label : String | Nil) : SequenceTree #

[View source]
def s_exp(indent : Int32 = 0) : String #

[View source]
def seq : Array(ParseTree) #

[View source]
def seq=(seq : Array(ParseTree)) #

[View source]
def simple_s_exp : String #

[View source]
def syntax_tree : SyntaxTree #

[View source]