Sha256: 372883b844e91fe8f4581ea3ce4790892b34bd5a0dd001d2445505c2cfc70b96

Contents?: true

Size: 870 Bytes

Versions: 16

Compression:

Stored size: 870 Bytes

Contents

unless Fog.mocking?

  module Fog
    module Rackspace
      class Files

        # Create a new object
        #
        # ==== Parameters
        # * container<~String> - Name for container, should be < 256 bytes and must not contain '/'
        #
        def put_object(container, object, data)
          data = parse_data(data)
          response = storage_request(
            :body     => data[:body],
            :expects  => 201,
            :headers  => data[:headers],
            :method   => 'PUT',
            :path     => "#{CGI.escape(container)}/#{CGI.escape(object)}"
          )
          response
        end

      end
    end
  end

else

  module Fog
    module Rackspace
      class Servers

        def put_object(container, object, data)
          raise MockNotImplemented.new("Contributions welcome!")
        end

      end
    end
  end

end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
fog-0.0.58 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.57 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.56 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.55 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.54 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.53 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.52 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.51 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.50 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.49 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.48 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.47 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.46 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.45 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.44 lib/fog/rackspace/requests/files/put_object.rb
fog-0.0.43 lib/fog/rackspace/requests/files/put_object.rb