Class: BadgerVision::Client::ImageInformationResponse
- Inherits:
-
Object
- Object
- BadgerVision::Client::ImageInformationResponse
- Defined in:
- lib/badger_vision/client.rb
Instance Method Summary collapse
- #attributes ⇒ Object
-
#initialize(response) ⇒ ImageInformationResponse
constructor
A new instance of ImageInformationResponse.
- #scenes ⇒ Object
- #type ⇒ Object
Constructor Details
#initialize(response) ⇒ ImageInformationResponse
Returns a new instance of ImageInformationResponse.
30 31 32 |
# File 'lib/badger_vision/client.rb', line 30 def initialize(response) @response = response || {} end |
Instance Method Details
#attributes ⇒ Object
34 35 36 |
# File 'lib/badger_vision/client.rb', line 34 def attributes @response.fetch(:attributes, []).split(",").map(&:strip) end |
#scenes ⇒ Object
42 43 44 45 46 |
# File 'lib/badger_vision/client.rb', line 42 def scenes @response.fetch(:scenes, []).split(",").map(&:strip).map do |scene| Scene.new(parse_scene(scene)) end end |
#type ⇒ Object
38 39 40 |
# File 'lib/badger_vision/client.rb', line 38 def type @response.fetch(:type, nil) end |