Sha256: 964943dd012b097ca36346520afa64d1f2315a675f373bbfc62ef616a475d354

Contents?: true

Size: 458 Bytes

Versions: 47

Compression:

Stored size: 458 Bytes

Contents

require 'protobuf/generators/base'

module Protobuf
  module Generators
    class OptionGenerator < Base
      def compile
        run_once(:compile) do
          descriptor.each_field.map do |field, value|
            next unless descriptor.field?(field.name)
            serialized_value = serialize_value(value)
            puts "set_option #{field.fully_qualified_name.inspect}, #{serialized_value}"
          end
        end
      end
    end
  end
end

Version data entries

47 entries across 47 versions & 4 rubygems

Version Path
protobuf-cucumber-3.10.4 lib/protobuf/generators/option_generator.rb
protobuf-3.10.3 lib/protobuf/generators/option_generator.rb
protobuf-3.10.2 lib/protobuf/generators/option_generator.rb
protobuf-3.10.1 lib/protobuf/generators/option_generator.rb
protobuf-3.10.0 lib/protobuf/generators/option_generator.rb
protobuf-3.10.0.pre0 lib/protobuf/generators/option_generator.rb
protobuf-3.9.0 lib/protobuf/generators/option_generator.rb
protobuf-3.9.0.pre2 lib/protobuf/generators/option_generator.rb
protobuf-3.9.0.pre lib/protobuf/generators/option_generator.rb
protobuf-3.8.5 lib/protobuf/generators/option_generator.rb
protobuf-3.8.5.pre0 lib/protobuf/generators/option_generator.rb
protobuf-3.8.4 lib/protobuf/generators/option_generator.rb
protobuf-3.8.3 lib/protobuf/generators/option_generator.rb
protobuf-3.8.2 lib/protobuf/generators/option_generator.rb
protobuf-3.8.1 lib/protobuf/generators/option_generator.rb
protobuf-3.8.0 lib/protobuf/generators/option_generator.rb
protobuf-3.8.0.pre1 lib/protobuf/generators/option_generator.rb
protobuf-3.7.5 lib/protobuf/generators/option_generator.rb
protobuf-3.7.4 lib/protobuf/generators/option_generator.rb
protobuf-3.7.3 lib/protobuf/generators/option_generator.rb