Sha256: e41e40582b71a5f582c5bf51a3980e7f0a37a3803c6b3f2d8299835b57e28e08

Contents?: true

Size: 563 Bytes

Versions: 13

Compression:

Stored size: 563 Bytes

Contents

require "jruby-parser"

module Rsense
  module Server
    class Parser
      include JRubyParser
      PCONFIG = org.jrubyparser.parser.ParserConfiguration

      def parse_string(source_string, filename='')
        filename = filename || '(string)'
        version = org.jrubyparser.CompatVersion::RUBY2_0
        config = PCONFIG.new(0, version)
        config.setSyntax(PCONFIG::SyntaxGathering::COMMENTS);
        reader = java.io.StringReader.new(source_string)
        org.jrubyparser.Parser.new.parse(filename, reader, config)
      end

    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
rsense-server-0.5.18 lib/rsense/server/parser.rb
rsense-server-0.5.17 lib/rsense/server/parser.rb
rsense-server-0.5.16 lib/rsense/server/parser.rb
rsense-server-0.5.15 lib/rsense/server/parser.rb
rsense-server-0.5.14 lib/rsense/server/parser.rb
rsense-server-0.5.13 lib/rsense/server/parser.rb
rsense-server-0.5.12 lib/rsense/server/parser.rb
rsense-server-0.5.11 lib/rsense/server/parser.rb
rsense-server-0.5.10 lib/rsense/server/parser.rb
rsense-server-0.5.9 lib/rsense/server/parser.rb
rsense-server-0.5.8 lib/rsense/server/parser.rb
rsense-server-0.5.7 lib/rsense/server/parser.rb
rsense-server-0.5.6 lib/rsense/server/parser.rb