Class: SSLyze::XML::Resum::SessionResumptionWithSessionIDs
- Inherits:
-
Object
- Object
- SSLyze::XML::Resum::SessionResumptionWithSessionIDs
- Includes:
- Attributes::IsSupported, Types
- Defined in:
- lib/sslyze/xml/resum/session_resumption_with_session_ids.rb
Overview
Represents the <sessionResumptionWithSessionIDs>
XML element.
Constant Summary
Constants included from Types
Instance Method Summary collapse
-
#each_error {|error| ... } ⇒ Enumerator
Enumerates over each error message.
-
#error_count ⇒ Integer
The number of errors that occurred.
-
#errors ⇒ Array<String>
All error messages.
-
#failed_attempts ⇒ Integer
Number of failed attempts.
-
#initialize(node) ⇒ SessionResumptionWithSessionIDs
constructor
Initializes the SessionResumptionWithSessionIDs object.
-
#successful_attempts ⇒ Integer
Number of successful attempts.
-
#total_attempts ⇒ Integer
Number of total attempts.
Methods included from Attributes::IsSupported
Constructor Details
#initialize(node) ⇒ SessionResumptionWithSessionIDs
Initializes the SSLyze::XML::Resum::SessionResumptionWithSessionIDs object.
24 25 26 |
# File 'lib/sslyze/xml/resum/session_resumption_with_session_ids.rb', line 24 def initialize(node) @node = node end |
Instance Method Details
#each_error {|error| ... } ⇒ Enumerator
Enumerates over each error message.
74 75 76 77 78 79 80 |
# File 'lib/sslyze/xml/resum/session_resumption_with_session_ids.rb', line 74 def each_error return enum_for(__method__) unless block_given? @node.xpath('error').each do |error| yield error.inner_text end end |
#error_count ⇒ Integer
The number of errors that occurred.
60 61 62 |
# File 'lib/sslyze/xml/resum/session_resumption_with_session_ids.rb', line 60 def error_count @error_count ||= @node['errors'].to_i end |
#errors ⇒ Array<String>
All error messages.
87 88 89 |
# File 'lib/sslyze/xml/resum/session_resumption_with_session_ids.rb', line 87 def errors each_error.to_a end |
#failed_attempts ⇒ Integer
Number of failed attempts.
33 34 35 |
# File 'lib/sslyze/xml/resum/session_resumption_with_session_ids.rb', line 33 def failed_attempts @failed_attempts ||= @node['failedAttempts'].to_i end |
#successful_attempts ⇒ Integer
Number of successful attempts.
42 43 44 |
# File 'lib/sslyze/xml/resum/session_resumption_with_session_ids.rb', line 42 def successful_attempts @successful_attempts ||= @node['successfulAttempts'].to_i end |
#total_attempts ⇒ Integer
Number of total attempts.
51 52 53 |
# File 'lib/sslyze/xml/resum/session_resumption_with_session_ids.rb', line 51 def total_attempts @total_attempts ||= @node['totalAttempts'].to_i end |