Class: Cloudflare::CustomHostname::SSLAttribute::Settings
- Inherits:
-
Object
- Object
- Cloudflare::CustomHostname::SSLAttribute::Settings
- Defined in:
- lib/cloudflare/custom_hostname/ssl_attribute/settings.rb
Instance Method Summary collapse
- #ciphers ⇒ Object
- #ciphers=(value) ⇒ Object
-
#http2 ⇒ Object
This will return the raw value, it is needed because if a value is nil we can’t assume that it means it is off.
- #http2=(value) ⇒ Object
-
#http2? ⇒ Boolean
Always coerce into a boolean, if the key is not provided, this value may not be accurate.
-
#initialize(settings = {}) ⇒ Settings
constructor
A new instance of Settings.
- #min_tls_version ⇒ Object
- #min_tls_version=(value) ⇒ Object
-
#tls_1_3 ⇒ Object
This will return the raw value, it is needed because if a value is nil we can’t assume that it means it is off.
- #tls_1_3=(value) ⇒ Object
-
#tls_1_3? ⇒ Boolean
Always coerce into a boolean, if the key is not provided, this value may not be accurate.
Constructor Details
#initialize(settings = {}) ⇒ Settings
Returns a new instance of Settings.
13 14 15 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 13 def initialize(settings = {}) @settings = settings end |
Instance Method Details
#ciphers ⇒ Object
17 18 19 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 17 def ciphers @settings[:ciphers] end |
#ciphers=(value) ⇒ Object
21 22 23 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 21 def ciphers=(value) @settings[:ciphers] = value end |
#http2 ⇒ Object
This will return the raw value, it is needed because if a value is nil we can’t assume that it means it is off
27 28 29 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 27 def http2 @settings[:http2] end |
#http2=(value) ⇒ Object
37 38 39 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 37 def http2=(value) process_boolean(:http2, value) end |
#http2? ⇒ Boolean
Always coerce into a boolean, if the key is not provided, this value may not be accurate
33 34 35 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 33 def http2? http2 == "on" end |
#min_tls_version ⇒ Object
41 42 43 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 41 def min_tls_version @settings[:min_tls_version] end |
#min_tls_version=(value) ⇒ Object
45 46 47 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 45 def min_tls_version=(value) @settings[:min_tls_version] = value end |
#tls_1_3 ⇒ Object
This will return the raw value, it is needed because if a value is nil we can’t assume that it means it is off
51 52 53 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 51 def tls_1_3 @settings[:tls_1_3] end |
#tls_1_3=(value) ⇒ Object
61 62 63 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 61 def tls_1_3=(value) process_boolean(:tls_1_3, value) end |
#tls_1_3? ⇒ Boolean
Always coerce into a boolean, if the key is not provided, this value may not be accurate
57 58 59 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 57 def tls_1_3? tls_1_3 == "on" end |