Class: Supabase::Storage::Types::Bucket
- Inherits:
-
Struct
- Object
- Struct
- Supabase::Storage::Types::Bucket
- Defined in:
- lib/supabase/storage/types.rb
Overview
Returned by list_buckets / get_bucket. Mirrors storage3’s BaseBucket fields.
Instance Attribute Summary collapse
-
#allowed_mime_types ⇒ Object
Returns the value of attribute allowed_mime_types.
-
#created_at ⇒ Object
Returns the value of attribute created_at.
-
#file_size_limit ⇒ Object
Returns the value of attribute file_size_limit.
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
-
#owner ⇒ Object
Returns the value of attribute owner.
-
#public ⇒ Object
Returns the value of attribute public.
-
#type ⇒ Object
Returns the value of attribute type.
-
#updated_at ⇒ Object
Returns the value of attribute updated_at.
Class Method Summary collapse
Instance Attribute Details
#allowed_mime_types ⇒ Object
Returns the value of attribute allowed_mime_types
22 23 24 |
# File 'lib/supabase/storage/types.rb', line 22 def allowed_mime_types @allowed_mime_types end |
#created_at ⇒ Object
Returns the value of attribute created_at
22 23 24 |
# File 'lib/supabase/storage/types.rb', line 22 def created_at @created_at end |
#file_size_limit ⇒ Object
Returns the value of attribute file_size_limit
22 23 24 |
# File 'lib/supabase/storage/types.rb', line 22 def file_size_limit @file_size_limit end |
#id ⇒ Object
Returns the value of attribute id
22 23 24 |
# File 'lib/supabase/storage/types.rb', line 22 def id @id end |
#name ⇒ Object
Returns the value of attribute name
22 23 24 |
# File 'lib/supabase/storage/types.rb', line 22 def name @name end |
#owner ⇒ Object
Returns the value of attribute owner
22 23 24 |
# File 'lib/supabase/storage/types.rb', line 22 def owner @owner end |
#public ⇒ Object
Returns the value of attribute public
22 23 24 |
# File 'lib/supabase/storage/types.rb', line 22 def public @public end |
#type ⇒ Object
Returns the value of attribute type
22 23 24 |
# File 'lib/supabase/storage/types.rb', line 22 def type @type end |
#updated_at ⇒ Object
Returns the value of attribute updated_at
22 23 24 |
# File 'lib/supabase/storage/types.rb', line 22 def updated_at @updated_at end |
Class Method Details
.from_hash(hash) ⇒ Object
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/supabase/storage/types.rb', line 27 def self.from_hash(hash) return nil if hash.nil? h = hash.transform_keys(&:to_s) new( id: h["id"], name: h["name"], owner: h["owner"], public: h["public"], file_size_limit: h["file_size_limit"], allowed_mime_types: h["allowed_mime_types"], created_at: h["created_at"], updated_at: h["updated_at"], type: h["type"] ) end |