class Deltacloud::Bucket

Attributes

blob_list[RW]
name[RW]
size[RW]

Public Instance Methods

to_hash(context) click to toggle source
# File lib/deltacloud/models/bucket.rb, line 28
def to_hash(context)
  {
    :id => self.id,
    :href => context.bucket_url(self.id),
    :name => name,
    :size => size,
    :blob_list => blob_list.map { |b| {
      :rel => :blob,
      :href => context.url("/buckets/#{self.id}/#{b}"), :id => b }
    }
  }
end