Class: Bskyrb::AppBskyEmbedImages::Image

Inherits:
Object
  • Object
show all
Defined in:
lib/bskyrb/generated_classes.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#altObject

Returns the value of attribute alt.



297
298
299
# File 'lib/bskyrb/generated_classes.rb', line 297

def alt
  @alt
end

#imageObject

Returns the value of attribute image.



295
296
297
# File 'lib/bskyrb/generated_classes.rb', line 295

def image
  @image
end

Class Method Details

.from_hash(hash) ⇒ Object



299
300
301
302
303
304
305
306
307
308
# File 'lib/bskyrb/generated_classes.rb', line 299

def self.from_hash(hash)
  # httparty-returned string-keyed hash
  instance = new

  instance.send(:image=, hash["image"])

  instance.send(:alt=, hash["alt"])

  instance
end