Class: Kinu::Configuration
- Inherits:
-
Object
- Object
- Kinu::Configuration
- Defined in:
- lib/kinu/configuration.rb
Instance Attribute Summary collapse
- #host ⇒ Object
- #port ⇒ Object
-
#ssl ⇒ Object
writeonly
Sets the attribute ssl.
- #upload_host ⇒ Object
Instance Method Summary collapse
Instance Attribute Details
#host ⇒ Object
5 6 7 |
# File 'lib/kinu/configuration.rb', line 5 def host @host end |
#port ⇒ Object
13 14 15 16 17 18 19 20 21 |
# File 'lib/kinu/configuration.rb', line 13 def port if @port @port elsif ssl? 443 else 80 end end |
#ssl=(value) ⇒ Object (writeonly)
Sets the attribute ssl
3 4 5 |
# File 'lib/kinu/configuration.rb', line 3 def ssl=(value) @ssl = value end |
#upload_host ⇒ Object
9 10 11 |
# File 'lib/kinu/configuration.rb', line 9 def upload_host @upload_host end |
Instance Method Details
#scheme ⇒ Object
27 28 29 30 31 32 33 |
# File 'lib/kinu/configuration.rb', line 27 def scheme if ssl? :https else :http end end |
#ssl? ⇒ Boolean
23 24 25 |
# File 'lib/kinu/configuration.rb', line 23 def ssl? @ssl end |