Class: Buckets::BucketMetaObject
- Inherits:
-
Object
- Object
- Buckets::BucketMetaObject
- Defined in:
- lib/buckets.rb
Instance Attribute Summary collapse
-
#bucket_name ⇒ Object
Returns the value of attribute bucket_name.
-
#e_tag ⇒ Object
Returns the value of attribute e_tag.
-
#key ⇒ Object
Returns the value of attribute key.
-
#last_modified ⇒ Object
Returns the value of attribute last_modified.
-
#owner_display_name ⇒ Object
Returns the value of attribute owner_display_name.
-
#owner_id ⇒ Object
Returns the value of attribute owner_id.
-
#properties ⇒ Object
Returns the value of attribute properties.
-
#size ⇒ Object
Returns the value of attribute size.
-
#storage_class ⇒ Object
Returns the value of attribute storage_class.
Instance Method Summary collapse
-
#initialize(*args) ⇒ BucketMetaObject
constructor
A new instance of BucketMetaObject.
- #object ⇒ Object
- #object! ⇒ Object
Constructor Details
#initialize(*args) ⇒ BucketMetaObject
Returns a new instance of BucketMetaObject.
83 84 85 86 87 88 89 90 91 92 93 |
# File 'lib/buckets.rb', line 83 def initialize(*args) @properties = args.first @bucket_name = @properties[:bucket_name] @key = @properties[:key] @last_modified = @properties[:last_modified] @e_tag = @properties[:e_tag] @size = @properties[:size] @storage_class = @properties[:storage_class] @owner_id = @properties[:owner_id] @owner_display_name = @properties[:owner_display_name] end |
Instance Attribute Details
#bucket_name ⇒ Object
Returns the value of attribute bucket_name.
78 79 80 |
# File 'lib/buckets.rb', line 78 def bucket_name @bucket_name end |
#e_tag ⇒ Object
Returns the value of attribute e_tag.
78 79 80 |
# File 'lib/buckets.rb', line 78 def e_tag @e_tag end |
#key ⇒ Object
Returns the value of attribute key.
78 79 80 |
# File 'lib/buckets.rb', line 78 def key @key end |
#last_modified ⇒ Object
Returns the value of attribute last_modified.
78 79 80 |
# File 'lib/buckets.rb', line 78 def last_modified @last_modified end |
#owner_display_name ⇒ Object
Returns the value of attribute owner_display_name.
78 79 80 |
# File 'lib/buckets.rb', line 78 def owner_display_name @owner_display_name end |
#owner_id ⇒ Object
Returns the value of attribute owner_id.
78 79 80 |
# File 'lib/buckets.rb', line 78 def owner_id @owner_id end |
#properties ⇒ Object
Returns the value of attribute properties.
78 79 80 |
# File 'lib/buckets.rb', line 78 def properties @properties end |
#size ⇒ Object
Returns the value of attribute size.
78 79 80 |
# File 'lib/buckets.rb', line 78 def size @size end |
#storage_class ⇒ Object
Returns the value of attribute storage_class.
78 79 80 |
# File 'lib/buckets.rb', line 78 def storage_class @storage_class end |
Instance Method Details
#object ⇒ Object
95 96 97 |
# File 'lib/buckets.rb', line 95 def object @object ||= object! end |
#object! ⇒ Object
99 100 101 |
# File 'lib/buckets.rb', line 99 def object! CryptKeeper::Connection.http_instance.get("/#{URI.escape(@key)}", @bucket_name) end |