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.
7 8 9 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 7 def initialize(settings) @settings = settings end |
Instance Method Details
#ciphers ⇒ Object
11 12 13 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 11 def ciphers @settings[:ciphers] end |
#ciphers=(value) ⇒ Object
15 16 17 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 15 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
21 22 23 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 21 def http2 @settings[:http2] end |
#http2=(value) ⇒ Object
31 32 33 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 31 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
27 28 29 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 27 def http2? http2 == 'on' end |
#min_tls_version ⇒ Object
35 36 37 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 35 def min_tls_version @settings[:min_tls_version] end |
#min_tls_version=(value) ⇒ Object
39 40 41 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 39 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
45 46 47 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 45 def tls_1_3 @settings[:tls_1_3] end |
#tls_1_3=(value) ⇒ Object
55 56 57 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 55 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
51 52 53 |
# File 'lib/cloudflare/custom_hostname/ssl_attribute/settings.rb', line 51 def tls_1_3? tls_1_3 == 'on' end |