Sha256: 45868df664e99e6d162563de6409100aab68f38e27e29c4f66d1f64488352901

Contents?: true

Size: 580 Bytes

Versions: 17

Compression:

Stored size: 580 Bytes

Contents

module ChartMogul
  module API
    module Actions
      module All
        def self.included(base)
          base.extend ClassMethods
        end

        module ClassMethods
          def all(options = {})
            resp = handling_errors do
              connection.get(resource_path.apply_with_get_params(options)) do |req|
                req.headers['Content-Type'] = 'application/json'
              end
            end
            json = ChartMogul::Utils::JSONParser.parse(resp.body)
            new_from_json(json)
          end
        end
      end
    end
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
chartmogul-ruby-1.5.1 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.5.0 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.4.1 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.4.0 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.3.3 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.3.2 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.3.1 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.3.0 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.2.2 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.2.1 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.2.0 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.1.9 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.1.8 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.1.7 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.1.3 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.1.1 lib/chartmogul/api/actions/all.rb
chartmogul-ruby-1.1.0 lib/chartmogul/api/actions/all.rb