Exception: TextWeaver::Error

Inherits:
StandardError
  • Object
show all
Defined in:
lib/text_weaver/error.rb

Overview

This Error is raised if insert-positions err.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(position, set) ⇒ Error

Returns a new instance of Error.



6
7
8
9
# File 'lib/text_weaver/error.rb', line 6

def initialize(position, set)
  @position = position
  @set = set
end

Instance Attribute Details

#positionObject

Returns the value of attribute position.



4
5
6
# File 'lib/text_weaver/error.rb', line 4

def position
  @position
end

#setObject

Returns the value of attribute set.



4
5
6
# File 'lib/text_weaver/error.rb', line 4

def set
  @set
end

Instance Method Details

#messageObject



11
12
13
# File 'lib/text_weaver/error.rb', line 11

def message
  super.to_s + ': ' + @position.to_s + ', set: ' + @set.to_s
end