Revision: 1058
          http://stripes.svn.sourceforge.net/stripes/?rev=1058&view=rev
Author:   bengunter
Date:     2009-02-26 14:45:11 +0000 (Thu, 26 Feb 2009)

Log Message:
-----------
STS-614. Not sure why I was creating a new ArrayList in the toArray(..) methods.

Modified Paths:
--------------
    trunk/stripes/src/net/sourceforge/stripes/util/ConcurrentHashSet.java

Modified: trunk/stripes/src/net/sourceforge/stripes/util/ConcurrentHashSet.java
===================================================================
--- trunk/stripes/src/net/sourceforge/stripes/util/ConcurrentHashSet.java       
2009-02-26 06:48:17 UTC (rev 1057)
+++ trunk/stripes/src/net/sourceforge/stripes/util/ConcurrentHashSet.java       
2009-02-26 14:45:11 UTC (rev 1058)
@@ -14,7 +14,6 @@
  */
 package net.sourceforge.stripes.util;
 
-import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Iterator;
 import java.util.Set;
@@ -133,10 +132,10 @@
     }
 
     public Object[] toArray() {
-        return new ArrayList<T>(map.keySet()).toArray();
+        return map.keySet().toArray();
     }
 
     public <E> E[] toArray(E[] a) {
-        return new ArrayList<T>(map.keySet()).toArray(a);
+        return map.keySet().toArray(a);
     }
 }


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Stripes-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-development

Reply via email to