Sha256: 2bb28fea56c954d1cb6ca6b056f1b53988aa62aa185ee5ee5226b0050439996f

Contents?: true

Size: 694 Bytes

Versions: 13

Compression:

Stored size: 694 Bytes

Contents

# encoding: utf-8

module Antelope
  module Ace
    class Scanner

      # Scans the third part.  Everything after the content
      # boundry is copied directly into the output.
      module Third

        # Scans the third part.  It should start with a content
        # boundry; raises an error if it does not.  It then scans
        # until the end of the file.
        #
        # @raise [SyntaxError] if somehow there is no content
        #   boundry.
        # @return [void]
        def scan_third_part
          @scanner.scan(CONTENT_BOUNDRY) or error!

          tokens << [:third]
          tokens << [:copy, @scanner.scan(/[\s\S]+/m) || ""]
        end
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
antelope-0.4.1 lib/antelope/ace/scanner/third.rb
antelope-0.4.0 lib/antelope/ace/scanner/third.rb
antelope-0.2.0 lib/antelope/ace/scanner/third.rb
antelope-0.1.11 lib/antelope/ace/scanner/third.rb
antelope-0.1.10 lib/antelope/ace/scanner/third.rb
antelope-0.1.9 lib/antelope/ace/scanner/third.rb
antelope-0.1.8 lib/antelope/ace/scanner/third.rb
antelope-0.1.7 lib/antelope/ace/scanner/third.rb
antelope-0.1.6 lib/antelope/ace/scanner/third.rb
antelope-0.1.5 lib/antelope/ace/scanner/third.rb
antelope-0.1.4 lib/antelope/ace/scanner/third.rb
antelope-0.1.3 lib/antelope/ace/scanner/third.rb
antelope-0.1.2 lib/antelope/ace/scanner/third.rb