Module: SmokeyBear
- Defined in:
- lib/smokey_bear.rb,
lib/smokey_bear/helpers.rb,
lib/smokey_bear/version.rb
Defined Under Namespace
Modules: Helpers
Constant Summary collapse
- VERSION =
"1.1.0"
Class Attribute Summary collapse
-
.domain ⇒ Object
Returns the value of attribute domain.
-
.endpoint ⇒ Object
Returns the value of attribute endpoint.
-
.https ⇒ Object
Returns the value of attribute https.
-
.timeout ⇒ Object
Returns the value of attribute timeout.
Class Method Summary collapse
Class Attribute Details
.domain ⇒ Object
Returns the value of attribute domain.
11 12 13 |
# File 'lib/smokey_bear.rb', line 11 def domain @domain end |
.endpoint ⇒ Object
Returns the value of attribute endpoint.
11 12 13 |
# File 'lib/smokey_bear.rb', line 11 def endpoint @endpoint end |
.https ⇒ Object
Returns the value of attribute https.
11 12 13 |
# File 'lib/smokey_bear.rb', line 11 def https @https end |
.timeout ⇒ Object
Returns the value of attribute timeout.
11 12 13 |
# File 'lib/smokey_bear.rb', line 11 def timeout @timeout end |
Class Method Details
.base_url ⇒ Object
21 22 23 |
# File 'lib/smokey_bear.rb', line 21 def base_url @base_url ||= build_base_url end |
.build_base_url ⇒ Object
17 18 19 |
# File 'lib/smokey_bear.rb', line 17 def build_base_url "#{https ? "https" : "http"}://#{domain}/" end |
.configure {|_self| ... } ⇒ Object
13 14 15 |
# File 'lib/smokey_bear.rb', line 13 def configure yield self if block_given? end |