Return-Path: X-Original-To: apmail-commons-commits-archive@minotaur.apache.org Delivered-To: apmail-commons-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 894D1FB23 for ; Tue, 26 Mar 2013 22:17:27 +0000 (UTC) Received: (qmail 18736 invoked by uid 500); 26 Mar 2013 22:17:27 -0000 Delivered-To: apmail-commons-commits-archive@commons.apache.org Received: (qmail 18678 invoked by uid 500); 26 Mar 2013 22:17:27 -0000 Mailing-List: contact commits-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@commons.apache.org Delivered-To: mailing list commits@commons.apache.org Received: (qmail 18671 invoked by uid 99); 26 Mar 2013 22:17:27 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Mar 2013 22:17:27 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Mar 2013 22:17:11 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id B469A2388B1B for ; Tue, 26 Mar 2013 22:16:24 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r856056 [8/26] - in /websites/production/commons/content/proper/commons-csv: ./ apidocs/ apidocs/org/apache/commons/csv/ apidocs/org/apache/commons/csv/class-use/ apidocs/src-html/org/apache/commons/csv/ cobertura/ testapidocs/ testapidocs/... Date: Tue, 26 Mar 2013 22:16:20 -0000 To: commits@commons.apache.org From: ggregory@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20130326221624.B469A2388B1B@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Modified: websites/production/commons/content/proper/commons-csv/cobertura/org.apache.commons.csv.CSVLexer.html ============================================================================== --- websites/production/commons/content/proper/commons-csv/cobertura/org.apache.commons.csv.CSVLexer.html (original) +++ websites/production/commons/content/proper/commons-csv/cobertura/org.apache.commons.csv.CSVLexer.html Tue Mar 26 22:16:19 2013 @@ -88,9 +88,9 @@  35  
     /** INTERNAL API. ctor needs to be public so can be called dynamically by PerformanceTest class */
 36   -
     public CSVLexer(final CSVFormat format, final ExtendedBufferedReader in) {
-  37  180408
         super(format, in);
-  38  180408
     }
+
     CSVLexer(final CSVFormat format, final ExtendedBufferedReader in) {
+  37  30075
         super(format, in);
+  38  30075
     }
 39  
 
 40   @@ -123,12 +123,12 @@
 
 54  
         // get the last read char (required for empty line detection)
-  55  1083889
         int lastChar = in.getLastChar();
+  55  180766
         int lastChar = in.getLastChar();
 56  
 
 57  
         // read the next char and set eol
-  58  1083889
         int c = in.read();
+  58  180766
         int c = in.read();
 59  
         /*
 60   @@ -137,25 +137,25 @@
          * - they are equivalent here.
 62  
          */
-  63  1083889
         boolean eol = readEndOfLine(c);
+  63  180766
         boolean eol = readEndOfLine(c);
 64  
 
 65  
         // empty line detection: eol AND (last char was EOL or beginning)
-  66  1083889
         if (ignoreEmptyLines) {
-  67  361560
             while (eol && isStartOfLine(lastChar)) {
+  66  180766
         if (ignoreEmptyLines) {
+  67  60484
             while (eol && isStartOfLine(lastChar)) {
 68  
                 // go on char ahead ...
-  69  216
                 lastChar = c;
-  70  216
                 c = in.read();
-  71  216
                 eol = readEndOfLine(c);
+  69  36
                 lastChar = c;
+  70  36
                 c = in.read();
+  71  36
                 eol = readEndOfLine(c);
 72  
                 // reached end of file without any content (empty line at the end)
-  73  216
                 if (isEndOfFile(c)) {
-  74  30
                     token.type = EOF;
+  73  36
                 if (isEndOfFile(c)) {
+  74  5
                     token.type = EOF;
 75  
                     // don't set tkn.isReady here because no content
-  76  30
                     return token;
+  76  5
                     return token;
 77  
                 }
 78   @@ -166,33 +166,33 @@
 
 81  
         // did we reach eof during the last iteration already ? EOF
-  82  1083859
         if (isEndOfFile(lastChar) || (!isDelimiter(lastChar) && isEndOfFile(c))) {
-  83  180348
             token.type = EOF;
+  82  180761
         if (isEndOfFile(lastChar) || (!isDelimiter(lastChar) && isEndOfFile(c))) {
+  83  30059
             token.type = EOF;
 84  
             // don't set tkn.isReady here because no content
-  85  180348
             return token;
+  85  30059
             return token;
 86  
         }
 87  
 
-  88  903511
         if (isStartOfLine(lastChar) && isCommentStart(c)) {
-  89  156
             final String comment = in.readLine().trim();
-  90  156
             token.content.append(comment);
-  91  156
             token.type = COMMENT;
-  92  156
             return token;
+  88  150702
         if (isStartOfLine(lastChar) && isCommentStart(c)) {
+  89  26
             final String comment = in.readLine().trim();
+  90  26
             token.content.append(comment);
+  91  26
             token.type = COMMENT;
+  92  26
             return token;
 93  
         }
 94  
 
 95  
         // important: make sure a new char gets consumed in each iteration
-  96  1806704
         while (token.type == INVALID) {
+  96  301351
         while (token.type == INVALID) {
 97  
             // ignore whitespaces at beginning of a token
-  98  903355
             if (ignoreSurroundingSpaces) {
-  99  720
                 while (isWhitespace(c) && !eol) {
-  100  192
                     c = in.read();
-  101  192
                     eol = readEndOfLine(c);
+  98  150676
             if (ignoreSurroundingSpaces) {
+  99  120
                 while (isWhitespace(c) && !eol) {
+  100  32
                     c = in.read();
+  101  32
                     eol = readEndOfLine(c);
 102  
                 }
 103   @@ -201,39 +201,39 @@
 
 105  
             // ok, start of token reached: encapsulated, or token
-  106  903355
             if (isDelimiter(c)) {
+  106  150676
             if (isDelimiter(c)) {
 107  
                 // empty token return TOKEN("")
-  108  10466
                 token.type = TOKEN;
-  109  892889
             } else if (eol) {
+  108  1729
                 token.type = TOKEN;
+  109  148947
             } else if (eol) {
 110  
                 // empty token return EORECORD("")
 111  
                 // noop: tkn.content.append("");
-  112  14833
                 token.type = EORECORD;
-  113  878056
             } else if (isQuoteChar(c)) {
+  112  2284
                 token.type = EORECORD;
+  113  146663
             } else if (isQuoteChar(c)) {
 114  
                 // consume encapsulated token
-  115  555241
                 encapsulatedTokenLexer(token);
-  116  322815
             } else if (isEndOfFile(c)) {
+  115  92723
                 parseEncapsulatedToken(token);
+  116  53940
             } else if (isEndOfFile(c)) {
 117  
                 // end of file return EOF()
 118  
                 // noop: tkn.content.append("");
-  119  36
                 token.type = EOF;
-  120  36
                 token.isReady = true; // there is data at EOF
+  119  6
                 token.type = EOF;
+  120  6
                 token.isReady = true; // there is data at EOF
 121  
             } else {
 122  
                 // next token must be a simple token
 123  
                 // add removed blanks when not ignoring whitespace chars...
-  124  322779
                 simpleTokenLexer(token, c);
+  124  53934
                 parseSimpleToken(token, c);
 125  
             }
 126  
         }
-  127  903349
         return token;
+  127  150675
         return token;
 128  
     }
 129   @@ -241,7 +241,7 @@  130  
     /**
 131   -
      * A simple token lexer
+
      * Parses a simple token.
 132  
      * <p/>
 133   @@ -277,41 +277,41 @@  148  
      */
 149   -
     private Token simpleTokenLexer(final Token tkn, int c) throws IOException {
+
     private Token parseSimpleToken(final Token tkn, int c) throws IOException {
 150  
         // Faster to use while(true)+break than while(tkn.type == INVALID)
 151  
         while (true) {
-  152  3570640
             if (readEndOfLine(c)) {
-  153  163850
                 tkn.type = EORECORD;
-  154  163850
                 break;
-  155  3406790
             } else if (isEndOfFile(c)) {
-  156  120
                 tkn.type = EOF;
-  157  120
                 tkn.isReady = true; // There is data at EOF
-  158  120
                 break;
-  159  3406670
             } else if (isDelimiter(c)) {
-  160  158803
                 tkn.type = TOKEN;
-  161  158803
                 break;
-  162  3247867
             } else if (isEscape(c)) {
-  163  638890
                 tkn.content.append((char) readEscape());
-  164  638884
                 c = in.read(); // continue
+  152  593839
             if (readEndOfLine(c)) {
+  153  27444
                 tkn.type = EORECORD;
+  154  27444
                 break;
+  155  566395
             } else if (isEndOfFile(c)) {
+  156  27
                 tkn.type = EOF;
+  157  27
                 tkn.isReady = true; // There is data at EOF
+  158  27
                 break;
+  159  566368
             } else if (isDelimiter(c)) {
+  160  26462
                 tkn.type = TOKEN;
+  161  26462
                 break;
+  162  539906
             } else if (isEscape(c)) {
+  163  106517
                 tkn.content.append((char) readEscape());
+  164  106516
                 c = in.read(); // continue
 165  
             } else {
-  166  2608977
                 tkn.content.append((char) c);
-  167  2608977
                 c = in.read(); // continue
+  166  433389
                 tkn.content.append((char) c);
+  167  433389
                 c = in.read(); // continue
 168  
             }
 169  
         }
 170  
 
-  171  322773
         if (ignoreSurroundingSpaces) {
-  172  354
             trimTrailingSpaces(tkn.content);
+  171  53933
         if (ignoreSurroundingSpaces) {
+  172  59
             trimTrailingSpaces(tkn.content);
 173  
         }
 174  
 
-  175  322773
         return tkn;
+  175  53933
         return tkn;
 176  
     }
 177   @@ -319,7 +319,7 @@  178  
     /**
 179   -
      * An encapsulated token lexer
+
      * Parses an encapsulated token.
 180  
      * <p/>
 181   @@ -357,43 +357,43 @@  197  
      */
 198   -
     private Token encapsulatedTokenLexer(final Token tkn) throws IOException {
+
     private Token parseEncapsulatedToken(final Token tkn) throws IOException {
 199  
         // save current line number in case needed for IOE
-  200  555241
         final long startLineNumber = getLineNumber();
+  200  92723
         final long startLineNumber = getLineNumber();
 201  
         int c;
 202  
         while (true) {
-  203  6476391
             c = in.read();
+  203  1075895
             c = in.read();
 204  
 
-  205  6476391
             if (isEscape(c)) {
-  206  24
                 tkn.content.append((char) readEscape());
-  207  6476367
             } else if (isQuoteChar(c)) {
-  208  871485
                 if (isQuoteChar(in.lookAhead())) {
+  205  1075895
             if (isEscape(c)) {
+  206  4
                 tkn.content.append((char) readEscape());
+  207  1075891
             } else if (isQuoteChar(c)) {
+  208  145163
                 if (isQuoteChar(in.lookAhead())) {
 209  
                     // double or escaped encapsulator -> add single encapsulator to token
-  210  316244
                     c = in.read();
-  211  316244
                     tkn.content.append((char) c);
+  210  52440
                     c = in.read();
+  211  52440
                     tkn.content.append((char) c);
 212  
                 } else {
 213  
                     // token finish mark (encapsulator) reached: ignore whitespace till delimiter
 214  
                     while (true) {
-  215  555295
                         c = in.read();
-  216  555295
                         if (isDelimiter(c)) {
-  217  282917
                             tkn.type = TOKEN;
-  218  282917
                             return tkn;
-  219  272378
                         } else if (isEndOfFile(c)) {
-  220  36
                             tkn.type = EOF;
-  221  36
                             tkn.isReady = true; // There is data at EOF
-  222  36
                             return tkn;
-  223  272342
                         } else if (readEndOfLine(c)) {
-  224  272288
                             tkn.type = EORECORD;
-  225  272288
                             return tkn;
-  226  54
                         } else if (!isWhitespace(c)) {
+  215  92732
                         c = in.read();
+  216  92732
                         if (isDelimiter(c)) {
+  217  47360
                             tkn.type = TOKEN;
+  218  47360
                             return tkn;
+  219  45372
                         } else if (isEndOfFile(c)) {
+  220  6
                             tkn.type = EOF;
+  221  6
                             tkn.isReady = true; // There is data at EOF
+  222  6
                             return tkn;
+  223  45366
                         } else if (readEndOfLine(c)) {
+  224  45357
                             tkn.type = EORECORD;
+  225  45357
                             return tkn;
+  226  9
                         } else if (!isWhitespace(c)) {
 227  
                             // error invalid char between token and next delimiter
 228  0
                             throw new IOException("(line " + getLineNumber() +
@@ -405,7 +405,7 @@
                     }
 232  
                 }
-  233  5604882
             } else if (isEndOfFile(c)) {
+  233  930728
             } else if (isEndOfFile(c)) {
 234  
                 // error condition (end of file before end of token)
 235  0
                 throw new IOException("(startline " + startLineNumber +
@@ -415,7 +415,7 @@
             } else {
 238  
                 // consume character
-  239  5604882
                 tkn.content.append((char) c);
+  239  930728
                 tkn.content.append((char) c);
 240  
             }
 241   @@ -428,6 +428,6 @@
 }
- + \ No newline at end of file