Class: DirectionNotFoundError
- Inherits:
-
CompilerError
- Object
- CompilerError
- DirectionNotFoundError
- Defined in:
- lib/compiler_error.rb
Instance Method Summary collapse
- #info ⇒ Object
-
#initialize(ast, client, direction, server) ⇒ DirectionNotFoundError
constructor
A new instance of DirectionNotFoundError.
Methods inherited from CompilerError
Constructor Details
#initialize(ast, client, direction, server) ⇒ DirectionNotFoundError
Returns a new instance of DirectionNotFoundError.
139 140 141 142 143 144 |
# File 'lib/compiler_error.rb', line 139 def initialize ast, client, direction, server super ast.position @client = client @direction = direction @server = server end |
Instance Method Details
#info ⇒ Object
146 147 148 149 150 151 152 153 |
# File 'lib/compiler_error.rb', line 146 def info case @direction when :left "'#{@client.name} -> #{@server.name}' : undefined direction" when :right "'#{@client.name} <- #{@server.name}' : undefined direction" end end |