Class: ClarifaiRuby::TagResponse
- Inherits:
-
Object
- Object
- ClarifaiRuby::TagResponse
- Defined in:
- lib/clarifai_ruby/tag_response.rb
Instance Attribute Summary collapse
-
#meta ⇒ Object
readonly
Returns the value of attribute meta.
-
#model ⇒ Object
readonly
Returns the value of attribute model.
-
#status_code ⇒ Object
readonly
Returns the value of attribute status_code.
-
#status_msg ⇒ Object
readonly
Returns the value of attribute status_msg.
-
#tag_images ⇒ Object
readonly
Returns the value of attribute tag_images.
Instance Method Summary collapse
-
#initialize(json_response) ⇒ TagResponse
constructor
A new instance of TagResponse.
Constructor Details
#initialize(json_response) ⇒ TagResponse
Returns a new instance of TagResponse.
10 11 12 13 14 15 16 |
# File 'lib/clarifai_ruby/tag_response.rb', line 10 def initialize(json_response) @tag_images = generate_tag_images json_response["results"] @status_code = json_response["status_code"] @status_msg = json_response["status_msg"] @meta = json_response["meta"] @model = json_response["meta"]["tag"]["model"] end |
Instance Attribute Details
#meta ⇒ Object (readonly)
Returns the value of attribute meta.
3 4 5 |
# File 'lib/clarifai_ruby/tag_response.rb', line 3 def @meta end |
#model ⇒ Object (readonly)
Returns the value of attribute model.
3 4 5 |
# File 'lib/clarifai_ruby/tag_response.rb', line 3 def model @model end |
#status_code ⇒ Object (readonly)
Returns the value of attribute status_code.
3 4 5 |
# File 'lib/clarifai_ruby/tag_response.rb', line 3 def status_code @status_code end |
#status_msg ⇒ Object (readonly)
Returns the value of attribute status_msg.
3 4 5 |
# File 'lib/clarifai_ruby/tag_response.rb', line 3 def status_msg @status_msg end |
#tag_images ⇒ Object (readonly)
Returns the value of attribute tag_images.
3 4 5 |
# File 'lib/clarifai_ruby/tag_response.rb', line 3 def tag_images @tag_images end |