Skip to content

Commit 83ad716

Browse files
committed
Add a 'using' section to the main page with a short code example and pointers to the Javadoc. Move the "About" section to the end and remove broken package reference.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/csv/trunk@1461338 13f79535-47bb-0310-9956-ffa450edef68
1 parent 4c530ac commit 83ad716

1 file changed

Lines changed: 24 additions & 12 deletions

File tree

src/site/xdoc/index.xml

Lines changed: 24 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -22,18 +22,16 @@ limitations under the License.
2222
</properties>
2323
<body>
2424
<!-- ================================================== -->
25-
<section name="Commons CSV">
26-
<p>Commons CSV was started to unify a common and simple interface for reading and writing CSV files under an ASL license. It has been bootstrapped by a code donation from Netcetera in Switzerland. There are three pre-existing BSD compatible CSV parsers which this component will hopefully make redundant (authors willing): </p>
27-
<ul>
28-
<li><a href="http://kasparov.skife.org/csv/">Skife CSV</a></li>
29-
<li><a href="http://opencsv.sourceforge.net/">Open CSV</a></li>
30-
<li><a href="http://www.osjava.org/genjava/multiproject/gj-csv/">Genjava CSV</a></li>
31-
</ul>
32-
<p>In addition to the code from Netcetera (org.apache.commons.csv), Martin van den Bemt has added an additional writer API (org.apache.commons.csv.writer). </p>
33-
<p>Other CSV implementations: </p>
34-
<ul>
35-
<li><a href="http://supercsv.sourceforge.net/">Super CSV</a></li>
36-
</ul>
25+
<section name="Using Commons CSV">
26+
<p>Commons CSV reads and writes files in variations of the Comma Separated Value (CSV) format.</p>
27+
<p>To parse an Excel CSV file, write:</p>
28+
<source>Reader in = ...;
29+
Iterable&lt;CSVRecord&gt; parser = CSVFormat.EXCEL.parse(in);
30+
for (CSVRecord record : parser) {
31+
...
32+
}</source>
33+
<p>Other formats are available, please consult the Javadoc for <a href="apidocs/org/apache/commons/csv/CSVFormat.html">CSVFormat</a> and
34+
<a href="apidocs/org/apache/commons/csv/CSVParser.html">CSVParser</a></p>
3735
</section>
3836

3937
<section name="Getting the code">
@@ -46,6 +44,20 @@ limitations under the License.
4644
<p>Please report any bugs or issues in the Commons Sandbox Jira project at <a href="http://issues.apache.org/jira/browse/CSV">http://issues.apache.org/jira/browse/CSV</a>. Please ask any questions or suggest any ideas for improvement on the commons-dev and commons-user <a href="mail-lists.html">mailing lists</a>. </p>
4745
</section>
4846

47+
<section name="About Commons CSV">
48+
<p>Commons CSV was started to unify a common and simple interface for reading and writing CSV files under an ASL license. It has been bootstrapped by a code donation from Netcetera in Switzerland. There are three pre-existing BSD compatible CSV parsers which this component will hopefully make redundant (authors willing): </p>
49+
<ul>
50+
<li><a href="http://kasparov.skife.org/csv/">Skife CSV</a></li>
51+
<li><a href="http://opencsv.sourceforge.net/">Open CSV</a></li>
52+
<li><a href="http://www.osjava.org/genjava/multiproject/gj-csv/">Genjava CSV</a></li>
53+
</ul>
54+
<p>In addition to the code from Netcetera (org.apache.commons.csv), Martin van den Bemt has added an additional writer API. </p>
55+
<p>Other CSV implementations: </p>
56+
<ul>
57+
<li><a href="http://supercsv.sourceforge.net/">Super CSV</a></li>
58+
</ul>
59+
</section>
60+
4961
<!-- ================================================== -->
5062
</body>
5163
</document>

0 commit comments

Comments
 (0)