Class: Ucode::Audit::Extractors::Base
- Inherits:
-
Object
- Object
- Ucode::Audit::Extractors::Base
- Defined in:
- lib/ucode/audit/extractors/base.rb
Overview
Abstract extractor interface. Subclasses implement ‘#extract`.
An extractor reads from a Context and returns a hash of fields suitable for ‘Models::Audit::AuditReport.new(**fields)`. Returning an empty hash is valid (no-op).
Direct Known Subclasses
Aggregations, ColorCapabilities, Coverage, Hinting, Identity, Licensing, Metrics, OpenTypeLayout, Provenance, Style, VariationDetail
Instance Method Summary collapse
-
#extract(context) ⇒ Hash{Symbol=>Object}
Fields merged into the AuditReport.
Instance Method Details
#extract(context) ⇒ Hash{Symbol=>Object}
Returns fields merged into the AuditReport.
14 15 16 17 |
# File 'lib/ucode/audit/extractors/base.rb', line 14 def extract(context) raise NotImplementedError, "#{self.class} must implement #extract" end |