Class: Topographer::Importer::Logger::LogEntry
- Inherits:
-
Object
- Object
- Topographer::Importer::Logger::LogEntry
- Defined in:
- lib/topographer/importer/logger/log_entry.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#input_identifier ⇒ Object
readonly
Returns the value of attribute input_identifier.
-
#model_name ⇒ Object
readonly
Returns the value of attribute model_name.
Instance Method Summary collapse
- #details ⇒ Object
- #failure? ⇒ Boolean
-
#initialize(input_identifier, model_name, import_status) ⇒ LogEntry
constructor
A new instance of LogEntry.
- #message ⇒ Object
- #source_identifier ⇒ Object
- #success? ⇒ Boolean
- #timestamp ⇒ Object
Constructor Details
#initialize(input_identifier, model_name, import_status) ⇒ LogEntry
Returns a new instance of LogEntry.
5 6 7 8 9 |
# File 'lib/topographer/importer/logger/log_entry.rb', line 5 def initialize(input_identifier, model_name, import_status) @input_identifier = input_identifier @model_name = model_name @import_status = import_status end |
Instance Attribute Details
#input_identifier ⇒ Object (readonly)
Returns the value of attribute input_identifier.
2 3 4 |
# File 'lib/topographer/importer/logger/log_entry.rb', line 2 def input_identifier @input_identifier end |
#model_name ⇒ Object (readonly)
Returns the value of attribute model_name.
2 3 4 |
# File 'lib/topographer/importer/logger/log_entry.rb', line 2 def model_name @model_name end |
Instance Method Details
#details ⇒ Object
23 24 25 |
# File 'lib/topographer/importer/logger/log_entry.rb', line 23 def details @import_status.errors end |
#failure? ⇒ Boolean
31 32 33 |
# File 'lib/topographer/importer/logger/log_entry.rb', line 31 def failure? @import_status.errors? end |
#message ⇒ Object
15 16 17 |
# File 'lib/topographer/importer/logger/log_entry.rb', line 15 def @import_status. end |
#source_identifier ⇒ Object
11 12 13 |
# File 'lib/topographer/importer/logger/log_entry.rb', line 11 def source_identifier @import_status.input_identifier end |
#success? ⇒ Boolean
27 28 29 |
# File 'lib/topographer/importer/logger/log_entry.rb', line 27 def success? !failure? end |
#timestamp ⇒ Object
19 20 21 |
# File 'lib/topographer/importer/logger/log_entry.rb', line 19 def @import_status. end |