mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
37 lines
881 B
Ruby
37 lines
881 B
Ruby
module Fog
|
|
module Rackspace
|
|
class Storage
|
|
class Real
|
|
|
|
# List number of objects and total bytes stored
|
|
#
|
|
# ==== Parameters
|
|
# * container<~String> - Name of container to retrieve info for
|
|
#
|
|
# ==== Returns
|
|
# * response<~Excon::Response>:
|
|
# * headers<~Hash>:
|
|
# * 'X-Container-Object-Count'<~String> - Count of containers
|
|
# * 'X-Container-Bytes-Used'<~String> - Bytes used
|
|
def head_container(container)
|
|
response = storage_request(
|
|
:expects => 204,
|
|
:method => 'HEAD',
|
|
:path => container,
|
|
:query => {'format' => 'json'}
|
|
)
|
|
response
|
|
end
|
|
|
|
end
|
|
|
|
class Mock
|
|
|
|
def head_container(container)
|
|
Fog::Mock.not_implemented
|
|
end
|
|
|
|
end
|
|
end
|
|
end
|
|
end
|