Menu

Home

HuDeanY

CsvReader

This is the same class as tens of thousands of similar classes except some special and unique features:

There is no dependency to other libraries (no Apache commons etc.).

The class "de.soderer.utilities.CsvReader" reads csv data from input streams.
Instead of opening and closing the csv files and returning all data at once this class works as a just in time reader. This helps handling huge files but works also on small ones.
Still there is a method for read all data at once.

The characterset encoding of the csv data may be any encoding java supports and may also include BOM at data start.

The separator character, the optional stringquote character and the escape character for stringquotes are configurable.

Other classes ignore the fact that not every linebreak is a new csv line. Quoted csv data may also contain linebreaks and even the escaped quotation character which is optional.

In some cases csv data line ends before all defined csv header columns are filled with data. This may be an error but can also be accepted and filled with empty data (fillMissingTrailingColumnsWithNull).

This reader counts the read csv data lines and characters.

It works with any linebreak characters (Unix, MAC, Windows).

There is also a method (parseCsvLine) to read and parse a single csv line from a String.

Featurelist: [csvreader_features]
Example: [csvreader_example]

CsvWriter

The class "de.soderer.utilities.CsvWriter" has the same configurable features as CsvReader.

It also allows to configure the linebreak characters used in output data (Unix, MAC, Windows).

Featurelist: [csvwriter_features]
Example: [csvwriter_example]

Project Members:


Related

Wiki: csvreader_example
Wiki: csvreader_features
Wiki: csvwriter_example
Wiki: csvwriter_features

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.