Class: Pennyworth::Presenters::System::Error
- Inherits:
-
Object
- Object
- Pennyworth::Presenters::System::Error
- Extended by:
- Forwardable
- Defined in:
- lib/pennyworth/presenters/system/error.rb
Overview
Shapes a system error record for serialization.
Instance Method Summary collapse
-
#initialize(record) ⇒ Error
constructor
A new instance of Error.
- #label ⇒ Object
- #subtitle ⇒ Object
Constructor Details
#initialize(record) ⇒ Error
Returns a new instance of Error.
14 15 16 |
# File 'lib/pennyworth/presenters/system/error.rb', line 14 def initialize record @record = record end |
Instance Method Details
#label ⇒ Object
18 |
# File 'lib/pennyworth/presenters/system/error.rb', line 18 def label = record.name |
#subtitle ⇒ Object
20 |
# File 'lib/pennyworth/presenters/system/error.rb', line 20 def subtitle = "#{label}: #{description}." |