class Kwalify::BaseError
Attributes
column[RW]
error_symbol[RW]
filename[RW]
linenum[RW]
path[RW]
rule[RW]
value[RW]
Public Class Methods
new(message="", path=nil, value=nil, rule=nil, error_symbol=nil)
click to toggle source
Calls superclass method
# File lib/kwalify/errors.rb, line 23 def initialize(message="", path=nil, value=nil, rule=nil, error_symbol=nil) super(message) @path = path.is_a?(Array) ? '/'+path.join('/') : path @rule = rule @value = value @error_symbol = error_symbol end
Public Instance Methods
<=>(ex)
click to toggle source
# File lib/kwalify/errors.rb, line 49 def <=>(ex) #return @linenum <=> ex.linenum v = 0 v = @linenum <=> ex.linenum if @linenum && ex.linenum v = @column <=> ex.column if v == 0 && @column && ex.column v = @path <=> ex.path if v == 0 return v end