Commons CSV
  1. Commons CSV
  2. CSV-92

Need a way to extract parsed headers, e.g. for use in formatting output

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.0
    • Component/s: None
    • Labels:
      None

      Description

      Parsed header names are currently not accessible except as field key names, but these have to be known in advance.

      It would be useful to be able to have access to the header names:

      • to use in printing a header for a new CSV file. E.g. to read a CSV file and produce a new one with some changes made.
      • to write generic CSV applications

      The headers could be made available as a String array (in column number order) from the CSVParser class.
      The simplest would be to store the parsed (or provided) headers and return a clone of the array.

      If headers were not provided or requested, the method should probably return null rather than an empty array - to be decided.

        Activity

          People

          • Assignee:
            Unassigned
            Reporter:
            Sebb
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development