Home | History | Annotate | Download | only in antlr3

Lines Matching refs:token_source

313   attr_reader :token_source
760 # constructs a new token stream using the +token_source+ provided. +token_source+ is
780 def initialize( token_source, options = {} )
781 case token_source
785 stream = token_source
786 @token_source = stream.token_source
791 @token_source = token_source
793 @source_name = options.fetch( :source_name ) { @token_source.source_name rescue nil }
794 tokens = @token_source.to_a
808 # If no +token_source+ value is provided, the stream will attempt to reset the
809 # current +token_source+ by calling +reset+ on the object. The stream will
814 def rebuild( token_source = nil )
815 if token_source.nil?
816 @token_source.reset rescue nil
817 else @token_source = token_source
819 @tokens = block_given? ? @token_source.select { |token| yield( token ) } :
820 @token_source.to_a
839 @token_source.token_class
1070 string = "#<%p: @token_source=%p @ %p/%p" %
1071 [ self.class, @token_source.class, @position, @tokens.length ]