Exception: CSV::InvalidEncodingError
- Inherits:
-
MalformedCSVError
- Object
- RuntimeError
- MalformedCSVError
- CSV::InvalidEncodingError
- Defined in:
- lib/csv.rb
Overview
The error thrown when the parser encounters invalid encoding in CSV.
Instance Attribute Summary collapse
-
#encoding ⇒ Object
readonly
Returns the value of attribute encoding.
Attributes inherited from MalformedCSVError
Instance Method Summary collapse
-
#initialize(encoding, line_number) ⇒ InvalidEncodingError
constructor
A new instance of InvalidEncodingError.
Constructor Details
#initialize(encoding, line_number) ⇒ InvalidEncodingError
Returns a new instance of InvalidEncodingError.
864 865 866 867 |
# File 'lib/csv.rb', line 864 def initialize(encoding, line_number) @encoding = encoding super("Invalid byte sequence in #{encoding}", line_number) end |
Instance Attribute Details
#encoding ⇒ Object (readonly)
Returns the value of attribute encoding.
863 864 865 |
# File 'lib/csv.rb', line 863 def encoding @encoding end |