Class: ClarifaiRuby::InfoRequest

Inherits:
Object
  • Object
show all
Defined in:
lib/clarifai_ruby/info_request.rb

Constant Summary collapse

INFO_PATH =
'/info'

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeInfoRequest

Returns a new instance of InfoRequest.



6
7
8
# File 'lib/clarifai_ruby/info_request.rb', line 6

def initialize
  @client = Client.new
end

Instance Attribute Details

#optionsObject (readonly)

Returns the value of attribute options.



4
5
6
# File 'lib/clarifai_ruby/info_request.rb', line 4

def options
  @options
end

#raw_responseObject (readonly)

Returns the value of attribute raw_response.



4
5
6
# File 'lib/clarifai_ruby/info_request.rb', line 4

def raw_response
  @raw_response
end

Instance Method Details

#get(opts = {}) ⇒ Object



10
11
12
13
# File 'lib/clarifai_ruby/info_request.rb', line 10

def get(opts = {})
  @raw_response = @client.get(INFO_PATH, opts).parsed_response
  InfoResponse.new(raw_response)
end