Class: Inferno::Entities::Message
- Defined in:
- lib/inferno/entities/message.rb
Overview
A Message
represents a message generated during a test.
Constant Summary collapse
- ATTRIBUTES =
[:id, :index, :message, :result_id, :result, :type].freeze
- TYPES =
['error', 'warning', 'info'].freeze
Instance Attribute Summary collapse
-
#id ⇒ String
Id of the message.
-
#index ⇒ String
Index of the message.
-
#message ⇒ String
-
#result ⇒ Inferno::Entities::Result
-
#result_id ⇒ String
-
#type ⇒ String
Instance Method Summary collapse
-
#initialize(params) ⇒ Message
constructor
A new instance of Message.
Methods inherited from Entity
Constructor Details
#initialize(params) ⇒ Message
Returns a new instance of Message.
23 24 25 |
# File 'lib/inferno/entities/message.rb', line 23 def initialize(params) super(params, ATTRIBUTES) end |
Instance Attribute Details
#id ⇒ String
Returns id of the message.
17 18 19 20 21 22 23 24 25 26 |
# File 'lib/inferno/entities/message.rb', line 17 class Message < Entity ATTRIBUTES = [:id, :index, :message, :result_id, :result, :type].freeze TYPES = ['error', 'warning', 'info'].freeze include Inferno::Entities::Attributes def initialize(params) super(params, ATTRIBUTES) end end |
#index ⇒ String
Returns index of the message. Used for ordering.
17 18 19 20 21 22 23 24 25 26 |
# File 'lib/inferno/entities/message.rb', line 17 class Message < Entity ATTRIBUTES = [:id, :index, :message, :result_id, :result, :type].freeze TYPES = ['error', 'warning', 'info'].freeze include Inferno::Entities::Attributes def initialize(params) super(params, ATTRIBUTES) end end |
#message ⇒ String
17 18 19 20 21 22 23 24 25 26 |
# File 'lib/inferno/entities/message.rb', line 17 class Message < Entity ATTRIBUTES = [:id, :index, :message, :result_id, :result, :type].freeze TYPES = ['error', 'warning', 'info'].freeze include Inferno::Entities::Attributes def initialize(params) super(params, ATTRIBUTES) end end |
#result ⇒ Inferno::Entities::Result
17 18 19 20 21 22 23 24 25 26 |
# File 'lib/inferno/entities/message.rb', line 17 class Message < Entity ATTRIBUTES = [:id, :index, :message, :result_id, :result, :type].freeze TYPES = ['error', 'warning', 'info'].freeze include Inferno::Entities::Attributes def initialize(params) super(params, ATTRIBUTES) end end |
#result_id ⇒ String
17 18 19 20 21 22 23 24 25 26 |
# File 'lib/inferno/entities/message.rb', line 17 class Message < Entity ATTRIBUTES = [:id, :index, :message, :result_id, :result, :type].freeze TYPES = ['error', 'warning', 'info'].freeze include Inferno::Entities::Attributes def initialize(params) super(params, ATTRIBUTES) end end |
#type ⇒ String
17 18 19 20 21 22 23 24 25 26 |
# File 'lib/inferno/entities/message.rb', line 17 class Message < Entity ATTRIBUTES = [:id, :index, :message, :result_id, :result, :type].freeze TYPES = ['error', 'warning', 'info'].freeze include Inferno::Entities::Attributes def initialize(params) super(params, ATTRIBUTES) end end |