Module: ANTLR3::Template::Builder::ClassMethods

Defined in:
lib/antlr3/template.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#template_libraryObject


18
19
20
# File 'lib/antlr3/template.rb', line 18

def template_library
  @template_library ||= ANTLR3::Template::Group.new
end

Instance Method Details

#define_template(name, source, &block) ⇒ Object


31
32
33
# File 'lib/antlr3/template.rb', line 31

def define_template( name, source, &block )
  template_library.define_template( name, source, &block )
end

#load_templates(group_file) ⇒ Object


26
27
28
29
# File 'lib/antlr3/template.rb', line 26

def load_templates( group_file )
  @template_library = 
    ANTLR3::Template::Group.load( group_file )
end

#return_scope_membersObject


22
23
24
# File 'lib/antlr3/template.rb', line 22

def return_scope_members
  super.push( :template )
end