Sha256: 01b695e34dbada29be4b1774f044c8c4e0b77369fc91d01eacdb36c2cc88dbbc

Contents?: true

Size: 207 Bytes

Versions: 12

Compression:

Stored size: 207 Bytes

Contents

module Grape
  module Formatter
    module Txt
      class << self

        def call(object, env)
          object.respond_to?(:to_txt) ? object.to_txt : object.to_s
        end

      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
grape-0.6.1 lib/grape/formatter/txt.rb
grape-0.6.0 lib/grape/formatter/txt.rb
grape-0.5.0 lib/grape/formatter/txt.rb
grape-0.4.1 lib/grape/formatter/txt.rb
grape-0.4.0 lib/grape/formatter/txt.rb
grape-0.3.2 lib/grape/formatter/txt.rb
grape-0.3.1 lib/grape/formatter/txt.rb
grape-0.3.0 lib/grape/formatter/txt.rb
grape-0.2.6 lib/grape/formatter/txt.rb
grape-0.2.5 lib/grape/formatter/txt.rb
grape-0.2.4 lib/grape/formatter/txt.rb
grape-0.2.3 lib/grape/formatter/txt.rb