Class: JSLintJohnson::LintError

Inherits:
Object
  • Object
show all
Defined in:
lib/jslint-johnson/lint_error.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(jsobject) ⇒ LintError

Returns a new instance of LintError.



6
7
8
9
10
11
# File 'lib/jslint-johnson/lint_error.rb', line 6

def initialize(jsobject)
  @line_number = jsobject["line"]
  @character = jsobject["character"]
  @reason = jsobject["reason"]
  @evidence = jsobject["evidence"]
end

Instance Attribute Details

#characterObject (readonly)

Returns the value of attribute character.



4
5
6
# File 'lib/jslint-johnson/lint_error.rb', line 4

def character
  @character
end

#evidenceObject (readonly)

Returns the value of attribute evidence.



4
5
6
# File 'lib/jslint-johnson/lint_error.rb', line 4

def evidence
  @evidence
end

#line_numberObject (readonly)

Returns the value of attribute line_number.



4
5
6
# File 'lib/jslint-johnson/lint_error.rb', line 4

def line_number
  @line_number
end

#reasonObject (readonly)

Returns the value of attribute reason.



4
5
6
# File 'lib/jslint-johnson/lint_error.rb', line 4

def reason
  @reason
end