Exception: Pure::ParseEntityError

Inherits:
ParseError show all
Defined in:
lib/pure/error.rb

Direct Known Subclasses

ParseMethodError

Instance Attribute Summary collapse

Attributes inherited from ExtractionTimeError

#file, #line

Instance Method Summary collapse

Constructor Details

#initialize(file, line, entity) ⇒ ParseEntityError

Returns a new instance of ParseEntityError.



44
45
46
47
# File 'lib/pure/error.rb', line 44

def initialize(file, line, entity)
  @entity = entity
  super(file, line)
end

Instance Attribute Details

#entityObject (readonly)

Returns the value of attribute entity.



42
43
44
# File 'lib/pure/error.rb', line 42

def entity
  @entity
end

Instance Method Details

#custom_messageObject



49
50
51
# File 'lib/pure/error.rb', line 49

def custom_message
  "failed to parse `#{entity}'"
end