Module: Foobara::HttpApiCommand::Concerns::Url

Includes:
Concern
Included in:
Foobara::HttpApiCommand
Defined in:
foobara-http-api-command-0.0.9/src/foobara/concerns/url.rb

Defined Under Namespace

Modules: ClassMethods

Instance Method Summary collapse

Methods included from Concern

foobara_class_methods_module_for, foobara_concern?, included

Instance Method Details

#api_uri_objectObject

[View source]

18
19
20
# File 'foobara-http-api-command-0.0.9/src/foobara/concerns/url.rb', line 18

def api_uri_object
  @api_uri_object ||= self.class.compute_uri_object(self)
end

#api_urlObject

[View source]

14
15
16
# File 'foobara-http-api-command-0.0.9/src/foobara/concerns/url.rb', line 14

def api_url
  @api_url ||= self.class.compute_api_url(self)
end

#net_httpObject

[View source]

7
8
9
10
11
12
# File 'foobara-http-api-command-0.0.9/src/foobara/concerns/url.rb', line 7

def net_http
  # unclear why, but, seems like if we're doing SSL we have to be single-use, hmmm...
  return @net_http if @net_http && !@net_http.use_ssl?

  @net_http ||= self.class.compute_http(self)
end