Exception: PandocRb::ParsecError

Inherits:
Error
  • Object
show all
Defined in:
lib/pandoc_rb/parsec_error.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ ParsecError

Returns a new instance of ParsecError.



6
7
8
9
10
# File 'lib/pandoc_rb/parsec_error.rb', line 6

def initialize(json)
  self.input, parse_error = json
  source_pos, self.messages = parse_error
  self.source_name, self.line, self.column = source_pos
end

Instance Attribute Details

#columnObject

Returns the value of attribute column.



4
5
6
# File 'lib/pandoc_rb/parsec_error.rb', line 4

def column
  @column
end

#inputObject

Returns the value of attribute input.



4
5
6
# File 'lib/pandoc_rb/parsec_error.rb', line 4

def input
  @input
end

#lineObject

Returns the value of attribute line.



4
5
6
# File 'lib/pandoc_rb/parsec_error.rb', line 4

def line
  @line
end

#messagesObject

Returns the value of attribute messages.



4
5
6
# File 'lib/pandoc_rb/parsec_error.rb', line 4

def messages
  @messages
end

#source_nameObject

Returns the value of attribute source_name.



4
5
6
# File 'lib/pandoc_rb/parsec_error.rb', line 4

def source_name
  @source_name
end