Class: Clickwrap::RequestEvidencePolicy::Setting
- Inherits:
-
Data
- Object
- Data
- Clickwrap::RequestEvidencePolicy::Setting
- Defined in:
- lib/clickwrap/request_evidence_policy.rb
Overview
One category's settings: whether to record it, why, how long, and what happens when it cannot be resolved.
Instance Attribute Summary collapse
-
#because ⇒ Object
readonly
Returns the value of attribute because.
-
#data_protection_impact_assessment_reference ⇒ Object
readonly
Returns the value of attribute data_protection_impact_assessment_reference.
-
#delete_after ⇒ Object
readonly
Returns the value of attribute delete_after.
-
#encrypted ⇒ Object
readonly
Returns the value of attribute encrypted.
-
#fail_if_unavailable ⇒ Object
readonly
Returns the value of attribute fail_if_unavailable.
-
#legal_basis_reference ⇒ Object
readonly
Returns the value of attribute legal_basis_reference.
-
#record ⇒ Object
readonly
Returns the value of attribute record.
-
#retain_until ⇒ Object
readonly
Returns the value of attribute retain_until.
Instance Method Summary collapse
- #encrypted? ⇒ Boolean
- #fail_if_unavailable? ⇒ Boolean
-
#initialize(record: false, encrypted: nil, delete_after: nil, retain_until: nil, fail_if_unavailable: false, because: nil, legal_basis_reference: nil, data_protection_impact_assessment_reference: nil) ⇒ Setting
constructor
A new instance of Setting.
- #record? ⇒ Boolean
- #to_snapshot ⇒ Object
Constructor Details
#initialize(record: false, encrypted: nil, delete_after: nil, retain_until: nil, fail_if_unavailable: false, because: nil, legal_basis_reference: nil, data_protection_impact_assessment_reference: nil) ⇒ Setting
Returns a new instance of Setting.
33 34 35 36 37 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 33 def initialize(record: false, encrypted: nil, delete_after: nil, retain_until: nil, fail_if_unavailable: false, because: nil, legal_basis_reference: nil, data_protection_impact_assessment_reference: nil) super end |
Instance Attribute Details
#because ⇒ Object (readonly)
Returns the value of attribute because
29 30 31 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 29 def because @because end |
#data_protection_impact_assessment_reference ⇒ Object (readonly)
Returns the value of attribute data_protection_impact_assessment_reference
29 30 31 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 29 def data_protection_impact_assessment_reference @data_protection_impact_assessment_reference end |
#delete_after ⇒ Object (readonly)
Returns the value of attribute delete_after
29 30 31 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 29 def delete_after @delete_after end |
#encrypted ⇒ Object (readonly)
Returns the value of attribute encrypted
29 30 31 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 29 def encrypted @encrypted end |
#fail_if_unavailable ⇒ Object (readonly)
Returns the value of attribute fail_if_unavailable
29 30 31 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 29 def fail_if_unavailable @fail_if_unavailable end |
#legal_basis_reference ⇒ Object (readonly)
Returns the value of attribute legal_basis_reference
29 30 31 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 29 def legal_basis_reference @legal_basis_reference end |
#record ⇒ Object (readonly)
Returns the value of attribute record
29 30 31 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 29 def record @record end |
#retain_until ⇒ Object (readonly)
Returns the value of attribute retain_until
29 30 31 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 29 def retain_until @retain_until end |
Instance Method Details
#encrypted? ⇒ Boolean
40 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 40 def encrypted? = encrypted == true |
#fail_if_unavailable? ⇒ Boolean
41 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 41 def fail_if_unavailable? = fail_if_unavailable == true |
#record? ⇒ Boolean
39 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 39 def record? = record == true |
#to_snapshot ⇒ Object
43 44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/clickwrap/request_evidence_policy.rb', line 43 def to_snapshot { "record" => record?, "encrypted" => encrypted?, "delete_after_seconds" => delete_after&.to_i, "retain_until_rule" => retain_until&.to_s, "fail_if_unavailable" => fail_if_unavailable?, "because" => because, "legal_basis_reference" => legal_basis_reference, "data_protection_impact_assessment_reference" => data_protection_impact_assessment_reference }.compact end |