You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by br...@apache.org on 2014/07/11 21:06:52 UTC

svn commit: r1609771 - in /commons/proper/csv/trunk/src/site: site.xml xdoc/index.xml

Author: britter
Date: Fri Jul 11 19:06:51 2014
New Revision: 1609771

URL: http://svn.apache.org/r1609771
Log:
Work some more on the website

Modified:
    commons/proper/csv/trunk/src/site/site.xml
    commons/proper/csv/trunk/src/site/xdoc/index.xml

Modified: commons/proper/csv/trunk/src/site/site.xml
URL: http://svn.apache.org/viewvc/commons/proper/csv/trunk/src/site/site.xml?rev=1609771&r1=1609770&r2=1609771&view=diff
==============================================================================
--- commons/proper/csv/trunk/src/site/site.xml (original)
+++ commons/proper/csv/trunk/src/site/site.xml Fri Jul 11 19:06:51 2014
@@ -29,6 +29,7 @@
     <menu name="Commons CSV">
       <item name="Overview"    href="/index.html"/>
       <item name="Download"    href="/download_csv.cgi"/>
+      <item name="User Guide"  href="/user-guide.html"/>
       <item name="Wiki"        href="http://wiki.apache.org/commons/CSV"/>
     </menu>
 

Modified: commons/proper/csv/trunk/src/site/xdoc/index.xml
URL: http://svn.apache.org/viewvc/commons/proper/csv/trunk/src/site/xdoc/index.xml?rev=1609771&r1=1609770&r2=1609771&view=diff
==============================================================================
--- commons/proper/csv/trunk/src/site/xdoc/index.xml (original)
+++ commons/proper/csv/trunk/src/site/xdoc/index.xml Fri Jul 11 19:06:51 2014
@@ -24,38 +24,30 @@ limitations under the License.
 <!-- ================================================== -->
 <section name="Using Commons CSV">
   <p>Commons CSV reads and writes files in variations of the Comma Separated Value (CSV) format.</p>
-  <p>To parse an Excel CSV file, write:</p>
-  <source>Reader in = new FileReader(&quot;path/to/file.csv&quot;);
-Iterable&lt;CSVRecord&gt; records = CSVFormat.EXCEL.parse(in);
-for (CSVRecord record : records) {
-  String lastName = record.get("Last Name");
-  String firstName = record.get("First Name");
-}</source>
-  <p>Other formats are available, please consult the Javadoc for <a href="apidocs/org/apache/commons/csv/CSVFormat.html">CSVFormat</a> and
-    <a href="apidocs/org/apache/commons/csv/CSVParser.html">CSVParser</a>.
-  </p>
-</section>
-<section name="Handling Byte Order Marks">
-  <p>
-    To handle files that start with a Byte Order Mark (BOM) like some Excel CSV files, you need an extra step to deal with these optional bytes.
-    You can use the 
-    <a href="https://commons.apache.org/proper/commons-io/apidocs/org/apache/commons/io/input/BOMInputStream.html">BOMInputStream</a> 
-    class from <a href="https://commons.apache.org/proper/commons-io/">Apache Commons IO</a> for example: 
-  </p>
-  <source>final URL url = ...;
-final Reader reader = new InputStreamReader(new BOMInputStream(url.openStream()), "UTF-8");
-final CSVParser parser = new CSVParser(reader, CSVFormat.EXCEL.withHeader());
-try {
-  for (final CSVRecord record : parser) {
-    final String string = record.get("SomeColumn");
-    ...
-  }
-} finally {
-  parser.close();
-  reader.close();
-}</source>
+  <p>The most common CSV formats are predefined in the <a href="apidocs/org/apache/commons/csv/CSVFormat.html">CSVFormat</a> class:
+  <ul>
+    <li><a href="http://tools.ietf.org/html/rfc4180">RFC 4180</a></li>
+    <li>MS Excel</li>
+    <li><a href="http://dev.mysql.com/doc/refman/5.0/en/mysqldump-delimited-text.html">MySQL</a></li>
+    <li><a href="http://en.wikipedia.org/wiki/Tab-separated_values">TDF</a></li>
+  </ul>
+  </p>
+  <p>Custom formats can be created using a fluent style API.</p>
+</section>
+<!-- ================================================== -->
+<section name="Documentation">
+  <p>
+    The package descriptions in the <a href="javadocs/api-release/index.html">JavaDoc</a> give an overview of the available features
+    and various <a href="project-reports.html">project reports</a> are provided.
+  </p>
+  <p>
+    The JavaDoc API documents for the <a href="javadocs/api-1.0/index.html">current stable release 1.0</a> [Java 5.0+] can be viewed in a web browser.
+  </p>
+  <p>
+    The <a href="source-repository.html">subversion repository</a> can be
+    <a href="http://svn.apache.org/viewvc/commons/proper/csv/trunk/">browsed</a>, or you can browse/contribute via <a href="https://github.com/apache/commons-csv">GitHub</a>.
+  </p>
 </section>
-
 <!-- ================================================== -->
 <section name="Release Information">
 <p>The latest stable release of csv is 1.0. You may: </p>