Author: manik.surtani(a)jboss.com
Date: 2008-06-26 19:08:29 -0400 (Thu, 26 Jun 2008)
New Revision: 6075
Modified:
core/trunk/src/main/java/org/jboss/cache/DataContainerImpl.java
core/trunk/src/main/java/org/jboss/cache/Modification.java
core/trunk/src/main/java/org/jboss/cache/NodeSPI.java
core/trunk/src/main/java/org/jboss/cache/UnversionedNode.java
core/trunk/src/main/java/org/jboss/cache/Version.java
core/trunk/src/main/java/org/jboss/cache/commands/read/GetKeyValueCommand.java
core/trunk/src/main/java/org/jboss/cache/invocation/NodeInvocationDelegate.java
core/trunk/src/main/java/org/jboss/cache/lock/IdentityLock.java
core/trunk/src/main/java/org/jboss/cache/lock/LockMap.java
core/trunk/src/main/java/org/jboss/cache/lock/NodeBasedLockManager.java
core/trunk/src/main/java/org/jboss/cache/lock/NodeLock.java
core/trunk/src/main/java/org/jboss/cache/lock/PessimisticNodeBasedLockManager.java
core/trunk/src/main/java/org/jboss/cache/lock/ReadWriteLockWithUpgrade.java
core/trunk/src/main/java/org/jboss/cache/transaction/GlobalTransaction.java
core/trunk/src/main/java/org/jboss/cache/transaction/OptimisticTransactionContext.java
core/trunk/src/main/java/org/jboss/cache/transaction/TransactionTable.java
core/trunk/src/test/java/org/jboss/cache/loader/JDBCCacheLoaderDerbyDSTest.java
core/trunk/src/test/java/org/jboss/cache/loader/JDBCCacheLoaderTest.java
core/trunk/src/test/java/org/jboss/cache/lock/IdentityLockTest.java
core/trunk/src/test/java/org/jboss/cache/statetransfer/StateTransferTestBase.java
Log:
Replaced StringBuffer with StringBuilder
Modified: core/trunk/src/main/java/org/jboss/cache/DataContainerImpl.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/DataContainerImpl.java 2008-06-26 22:59:25
UTC (rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/DataContainerImpl.java 2008-06-26 23:08:29
UTC (rev 6075)
@@ -299,7 +299,7 @@
@SuppressWarnings("deprecation")
public String toString(boolean details)
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
int indent = 0;
if (!details)
@@ -369,7 +369,7 @@
*/
public String printDetails()
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
root.printDetails(sb, 0);
sb.append("\n");
return sb.toString();
Modified: core/trunk/src/main/java/org/jboss/cache/Modification.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/Modification.java 2008-06-26 22:59:25 UTC
(rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/Modification.java 2008-06-26 23:08:29 UTC
(rev 6075)
@@ -266,7 +266,7 @@
@Override
public String toString()
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
sb.append(type.toString()).append(": ").append(fqn);
if (key != null)
{
Modified: core/trunk/src/main/java/org/jboss/cache/NodeSPI.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/NodeSPI.java 2008-06-26 22:59:25 UTC (rev
6074)
+++ core/trunk/src/main/java/org/jboss/cache/NodeSPI.java 2008-06-26 23:08:29 UTC (rev
6075)
@@ -151,21 +151,21 @@
void addChild(Object nodeName, Node<K, V> nodeToAdd);
/**
- * Prints details of this node to the StringBuffer passed in.
+ * Prints details of this node to the StringBuilder passed in.
*
- * @param sb StringBuffer to print to
+ * @param sb StringBuilder to print to
* @param indent depth of this node in the tree. Used to indent details by prepending
spaces.
*/
- void printDetails(StringBuffer sb, int indent);
+ void printDetails(StringBuilder sb, int indent);
/**
- * Prints basic information of this node to the StringBuffer passed in.
+ * Prints basic information of this node to the StringBuilder passed in.
*
- * @param sb StringBuffer to print to
+ * @param sb StringBuilder to print to
* @param indent depth of this node in the tree. Used to indent details by prepending
spaces.
*/
@Deprecated
- void print(StringBuffer sb, int indent);
+ void print(StringBuilder sb, int indent);
// versioning
/**
Modified: core/trunk/src/main/java/org/jboss/cache/UnversionedNode.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/UnversionedNode.java 2008-06-26 22:59:25 UTC
(rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/UnversionedNode.java 2008-06-26 23:08:29 UTC
(rev 6075)
@@ -313,7 +313,7 @@
return data.remove(key);
}
- public void printDetails(StringBuffer sb, int indent)
+ public void printDetails(StringBuilder sb, int indent)
{
printDetailsInMap(sb, indent);
}
@@ -562,7 +562,7 @@
throw new UnsupportedOperationException("Versioning not supported");
}
- private void printIndent(StringBuffer sb, int indent)
+ private void printIndent(StringBuilder sb, int indent)
{
if (sb != null)
{
@@ -666,7 +666,7 @@
/**
* Adds details of the node into a map as strings.
*/
- private void printDetailsInMap(StringBuffer sb, int indent)
+ private void printDetailsInMap(StringBuilder sb, int indent)
{
printIndent(sb, indent);
indent += 2;// increse it
Modified: core/trunk/src/main/java/org/jboss/cache/Version.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/Version.java 2008-06-26 22:59:25 UTC (rev
6074)
+++ core/trunk/src/main/java/org/jboss/cache/Version.java 2008-06-26 23:08:29 UTC (rev
6075)
@@ -46,7 +46,7 @@
public static String printVersionId(byte[] v, int len)
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
if (v != null)
{
if (len <= 0)
@@ -59,7 +59,7 @@
public static String printVersionId(byte[] v)
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
if (v != null)
{
for (byte aV : v) sb.append((char) aV);
Modified: core/trunk/src/main/java/org/jboss/cache/commands/read/GetKeyValueCommand.java
===================================================================
---
core/trunk/src/main/java/org/jboss/cache/commands/read/GetKeyValueCommand.java 2008-06-26
22:59:25 UTC (rev 6074)
+++
core/trunk/src/main/java/org/jboss/cache/commands/read/GetKeyValueCommand.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -54,7 +54,7 @@
{
if (trace)
{
- log.trace(new
StringBuffer("get(").append("\"").append(fqn).append("\",
\"").append(key).append("\", \"").
+ log.trace(new
StringBuilder("get(").append("\"").append(fqn).append("\",
\"").append(key).append("\", \"").
append(sendNodeEvent).append("\")"));
}
NodeSPI n = ctx.lookUpNode(fqn);
Modified: core/trunk/src/main/java/org/jboss/cache/invocation/NodeInvocationDelegate.java
===================================================================
---
core/trunk/src/main/java/org/jboss/cache/invocation/NodeInvocationDelegate.java 2008-06-26
22:59:25 UTC (rev 6074)
+++
core/trunk/src/main/java/org/jboss/cache/invocation/NodeInvocationDelegate.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -110,12 +110,12 @@
node.addChild(nodeName, nodeToAdd);
}
- public void printDetails(StringBuffer sb, int indent)
+ public void printDetails(StringBuilder sb, int indent)
{
node.printDetails(sb, indent);
}
- public void print(StringBuffer sb, int indent)
+ public void print(StringBuilder sb, int indent)
{
throw new CacheException("This method is deprecated!");
}
Modified: core/trunk/src/main/java/org/jboss/cache/lock/IdentityLock.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/lock/IdentityLock.java 2008-06-26 22:59:25
UTC (rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/lock/IdentityLock.java 2008-06-26 23:08:29
UTC (rev 6075)
@@ -155,13 +155,13 @@
{
if (trace)
{
- log.trace(new StringBuffer("acquiring WL:
fqn=").append(getFqn()).append(", caller=").append(caller).
+ log.trace(new StringBuilder("acquiring WL:
fqn=").append(getFqn()).append(", caller=").append(caller).
append(", lock=").append(toString(PRINT_LOCK_DETAILS)));
}
boolean flag = acquireWriteLock0(caller, timeout);
if (trace)
{
- log.trace(new StringBuffer("acquired WL:
fqn=").append(getFqn()).append(", caller=").append(caller).
+ log.trace(new StringBuilder("acquired WL:
fqn=").append(getFqn()).append(", caller=").append(caller).
append(", lock=").append(toString(PRINT_LOCK_DETAILS)));
}
return flag;
@@ -255,13 +255,13 @@
{
if (trace)
{
- log.trace(new StringBuffer("acquiring RL:
fqn=").append(getFqn()).append(", caller=").append(caller).
+ log.trace(new StringBuilder("acquiring RL:
fqn=").append(getFqn()).append(", caller=").append(caller).
append(", lock=").append(toString(PRINT_LOCK_DETAILS)));
}
boolean flag = acquireReadLock0(caller, timeout);
if (trace)
{
- log.trace(new StringBuffer("acquired RL:
fqn=").append(getFqn()).append(", caller=").append(caller).
+ log.trace(new StringBuilder("acquired RL:
fqn=").append(getFqn()).append(", caller=").append(caller).
append(", lock=").append(toString(PRINT_LOCK_DETAILS)));
}
return flag;
@@ -296,7 +296,7 @@
{
if (trace)
{
- StringBuffer sb = new StringBuffer(64);
+ StringBuilder sb = new StringBuilder(64);
sb.append("acquireReadLock(): caller
").append(caller).append(" already owns lock for ").append(getFqn());
log.trace(sb.toString());
}
@@ -308,7 +308,7 @@
// we don't need to synchronize from here on because we own the semaphore
if (!rc)
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
sb.append("read lock for ").append(getFqn()).append(" could not
be acquired by ").append(caller);
sb.append(" after ").append(timeout).append(" ms. " +
"Locks: ").append(map.printInfo());
sb.append(", lock info: ").append(toString(true));
@@ -421,17 +421,17 @@
public String toString(boolean print_lock_details)
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
toString(sb, print_lock_details);
return sb.toString();
}
- public void toString(StringBuffer sb)
+ public void toString(StringBuilder sb)
{
toString(sb, false);
}
- public void toString(StringBuffer sb, boolean print_lock_details)
+ public void toString(StringBuilder sb, boolean print_lock_details)
{
boolean printed_read_owners = false;
Collection<Object> read_owners = lock != null ? getReaderOwners() : null;
@@ -490,7 +490,7 @@
}
catch (UpgradeException e)
{
- StringBuffer buf = new StringBuffer("failure upgrading lock:
fqn=").append(getFqn()).append(", caller=").append(caller).
+ StringBuilder buf = new StringBuilder("failure upgrading lock:
fqn=").append(getFqn()).append(", caller=").append(caller).
append(", lock=").append(toString(true));
if (trace)
{
@@ -500,7 +500,7 @@
}
catch (LockingException e)
{
- StringBuffer buf = new StringBuffer("failure acquiring lock:
fqn=").append(getFqn()).append(", caller=").append(caller).
+ StringBuilder buf = new StringBuilder("failure acquiring lock:
fqn=").append(getFqn()).append(", caller=").append(caller).
append(", lock=").append(toString(true));
if (trace)
{
@@ -510,7 +510,7 @@
}
catch (TimeoutException e)
{
- StringBuffer buf = new StringBuffer("failure acquiring lock:
fqn=").append(getFqn()).append(", caller=").append(caller).
+ StringBuilder buf = new StringBuilder("failure acquiring lock:
fqn=").append(getFqn()).append(", caller=").append(caller).
append(", lock=").append(toString(true));
if (trace)
{
@@ -559,7 +559,7 @@
release(owner);
}
- private void printIndent(StringBuffer sb, int indent)
+ private void printIndent(StringBuilder sb, int indent)
{
if (sb != null)
{
@@ -570,7 +570,7 @@
}
}
- public void printLockInfo(StringBuffer sb, int indent)
+ public void printLockInfo(StringBuilder sb, int indent)
{
boolean locked = isLocked();
Modified: core/trunk/src/main/java/org/jboss/cache/lock/LockMap.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/lock/LockMap.java 2008-06-26 22:59:25 UTC
(rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/lock/LockMap.java 2008-06-26 23:08:29 UTC
(rev 6075)
@@ -187,7 +187,7 @@
*/
public String printInfo()
{
- StringBuffer buf = new StringBuffer(64);
+ StringBuilder buf = new StringBuilder(64);
buf.append("Read lock owners:
").append(readOwners).append('\n');
buf.append("Write lock owner:
").append(writeOwner_).append('\n');
return buf.toString();
Modified: core/trunk/src/main/java/org/jboss/cache/lock/NodeBasedLockManager.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/lock/NodeBasedLockManager.java 2008-06-26
22:59:25 UTC (rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/lock/NodeBasedLockManager.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -293,7 +293,7 @@
public String printLockInfo(NodeSPI node)
{
- StringBuffer sb = new StringBuffer("\n");
+ StringBuilder sb = new StringBuilder("\n");
int indent = 0;
for (Object n : node.getChildrenDirect())
Modified: core/trunk/src/main/java/org/jboss/cache/lock/NodeLock.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/lock/NodeLock.java 2008-06-26 22:59:25 UTC
(rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/lock/NodeLock.java 2008-06-26 23:08:29 UTC
(rev 6075)
@@ -124,6 +124,6 @@
Set<NodeLock> acquireAll(Object caller, long timeout, LockType lock_type,
boolean excludeInternalFqns) throws LockingException, TimeoutException,
InterruptedException;
- void printLockInfo(StringBuffer sb, int indent);
+ void printLockInfo(StringBuilder sb, int indent);
}
\ No newline at end of file
Modified:
core/trunk/src/main/java/org/jboss/cache/lock/PessimisticNodeBasedLockManager.java
===================================================================
---
core/trunk/src/main/java/org/jboss/cache/lock/PessimisticNodeBasedLockManager.java 2008-06-26
22:59:25 UTC (rev 6074)
+++
core/trunk/src/main/java/org/jboss/cache/lock/PessimisticNodeBasedLockManager.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -193,7 +193,7 @@
}
if (!fqn.isChildOrEquals(currentNode.getFqn())) // Does this ever happen?
Perhaps with a move(), I suppose? - MS
{
- String message = new StringBuffer("currentNode instance changed the
FQN(").append(currentNode.getFqn())
+ String message = new StringBuilder("currentNode instance changed the
FQN(").append(currentNode.getFqn())
.append(") and do not match the FQN on which we want to acquire
lock(").append(fqn).append(")").toString();
log.trace(message);
throw new LockingException(message);
Modified: core/trunk/src/main/java/org/jboss/cache/lock/ReadWriteLockWithUpgrade.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/lock/ReadWriteLockWithUpgrade.java 2008-06-26
22:59:25 UTC (rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/lock/ReadWriteLockWithUpgrade.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -70,7 +70,7 @@
@Override
public String toString()
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
sb.append("activeReaders=").append(activeReaders_).append(",
activeWriter=").append(activeWriter_);
sb.append(", waitingReaders=").append(waitingReaders_).append(",
waitingWriters=").append(waitingWriters_);
sb.append(", waitingUpgrader=").append(waitingUpgrader_);
Modified: core/trunk/src/main/java/org/jboss/cache/transaction/GlobalTransaction.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/transaction/GlobalTransaction.java 2008-06-26
22:59:25 UTC (rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/transaction/GlobalTransaction.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -102,7 +102,7 @@
@Override
public String toString()
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
sb.append("GlobalTransaction:<").append(addr).append(">:").append(id);
return sb.toString();
}
Modified:
core/trunk/src/main/java/org/jboss/cache/transaction/OptimisticTransactionContext.java
===================================================================
---
core/trunk/src/main/java/org/jboss/cache/transaction/OptimisticTransactionContext.java 2008-06-26
22:59:25 UTC (rev 6074)
+++
core/trunk/src/main/java/org/jboss/cache/transaction/OptimisticTransactionContext.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -33,7 +33,7 @@
@Override
public String toString()
{
- StringBuffer sb = new StringBuffer(super.toString());
+ StringBuilder sb = new StringBuilder(super.toString());
sb.append("\nworkspace: ").append(transactionWorkSpace);
return sb.toString();
}
Modified: core/trunk/src/main/java/org/jboss/cache/transaction/TransactionTable.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/transaction/TransactionTable.java 2008-06-26
22:59:25 UTC (rev 6074)
+++ core/trunk/src/main/java/org/jboss/cache/transaction/TransactionTable.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -195,7 +195,7 @@
@Override
public String toString()
{
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
sb.append(tx2gtxMap.size()).append(" mappings, ");
sb.append(gtx2ContextMap.size()).append(" transactions");
return sb.toString();
@@ -208,7 +208,7 @@
{
if (!printDetails)
return toString();
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
sb.append("LocalTransactions:
").append(tx2gtxMap.size()).append("\n");
sb.append("GlobalTransactions:
").append(gtx2ContextMap.size()).append("\n");
sb.append("tx2gtxMap:\n");
Modified: core/trunk/src/test/java/org/jboss/cache/loader/JDBCCacheLoaderDerbyDSTest.java
===================================================================
---
core/trunk/src/test/java/org/jboss/cache/loader/JDBCCacheLoaderDerbyDSTest.java 2008-06-26
22:59:25 UTC (rev 6074)
+++
core/trunk/src/test/java/org/jboss/cache/loader/JDBCCacheLoaderDerbyDSTest.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -92,7 +92,7 @@
{
String key = "LargeObj";
// create an object with size bigger than 4k (k=1024 bytes)
- StringBuffer text = new StringBuffer("LargeObject");
+ StringBuilder text = new StringBuilder("LargeObject");
while (text.toString().getBytes().length < (1024 * 100))
{
text.append(text);
Modified: core/trunk/src/test/java/org/jboss/cache/loader/JDBCCacheLoaderTest.java
===================================================================
--- core/trunk/src/test/java/org/jboss/cache/loader/JDBCCacheLoaderTest.java 2008-06-26
22:59:25 UTC (rev 6074)
+++ core/trunk/src/test/java/org/jboss/cache/loader/JDBCCacheLoaderTest.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -6,18 +6,12 @@
*/
package org.jboss.cache.loader;
-import static org.testng.AssertJUnit.assertEquals;
-import static org.testng.AssertJUnit.assertNull;
-import static org.testng.AssertJUnit.assertTrue;
-import static org.testng.AssertJUnit.fail;
+import org.jboss.cache.Fqn;
+import static org.testng.AssertJUnit.*;
import org.testng.annotations.Test;
-import org.testng.annotations.AfterMethod;
import java.util.Properties;
-import org.jboss.cache.Fqn;
-import org.jboss.cache.config.CacheLoaderConfig;
-
/**
* This test runs cache loader tests using Database as the cache loader store.
* The default test is configured using Derby embedded framework.
@@ -60,7 +54,7 @@
{
String key = "LargeObj";
// create an object with size bigger than 4k (k=1024 bytes)
- StringBuffer text = new StringBuffer("LargeObject");
+ StringBuilder text = new StringBuilder("LargeObject");
while (text.toString().getBytes().length < (1024 * 100))
{
text.append(text);
@@ -79,7 +73,8 @@
retVal = loader.put(FQN, key, updatedValue);
assertEquals(initialValue, (String) retVal);
assertEquals(updatedValue, (String) loader.get(FQN).get(key));
- } catch (Exception e)
+ }
+ catch (Exception e)
{
fail(e.toString());
}
@@ -99,9 +94,9 @@
}
}
- public void testRootIsCreated() throws Exception
- {
- loader.put(Fqn.fromString("/a/b/c"), "a", "b");
- assertTrue(loader.exists(Fqn.ROOT));
- }
+ public void testRootIsCreated() throws Exception
+ {
+ loader.put(Fqn.fromString("/a/b/c"), "a", "b");
+ assertTrue(loader.exists(Fqn.ROOT));
+ }
}
Modified: core/trunk/src/test/java/org/jboss/cache/lock/IdentityLockTest.java
===================================================================
--- core/trunk/src/test/java/org/jboss/cache/lock/IdentityLockTest.java 2008-06-26
22:59:25 UTC (rev 6074)
+++ core/trunk/src/test/java/org/jboss/cache/lock/IdentityLockTest.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -10,8 +10,8 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.jboss.cache.NodeSPI;
+import org.jboss.cache.transaction.GlobalTransaction;
import org.jboss.cache.util.TestingUtil;
-import org.jboss.cache.transaction.GlobalTransaction;
import static org.testng.AssertJUnit.*;
import org.testng.annotations.AfterMethod;
import org.testng.annotations.BeforeMethod;
@@ -567,7 +567,7 @@
}
try
{
- iLock.toString(new StringBuffer(), false);
+ iLock.toString(new StringBuilder(), false);
}
catch (Exception e)
{
Modified:
core/trunk/src/test/java/org/jboss/cache/statetransfer/StateTransferTestBase.java
===================================================================
---
core/trunk/src/test/java/org/jboss/cache/statetransfer/StateTransferTestBase.java 2008-06-26
22:59:25 UTC (rev 6074)
+++
core/trunk/src/test/java/org/jboss/cache/statetransfer/StateTransferTestBase.java 2008-06-26
23:08:29 UTC (rev 6075)
@@ -27,13 +27,13 @@
import org.jboss.cache.DefaultCacheFactory;
import org.jboss.cache.Fqn;
import org.jboss.cache.Region;
-import org.jboss.cache.util.TestingUtil;
import org.jboss.cache.config.Configuration;
import org.jboss.cache.config.Configuration.CacheMode;
import org.jboss.cache.factories.UnitTestCacheConfigurationFactory;
import org.jboss.cache.loader.AbstractCacheLoaderTestBase;
import org.jboss.cache.loader.CacheLoader;
import org.jboss.cache.marshall.SelectedClassnameClassLoader;
+import org.jboss.cache.util.TestingUtil;
import static org.testng.AssertJUnit.assertEquals;
import static org.testng.AssertJUnit.assertFalse;
import org.testng.annotations.AfterMethod;
@@ -307,7 +307,7 @@
}
char[] chars = path.toCharArray();
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
for (char aChar : chars)
{
if (aChar == '\\')
@@ -394,7 +394,7 @@
protected ClassLoader getClassLoader() throws Exception
{
String[] includesClasses = {"org.jboss.cache.marshall.Person",
- "org.jboss.cache.marshall.Address"};
+ "org.jboss.cache.marshall.Address"};
String[] excludesClasses = {};
ClassLoader cl = Thread.currentThread().getContextClassLoader();
return new SelectedClassnameClassLoader(includesClasses, excludesClasses, cl);
@@ -403,7 +403,7 @@
protected ClassLoader getNotFoundClassLoader() throws Exception
{
String[] notFoundClasses = {"org.jboss.cache.marshall.Person",
- "org.jboss.cache.marshall.Address"};
+ "org.jboss.cache.marshall.Address"};
ClassLoader cl = Thread.currentThread().getContextClassLoader();
return new SelectedClassnameClassLoader(null, null, notFoundClasses, cl);
}