Class: Roodi::Core::Error
- Inherits:
-
Object
- Object
- Roodi::Core::Error
- Defined in:
- lib/roodi/core/error.rb
Instance Attribute Summary collapse
-
#filename ⇒ Object
readonly
Returns the value of attribute filename.
-
#line_number ⇒ Object
readonly
Returns the value of attribute line_number.
-
#message ⇒ Object
readonly
Returns the value of attribute message.
Instance Method Summary collapse
-
#initialize(filename, line_number, message) ⇒ Error
constructor
A new instance of Error.
- #to_s ⇒ Object
Constructor Details
#initialize(filename, line_number, message) ⇒ Error
Returns a new instance of Error.
6 7 8 9 10 |
# File 'lib/roodi/core/error.rb', line 6 def initialize(filename, line_number, ) @filename = filename @line_number = line_number @message = end |
Instance Attribute Details
#filename ⇒ Object (readonly)
Returns the value of attribute filename.
4 5 6 |
# File 'lib/roodi/core/error.rb', line 4 def filename @filename end |
#line_number ⇒ Object (readonly)
Returns the value of attribute line_number.
4 5 6 |
# File 'lib/roodi/core/error.rb', line 4 def line_number @line_number end |
#message ⇒ Object (readonly)
Returns the value of attribute message.
4 5 6 |
# File 'lib/roodi/core/error.rb', line 4 def @message end |
Instance Method Details
#to_s ⇒ Object
12 13 14 |
# File 'lib/roodi/core/error.rb', line 12 def to_s "#{@filename}:#{@line_number} - #{@message}" end |