commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Gregory <garydgreg...@gmail.com>
Subject RE: [CSV] CSVFormat validation - do this earlier?
Date Tue, 13 May 2014 13:13:21 GMT
I'm for whatever will be more helpful to the user. You can pick :)

Gary

<div>-------- Original message --------</div><div>From: sebb <sebbaz@gmail.com>
</div><div>Date:05/13/2014  06:06  (GMT-05:00) </div><div>To: dev@commons.apache.org
</div><div>Subject: [CSV] CSVFormat validation - do this earlier? </div><div>
</div>At present, validate() is not invoked until the format is used. This
means that invalid arguments are not detected at the point they are
provided.

It would be possible to run validate as part of the withArgument()
methods. This would allow earlier detection, and avoid the issue that
currently some incorrect arguments may generate ISE rather than IAE.

I think the only possible user problem is that escape must be set
before using Quote.NONE as the policy, but this could be documented.
Otherwise AFAICT the arguments can be set in any order.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message