lucene-java-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From uschind...@apache.org
Subject svn commit: r821185 [2/2] - in /lucene/java/trunk: contrib/analyzers/common/src/java/org/apache/lucene/analysis/compound/hyphenation/ contrib/analyzers/common/src/java/org/apache/lucene/analysis/de/ contrib/analyzers/common/src/java/org/apache/lucene/a...
Date Fri, 02 Oct 2009 22:11:14 GMT
Modified: lucene/java/trunk/src/java/org/apache/lucene/search/MatchAllDocsQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/MatchAllDocsQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/MatchAllDocsQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/MatchAllDocsQuery.java Fri Oct  2
22:11:10 2009
@@ -150,7 +150,7 @@
   }
 
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     buffer.append("*:*");
     buffer.append(ToStringUtils.boost(getBoost()));
     return buffer.toString();

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/MultiPhraseQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/MultiPhraseQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/MultiPhraseQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/MultiPhraseQuery.java Fri Oct  2 22:11:10
2009
@@ -271,7 +271,7 @@
 
   /** Prints a user-readable version of this query. */
   public final String toString(String f) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     if (!field.equals(f)) {
       buffer.append(field);
       buffer.append(":");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/MultiTermQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/MultiTermQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/MultiTermQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/MultiTermQuery.java Fri Oct  2 22:11:10
2009
@@ -393,7 +393,7 @@
    */
   @Override
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     if (term != null) {
       if (!term.field().equals(field)) {
         buffer.append(term.field());

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/NumericRangeQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/NumericRangeQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/NumericRangeQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/NumericRangeQuery.java Fri Oct  2
22:11:10 2009
@@ -317,7 +317,7 @@
   
   @Override
   public String toString(final String field) {
-    final StringBuffer sb = new StringBuffer();
+    final StringBuilder sb = new StringBuilder();
     if (!this.field.equals(field)) sb.append(this.field).append(':');
     return sb.append(minInclusive ? '[' : '{')
       .append((min == null) ? "*" : min.toString())

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/PhraseQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/PhraseQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/PhraseQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/PhraseQuery.java Fri Oct  2 22:11:10
2009
@@ -167,8 +167,8 @@
       Explanation result = new Explanation();
       result.setDescription("weight("+getQuery()+" in "+doc+"), product of:");
 
-      StringBuffer docFreqs = new StringBuffer();
-      StringBuffer query = new StringBuffer();
+      StringBuilder docFreqs = new StringBuilder();
+      StringBuilder query = new StringBuilder();
       query.append('\"');
       docFreqs.append(idfExp.explain());
       for (int i = 0; i < terms.size(); i++) {
@@ -259,7 +259,7 @@
 
   /** Prints a user-readable version of this query. */
   public String toString(String f) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     if (field != null && !field.equals(f)) {
       buffer.append(field);
       buffer.append(":");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/PrefixFilter.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/PrefixFilter.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/PrefixFilter.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/PrefixFilter.java Fri Oct  2 22:11:10
2009
@@ -33,7 +33,7 @@
 
   /** Prints a user-readable version of this query. */
   public String toString () {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     buffer.append("PrefixFilter(");
     buffer.append(getPrefix().toString());
     buffer.append(")");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/PrefixQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/PrefixQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/PrefixQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/PrefixQuery.java Fri Oct  2 22:11:10
2009
@@ -47,7 +47,7 @@
 
   /** Prints a user-readable version of this query. */
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     if (!prefix.field().equals(field)) {
       buffer.append(prefix.field());
       buffer.append(":");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/QueryTermVector.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/QueryTermVector.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/QueryTermVector.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/QueryTermVector.java Fri Oct  2 22:11:10
2009
@@ -108,7 +108,7 @@
   }
   
   public final String toString() {
-        StringBuffer sb = new StringBuffer();
+        StringBuilder sb = new StringBuilder();
         sb.append('{');
         for (int i=0; i<terms.length; i++) {
             if (i>0) sb.append(", ");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/Similarity.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/Similarity.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/Similarity.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/Similarity.java Fri Oct  2 22:11:10
2009
@@ -826,7 +826,7 @@
     }
     final int max = searcher.maxDoc();
     float idf = 0.0f;
-    final StringBuffer exp = new StringBuffer();
+    final StringBuilder exp = new StringBuilder();
     Iterator i = terms.iterator();
     while (i.hasNext()) {
       Term term = (Term)i.next();

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/Sort.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/Sort.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/Sort.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/Sort.java Fri Oct  2 22:11:10 2009
@@ -229,7 +229,7 @@
   }
 
   public String toString() {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
 
     for (int i = 0; i < fields.length; i++) {
       buffer.append(fields[i].toString());

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/SortField.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/SortField.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/SortField.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/SortField.java Fri Oct  2 22:11:10
2009
@@ -347,7 +347,7 @@
   }
 
   public String toString() {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     switch (type) {
       case SCORE:
         buffer.append("<score>");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/TermQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/TermQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/TermQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/TermQuery.java Fri Oct  2 22:11:10
2009
@@ -152,7 +152,7 @@
 
   /** Prints a user-readable version of this query. */
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     if (!term.field().equals(field)) {
       buffer.append(term.field());
       buffer.append(":");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/TermRangeQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/TermRangeQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/TermRangeQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/TermRangeQuery.java Fri Oct  2 22:11:10
2009
@@ -137,7 +137,7 @@
 
   /** Prints a user-readable version of this query. */
   public String toString(String field) {
-      StringBuffer buffer = new StringBuffer();
+      StringBuilder buffer = new StringBuilder();
       if (!getField().equals(field)) {
           buffer.append(getField());
           buffer.append(":");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/WildcardQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/WildcardQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/WildcardQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/WildcardQuery.java Fri Oct  2 22:11:10
2009
@@ -65,7 +65,7 @@
   
   /** Prints a user-readable version of this query. */
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     if (!term.field().equals(field)) {
       buffer.append(term.field());
       buffer.append(":");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/function/CustomScoreQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/function/CustomScoreQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/function/CustomScoreQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/function/CustomScoreQuery.java Fri
Oct  2 22:11:10 2009
@@ -118,7 +118,7 @@
 
   /* (non-Javadoc) @see org.apache.lucene.search.Query#toString(java.lang.String) */
   public String toString(String field) {
-    StringBuffer sb = new StringBuffer(name()).append("(");
+    StringBuilder sb = new StringBuilder(name()).append("(");
     sb.append(subQuery.toString(field));
     for(int i = 0; i < valSrcQueries.length; i++) {
       sb.append(", ").append(valSrcQueries[i].toString(field));

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/payloads/PayloadNearQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/payloads/PayloadNearQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/payloads/PayloadNearQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/payloads/PayloadNearQuery.java Fri
Oct  2 22:11:10 2009
@@ -85,7 +85,7 @@
   }
 
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     buffer.append("payloadNear([");
     Iterator i = clauses.iterator();
     while (i.hasNext()) {

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/spans/FieldMaskingSpanQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/spans/FieldMaskingSpanQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/spans/FieldMaskingSpanQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/spans/FieldMaskingSpanQuery.java Fri
Oct  2 22:11:10 2009
@@ -128,7 +128,7 @@
   }
 
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     buffer.append("mask(");
     buffer.append(maskedQuery.toString(field));
     buffer.append(")");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanFirstQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanFirstQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanFirstQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanFirstQuery.java Fri Oct
 2 22:11:10 2009
@@ -54,7 +54,7 @@
   public Collection getTerms() { return match.getTerms(); }
 
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     buffer.append("spanFirst(");
     buffer.append(match.toString(field));
     buffer.append(", ");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanNearQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanNearQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanNearQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanNearQuery.java Fri Oct 
2 22:11:10 2009
@@ -104,7 +104,7 @@
   
 
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     buffer.append("spanNear([");
     Iterator i = clauses.iterator();
     while (i.hasNext()) {

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanNotQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanNotQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanNotQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanNotQuery.java Fri Oct  2
22:11:10 2009
@@ -58,7 +58,7 @@
   public void extractTerms(Set terms) { include.extractTerms(terms); }
 
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     buffer.append("spanNot(");
     buffer.append(include.toString(field));
     buffer.append(", ");

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanOrQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanOrQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanOrQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanOrQuery.java Fri Oct  2
22:11:10 2009
@@ -112,7 +112,7 @@
   }
 
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     buffer.append("spanOr([");
     Iterator i = clauses.iterator();
     while (i.hasNext()) {

Modified: lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanTermQuery.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanTermQuery.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanTermQuery.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/search/spans/SpanTermQuery.java Fri Oct 
2 22:11:10 2009
@@ -52,7 +52,7 @@
   }
 
   public String toString(String field) {
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     if (term.field().equals(field))
       buffer.append(term.text());
     else

Modified: lucene/java/trunk/src/java/org/apache/lucene/store/FSDirectory.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/store/FSDirectory.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/store/FSDirectory.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/store/FSDirectory.java Fri Oct  2 22:11:10
2009
@@ -718,7 +718,7 @@
     synchronized (DIGESTER) {
       digest = DIGESTER.digest(dirName.getBytes());
     }
-    StringBuffer buf = new StringBuffer();
+    StringBuilder buf = new StringBuilder();
     buf.append("lucene-");
     for (int i = 0; i < digest.length; i++) {
       int b = digest[i];

Modified: lucene/java/trunk/src/java/org/apache/lucene/util/FieldCacheSanityChecker.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/util/FieldCacheSanityChecker.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/util/FieldCacheSanityChecker.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/util/FieldCacheSanityChecker.java Fri Oct
 2 22:11:10 2009
@@ -366,7 +366,7 @@
      * own line prefaced by a tab character
      */
     public String toString() {
-      StringBuffer buf = new StringBuffer();
+      StringBuilder buf = new StringBuilder();
       buf.append(getType()).append(": ");
 
       String m = getMsg();

Modified: lucene/java/trunk/src/test/org/apache/lucene/analysis/TestASCIIFoldingFilter.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/analysis/TestASCIIFoldingFilter.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/analysis/TestASCIIFoldingFilter.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/analysis/TestASCIIFoldingFilter.java Fri
Oct  2 22:11:10 2009
@@ -1872,7 +1872,7 @@
 
     // Construct input text and expected output tokens
     List expectedOutputTokens = new ArrayList();
-    StringBuffer inputText = new StringBuffer();
+    StringBuilder inputText = new StringBuilder();
     for (int n = 0 ; n < foldings.length ; n += 2) {
       if (n > 0) {
         inputText.append(' ');  // Space between tokens
@@ -1881,7 +1881,7 @@
 
       // Construct the expected output token: the ASCII string to fold to,
       // duplicated as many times as the number of characters in the input text.
-      StringBuffer expected = new StringBuffer();
+      StringBuilder expected = new StringBuilder();
       int numChars = foldings[n].length();
       for (int m = 0 ; m < numChars; ++m) {
         expected.append(foldings[n + 1]);

Modified: lucene/java/trunk/src/test/org/apache/lucene/analysis/TestCharArraySet.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/analysis/TestCharArraySet.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/analysis/TestCharArraySet.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/analysis/TestCharArraySet.java Fri Oct  2
22:11:10 2009
@@ -108,7 +108,7 @@
     }
     
     try{
-      set.add(new StringBuffer(NOT_IN_SET));  
+      set.add(new StringBuilder(NOT_IN_SET));  
       fail("Modified unmodifiable set");
     }catch (UnsupportedOperationException e) {
       // expected

Modified: lucene/java/trunk/src/test/org/apache/lucene/analysis/TestStopFilter.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/analysis/TestStopFilter.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/analysis/TestStopFilter.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/analysis/TestStopFilter.java Fri Oct  2 22:11:10
2009
@@ -71,7 +71,7 @@
    * Test Position increments applied by StopFilter with and without enabling this option.
    */
   public void testStopPositons() throws IOException {
-    StringBuffer sb = new StringBuffer();
+    StringBuilder sb = new StringBuilder();
     ArrayList a = new ArrayList();
     for (int i=0; i<20; i++) {
       String w = English.intToEnglish(i).trim();

Modified: lucene/java/trunk/src/test/org/apache/lucene/analysis/TestTeeSinkTokenFilter.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/analysis/TestTeeSinkTokenFilter.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/analysis/TestTeeSinkTokenFilter.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/analysis/TestTeeSinkTokenFilter.java Fri
Oct  2 22:11:10 2009
@@ -32,8 +32,8 @@
  * tests for the TestTeeSinkTokenFilter
  */
 public class TestTeeSinkTokenFilter extends BaseTokenStreamTestCase {
-  protected StringBuffer buffer1;
-  protected StringBuffer buffer2;
+  protected StringBuilder buffer1;
+  protected StringBuilder buffer2;
   protected String[] tokens1;
   protected String[] tokens2;
 
@@ -46,12 +46,12 @@
     super.setUp();
     tokens1 = new String[]{"The", "quick", "Burgundy", "Fox", "jumped", "over", "the", "lazy",
"Red", "Dogs"};
     tokens2 = new String[]{"The", "Lazy", "Dogs", "should", "stay", "on", "the", "porch"};
-    buffer1 = new StringBuffer();
+    buffer1 = new StringBuilder();
 
     for (int i = 0; i < tokens1.length; i++) {
       buffer1.append(tokens1[i]).append(' ');
     }
-    buffer2 = new StringBuffer();
+    buffer2 = new StringBuilder();
     for (int i = 0; i < tokens2.length; i++) {
       buffer2.append(tokens2[i]).append(' ');
     }
@@ -161,7 +161,7 @@
     int[] tokCount = {100, 500, 1000, 2000, 5000, 10000};
     int[] modCounts = {1, 2, 5, 10, 20, 50, 100, 200, 500};
     for (int k = 0; k < tokCount.length; k++) {
-      StringBuffer buffer = new StringBuffer();
+      StringBuilder buffer = new StringBuilder();
       System.out.println("-----Tokens: " + tokCount[k] + "-----");
       for (int i = 0; i < tokCount[k]; i++) {
         buffer.append(English.intToEnglish(i).toUpperCase()).append(' ');

Modified: lucene/java/trunk/src/test/org/apache/lucene/analysis/TestTeeTokenFilter.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/analysis/TestTeeTokenFilter.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/analysis/TestTeeTokenFilter.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/analysis/TestTeeTokenFilter.java Fri Oct
 2 22:11:10 2009
@@ -30,8 +30,8 @@
  * tests for the TeeTokenFilter and SinkTokenizer
  */
 public class TestTeeTokenFilter extends LuceneTestCase {
-  protected StringBuffer buffer1;
-  protected StringBuffer buffer2;
+  protected StringBuilder buffer1;
+  protected StringBuilder buffer2;
   protected String[] tokens1;
   protected String[] tokens2;
 
@@ -44,12 +44,12 @@
     super.setUp();
     tokens1 = new String[]{"The", "quick", "Burgundy", "Fox", "jumped", "over", "the", "lazy",
"Red", "Dogs"};
     tokens2 = new String[]{"The", "Lazy", "Dogs", "should", "stay", "on", "the", "porch"};
-    buffer1 = new StringBuffer();
+    buffer1 = new StringBuilder();
 
     for (int i = 0; i < tokens1.length; i++) {
       buffer1.append(tokens1[i]).append(' ');
     }
-    buffer2 = new StringBuffer();
+    buffer2 = new StringBuilder();
     for (int i = 0; i < tokens2.length; i++) {
       buffer2.append(tokens2[i]).append(' ');
 
@@ -147,7 +147,7 @@
     int[] tokCount = {100, 500, 1000, 2000, 5000, 10000};
     int[] modCounts = {1, 2, 5, 10, 20, 50, 100, 200, 500};
     for (int k = 0; k < tokCount.length; k++) {
-      StringBuffer buffer = new StringBuffer();
+      StringBuilder buffer = new StringBuilder();
       System.out.println("-----Tokens: " + tokCount[k] + "-----");
       for (int i = 0; i < tokCount[k]; i++) {
         buffer.append(English.intToEnglish(i).toUpperCase()).append(' ');

Modified: lucene/java/trunk/src/test/org/apache/lucene/analysis/TestToken.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/analysis/TestToken.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/analysis/TestToken.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/analysis/TestToken.java Fri Oct  2 22:11:10
2009
@@ -71,7 +71,7 @@
 
   public void testGrow() {
     Token t = new Token();
-    StringBuffer buf = new StringBuffer("ab");
+    StringBuilder buf = new StringBuilder("ab");
     for (int i = 0; i < 20; i++)
     {
       char[] content = buf.toString().toCharArray();
@@ -85,7 +85,7 @@
 
     // now as a string, first variant
     t = new Token();
-    buf = new StringBuffer("ab");
+    buf = new StringBuilder("ab");
     for (int i = 0; i < 20; i++)
     {
       String content = buf.toString();
@@ -99,7 +99,7 @@
 
     // now as a string, second variant
     t = new Token();
-    buf = new StringBuffer("ab");
+    buf = new StringBuilder("ab");
     for (int i = 0; i < 20; i++)
     {
       String content = buf.toString();
@@ -113,7 +113,7 @@
 
     // Test for slow growth to a long term
     t = new Token();
-    buf = new StringBuffer("a");
+    buf = new StringBuilder("a");
     for (int i = 0; i < 20000; i++)
     {
       String content = buf.toString();
@@ -127,7 +127,7 @@
 
     // Test for slow growth to a long term
     t = new Token();
-    buf = new StringBuffer("a");
+    buf = new StringBuilder("a");
     for (int i = 0; i < 20000; i++)
     {
       String content = buf.toString();

Modified: lucene/java/trunk/src/test/org/apache/lucene/analysis/tokenattributes/TestTermAttributeImpl.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/analysis/tokenattributes/TestTermAttributeImpl.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/analysis/tokenattributes/TestTermAttributeImpl.java
(original)
+++ lucene/java/trunk/src/test/org/apache/lucene/analysis/tokenattributes/TestTermAttributeImpl.java
Fri Oct  2 22:11:10 2009
@@ -39,7 +39,7 @@
 
   public void testGrow() {
     TermAttributeImpl t = new TermAttributeImpl();
-    StringBuffer buf = new StringBuffer("ab");
+    StringBuilder buf = new StringBuilder("ab");
     for (int i = 0; i < 20; i++)
     {
       char[] content = buf.toString().toCharArray();
@@ -53,7 +53,7 @@
 
     // now as a string, first variant
     t = new TermAttributeImpl();
-    buf = new StringBuffer("ab");
+    buf = new StringBuilder("ab");
     for (int i = 0; i < 20; i++)
     {
       String content = buf.toString();
@@ -67,7 +67,7 @@
 
     // now as a string, second variant
     t = new TermAttributeImpl();
-    buf = new StringBuffer("ab");
+    buf = new StringBuilder("ab");
     for (int i = 0; i < 20; i++)
     {
       String content = buf.toString();
@@ -81,7 +81,7 @@
 
     // Test for slow growth to a long term
     t = new TermAttributeImpl();
-    buf = new StringBuffer("a");
+    buf = new StringBuilder("a");
     for (int i = 0; i < 20000; i++)
     {
       String content = buf.toString();
@@ -95,7 +95,7 @@
 
     // Test for slow growth to a long term
     t = new TermAttributeImpl();
-    buf = new StringBuffer("a");
+    buf = new StringBuilder("a");
     for (int i = 0; i < 20000; i++)
     {
       String content = buf.toString();

Modified: lucene/java/trunk/src/test/org/apache/lucene/index/DocHelper.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/index/DocHelper.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/index/DocHelper.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/index/DocHelper.java Fri Oct  2 22:11:10
2009
@@ -152,7 +152,7 @@
 
   static {
     //Initialize the large Lazy Field
-    StringBuffer buffer = new StringBuffer();
+    StringBuilder buffer = new StringBuilder();
     for (int i = 0; i < 10000; i++)
     {
       buffer.append("Lazily loading lengths of language in lieu of laughing ");

Modified: lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexReaderReopen.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexReaderReopen.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexReaderReopen.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexReaderReopen.java Fri Oct
 2 22:11:10 2009
@@ -955,7 +955,7 @@
   }
 
   public static Document createDocument(int n, int numFields) {
-    StringBuffer sb = new StringBuffer();
+    StringBuilder sb = new StringBuilder();
     Document doc = new Document();
     sb.append("a");
     sb.append(n);

Modified: lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexWriter.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexWriter.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexWriter.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexWriter.java Fri Oct  2 22:11:10
2009
@@ -1440,7 +1440,7 @@
         // occurs but the terms are very long (heavy on
         // char[] arrays)
         for(int j=0;j<100;j++) {
-          StringBuffer b = new StringBuffer();
+          StringBuilder b = new StringBuilder();
           String x = Integer.toString(j) + ".";
           for(int k=0;k<1000;k++)
             b.append(x);
@@ -1513,7 +1513,7 @@
       IndexWriter writer  = new IndexWriter(dir, new WhitespaceAnalyzer(), true, new IndexWriter.MaxFieldLength(100000000));
       writer.setRAMBufferSizeMB(0.01);
       // Massive doc that has 128 K a's
-      StringBuffer b = new StringBuffer(1024*1024);
+      StringBuilder b = new StringBuilder(1024*1024);
       for(int i=0;i<4096;i++) {
         b.append(" a a a a a a a a");
         b.append(" a a a a a a a a");
@@ -2677,7 +2677,7 @@
     IndexWriter writer = new IndexWriter(dir, new WhitespaceAnalyzer(), IndexWriter.MaxFieldLength.UNLIMITED);
 
     Document doc = new Document();
-    StringBuffer b = new StringBuffer();
+    StringBuilder b = new StringBuilder();
     for(int i=0;i<10000;i++)
       b.append(" a");
     b.append(" x");
@@ -2957,7 +2957,7 @@
     IndexWriter writer = new IndexWriter(dir, new WhitespaceAnalyzer(), new IndexWriter.MaxFieldLength(100000));
 
     Document doc = new Document();
-    StringBuffer b = new StringBuffer();
+    StringBuilder b = new StringBuilder();
     for(int i=0;i<10000;i++)
       b.append(" a");
     b.append(" x");

Modified: lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexWriterReader.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexWriterReader.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexWriterReader.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/index/TestIndexWriterReader.java Fri Oct
 2 22:11:10 2009
@@ -509,7 +509,7 @@
 
   
   public static Document createDocument(int n, String indexName, int numFields) {
-    StringBuffer sb = new StringBuffer();
+    StringBuilder sb = new StringBuilder();
     Document doc = new Document();
     doc.add(new Field("id", Integer.toString(n), Store.YES, Index.NOT_ANALYZED, TermVector.WITH_POSITIONS_OFFSETS));
     doc.add(new Field("indexname", indexName, Store.YES, Index.NOT_ANALYZED, TermVector.WITH_POSITIONS_OFFSETS));

Modified: lucene/java/trunk/src/test/org/apache/lucene/index/TestOmitTf.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/index/TestOmitTf.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/index/TestOmitTf.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/index/TestOmitTf.java Fri Oct  2 22:11:10
2009
@@ -242,7 +242,7 @@
     writer.setSimilarity(new SimpleSimilarity());
         
         
-    StringBuffer sb = new StringBuffer(265);
+    StringBuilder sb = new StringBuilder(265);
     String term = "term";
     for(int i = 0; i<30; i++){
       Document d = new Document();

Modified: lucene/java/trunk/src/test/org/apache/lucene/index/TestPayloads.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/index/TestPayloads.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/index/TestPayloads.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/index/TestPayloads.java Fri Oct  2 22:11:10
2009
@@ -179,7 +179,7 @@
         int numDocs = skipInterval + 1; 
         // create content for the test documents with just a few terms
         Term[] terms = generateTerms(fieldName, numTerms);
-        StringBuffer sb = new StringBuffer();
+        StringBuilder sb = new StringBuilder();
         for (int i = 0; i < terms.length; i++) {
             sb.append(terms[i].text);
             sb.append(" ");
@@ -350,7 +350,7 @@
     private Term[] generateTerms(String fieldName, int n) {
         int maxDigits = (int) (Math.log(n) / Math.log(10));
         Term[] terms = new Term[n];
-        StringBuffer sb = new StringBuffer();
+        StringBuilder sb = new StringBuilder();
         for (int i = 0; i < n; i++) {
             sb.setLength(0);
             sb.append("t");

Modified: lucene/java/trunk/src/test/org/apache/lucene/search/BaseTestRangeFilter.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/search/BaseTestRangeFilter.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/search/BaseTestRangeFilter.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/search/BaseTestRangeFilter.java Fri Oct 
2 22:11:10 2009
@@ -65,7 +65,7 @@
      * a simple padding function that should work with any int
      */
     public static String pad(int n) {
-        StringBuffer b = new StringBuffer(40);
+        StringBuilder b = new StringBuilder(40);
         String p = "0";
         if (n < 0) {
             p = "-";

Modified: lucene/java/trunk/src/test/org/apache/lucene/search/CheckHits.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/search/CheckHits.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/search/CheckHits.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/search/CheckHits.java Fri Oct  2 22:11:10
2009
@@ -223,7 +223,7 @@
   }
 
   public static String hits2str(ScoreDoc[] hits1, ScoreDoc[] hits2, int start, int end) throws
IOException {
-    StringBuffer sb = new StringBuffer();
+    StringBuilder sb = new StringBuilder();
     int len1=hits1==null ? 0 : hits1.length;
     int len2=hits2==null ? 0 : hits2.length;
     if (end<=0) {
@@ -251,7 +251,7 @@
 
 
   public static String topdocsString(TopDocs docs, int start, int end) {
-    StringBuffer sb = new StringBuffer();
+    StringBuilder sb = new StringBuilder();
       sb.append("TopDocs totalHits=").append(docs.totalHits).append(" top=").append(docs.scoreDocs.length).append('\n');
     if (end<=0) end=docs.scoreDocs.length;
     else end=Math.min(end,docs.scoreDocs.length);

Modified: lucene/java/trunk/src/test/org/apache/lucene/search/QueryUtils.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/search/QueryUtils.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/search/QueryUtils.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/search/QueryUtils.java Fri Oct  2 22:11:10
2009
@@ -312,7 +312,7 @@
               float scorerDiff = Math.abs(scorerScore2 - scorerScore);
               if (!more || doc != sdoc[0] || scoreDiff > maxDiff
                   || scorerDiff > maxDiff) {
-                StringBuffer sbord = new StringBuffer();
+                StringBuilder sbord = new StringBuilder();
                 for (int i = 0; i < order.length; i++)
                   sbord.append(order[i] == skip_op ? " skip()" : " next()");
                 throw new RuntimeException("ERROR matching docs:" + "\n\t"

Modified: lucene/java/trunk/src/test/org/apache/lucene/search/TestCustomSearcherSort.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/search/TestCustomSearcherSort.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/search/TestCustomSearcherSort.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/search/TestCustomSearcherSort.java Fri Oct
 2 22:11:10 2009
@@ -195,7 +195,7 @@
 
                 luceneId = new Integer(hits[docnum].doc);
                 if(idMap.containsKey(luceneId)) {
-                    StringBuffer message = new StringBuffer(prefix);
+                    StringBuilder message = new StringBuilder(prefix);
                     message.append("Duplicate key for hit index = ");
                     message.append(docnum);
                     message.append(", previous index = ");

Modified: lucene/java/trunk/src/test/org/apache/lucene/search/TestMultiThreadTermVectors.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/search/TestMultiThreadTermVectors.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/search/TestMultiThreadTermVectors.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/search/TestMultiThreadTermVectors.java Fri
Oct  2 22:11:10 2009
@@ -177,7 +177,7 @@
   }
   
   private void verifyVectors(TermFreqVector[] vectors, int num) {
-    StringBuffer temp = new StringBuffer();
+    StringBuilder temp = new StringBuilder();
     String[] terms = null;
     for (int i = 0; i < vectors.length; i++) {
       terms = vectors[i].getTerms();

Modified: lucene/java/trunk/src/test/org/apache/lucene/search/TestSort.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/search/TestSort.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/search/TestSort.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/search/TestSort.java Fri Oct  2 22:11:10
2009
@@ -164,7 +164,7 @@
   }
   
   public String getRandomNumberString(int num, int low, int high) {
-    StringBuffer sb = new StringBuffer();
+    StringBuilder sb = new StringBuilder();
     for (int i = 0; i < num; i++) {
       sb.append(getRandomNumber(low, high));
     }
@@ -176,7 +176,7 @@
   }
   
   public String getRandomCharString(int num, int start, int end) {
-    StringBuffer sb = new StringBuffer();
+    StringBuilder sb = new StringBuilder();
     for (int i = 0; i < num; i++) {
       sb.append(new Character((char) getRandomNumber(start, end)));
     }
@@ -277,7 +277,7 @@
 
     result = searcher.search(new MatchAllDocsQuery(), null, 500, sort).scoreDocs;
 
-    StringBuffer buff = new StringBuffer();
+    StringBuilder buff = new StringBuilder();
     int n = result.length;
     String last = null;
     String lastSub = null;
@@ -998,7 +998,7 @@
     TopDocs hits = searcher.search (query, null, expectedResult.length(), sort);
     ScoreDoc[] result = hits.scoreDocs;
     assertEquals(hits.totalHits, expectedResult.length());
-    StringBuffer buff = new StringBuffer(10);
+    StringBuilder buff = new StringBuilder(10);
     int n = result.length;
     for (int i=0; i<n; ++i) {
       Document doc = searcher.doc(result[i].doc);

Modified: lucene/java/trunk/src/test/org/apache/lucene/search/TestThreadSafe.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/search/TestThreadSafe.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/search/TestThreadSafe.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/search/TestThreadSafe.java Fri Oct  2 22:11:10
2009
@@ -116,7 +116,7 @@
       int nFields = r.nextInt(maxFields);
       for (int i=0; i<nFields; i++) {
         int flen = r.nextInt(maxFieldLen);
-        StringBuffer sb = new StringBuffer("^ ");
+        StringBuilder sb = new StringBuilder("^ ");
         while (sb.length() < flen) sb.append(' ').append(words[r.nextInt(words.length)]);
         sb.append(" $");
         Field.Store store = Field.Store.YES;  // make random later

Modified: lucene/java/trunk/src/test/org/apache/lucene/store/TestWindowsMMap.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/store/TestWindowsMMap.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/store/TestWindowsMMap.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/store/TestWindowsMMap.java Fri Oct  2 22:11:10
2009
@@ -41,7 +41,7 @@
 	
 	private String randomToken() {
 		int tl = 1 + random.nextInt(7);
-		StringBuffer sb = new StringBuffer();
+		StringBuilder sb = new StringBuilder();
 		for(int cx = 0; cx < tl; cx ++) {
 			int c = random.nextInt(25);
 			sb.append(alphabet.substring(c, c+1));
@@ -51,7 +51,7 @@
 	
 	private String randomField() {
 		int fl = 1 + random.nextInt(3);
-		StringBuffer fb = new StringBuffer();
+		StringBuilder fb = new StringBuilder();
 		for(int fx = 0; fx < fl; fx ++) {
 			fb.append(randomToken());
 			fb.append(" ");

Modified: lucene/java/trunk/src/test/org/apache/lucene/util/English.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/util/English.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/util/English.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/util/English.java Fri Oct  2 22:11:10 2009
@@ -21,12 +21,12 @@
 public class English {
 
   public static String intToEnglish(int i) {
-    StringBuffer result = new StringBuffer();
+    StringBuilder result = new StringBuilder();
     intToEnglish(i, result);
     return result.toString();
   }
 
-  public static void intToEnglish(int i, StringBuffer result) {
+  public static void intToEnglish(int i, StringBuilder result) {
     if (i == 0) {
       result.append("zero");
       return;

Modified: lucene/java/trunk/src/test/org/apache/lucene/util/TestIndexableBinaryStringTools.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/util/TestIndexableBinaryStringTools.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/util/TestIndexableBinaryStringTools.java
(original)
+++ lucene/java/trunk/src/test/org/apache/lucene/util/TestIndexableBinaryStringTools.java
Fri Oct  2 22:11:10 2009
@@ -152,7 +152,7 @@
   }
   
   public String binaryDump(ByteBuffer binaryBuf) {
-    StringBuffer buf = new StringBuffer();
+    StringBuilder buf = new StringBuilder();
     int numBytes = binaryBuf.limit() - binaryBuf.arrayOffset();
     byte[] binary = binaryBuf.array();
     for (int byteNum = 0 ; byteNum < numBytes ; ++byteNum) {
@@ -169,7 +169,7 @@
   }
 
   public String charArrayDump(CharBuffer charBuf) {
-    StringBuffer buf = new StringBuffer();
+    StringBuilder buf = new StringBuilder();
     int numBytes = charBuf.limit() - charBuf.arrayOffset();
     char[] charArray = charBuf.array();
     for (int charNum = 0 ; charNum < numBytes ; ++charNum) {

Modified: lucene/java/trunk/src/test/org/apache/lucene/util/_TestUtil.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/test/org/apache/lucene/util/_TestUtil.java?rev=821185&r1=821184&r2=821185&view=diff
==============================================================================
--- lucene/java/trunk/src/test/org/apache/lucene/util/_TestUtil.java (original)
+++ lucene/java/trunk/src/test/org/apache/lucene/util/_TestUtil.java Fri Oct  2 22:11:10 2009
@@ -85,7 +85,7 @@
    *  @deprecated -- in 3.0 we can use Arrays.toString
    *  instead */
   public static String arrayToString(int[] array) {
-    StringBuffer buf = new StringBuffer();
+    StringBuilder buf = new StringBuilder();
     buf.append("[");
     for(int i=0;i<array.length;i++) {
       if (i > 0) {
@@ -101,7 +101,7 @@
    *  @deprecated -- in 3.0 we can use Arrays.toString
    *  instead */
   public static String arrayToString(Object[] array) {
-    StringBuffer buf = new StringBuffer();
+    StringBuilder buf = new StringBuilder();
     buf.append("[");
     for(int i=0;i<array.length;i++) {
       if (i > 0) {



Mime
View raw message