Class: Continuum::FixType
- Inherits:
-
Object
- Object
- Continuum::FixType
- Defined in:
- src/lib/continuum/fix_type.rb
Overview
A class that encapsulates remediation steps suggested by Access Engine for resolving an accessibility concern.
Instance Attribute Summary collapse
-
#dom_spec ⇒ Boolean
Gets whether this fix is specific to the particular page under test, or more general.
-
#helper_text ⇒ String
Gets a brief human-readable description of how to resolve the accessibility concern corresponding to this fix.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(dom_spec, helper_text) ⇒ FixType
constructor
A new instance of FixType.
Constructor Details
#initialize(dom_spec, helper_text) ⇒ FixType
Returns a new instance of FixType.
26 27 28 29 |
# File 'src/lib/continuum/fix_type.rb', line 26 def initialize(dom_spec, helper_text) @dom_spec = dom_spec @helper_text = helper_text end |
Instance Attribute Details
#dom_spec ⇒ Boolean
Gets whether this fix is specific to the particular page under test, or more general.
14 15 16 |
# File 'src/lib/continuum/fix_type.rb', line 14 def dom_spec @dom_spec end |
#helper_text ⇒ String
Gets a brief human-readable description of how to resolve the accessibility concern corresponding to this fix. Consult AMP for additional information.
21 22 23 |
# File 'src/lib/continuum/fix_type.rb', line 21 def helper_text @helper_text end |
Class Method Details
.from_json(json_data) ⇒ FixType
33 34 35 36 |
# File 'src/lib/continuum/fix_type.rb', line 33 def self.from_json(json_data) parsed = DataUtil.parse_json(json_data) || {} return new(parsed['domSpec'], parsed['helperText']) end |