Java Code Examples for java.util.concurrent.ConcurrentSkipListSet#toArray()
The following examples show how to use
java.util.concurrent.ConcurrentSkipListSet#toArray() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ConstantContainer.java From FuzzDroid with Apache License 2.0 | 5 votes |
public void convertSetsToArrays() { for (String clazz : tmpSetMap.keySet()) { ConcurrentSkipListSet<Object> constantSet = tmpSetMap.get(clazz); Object[] constantObjects = constantSet.toArray(new Object[constantSet.size()]); arrayMap.put(clazz, constantObjects); } allValues = allValuesSet.toArray(); }
Example 2
Source File: ConcurrentSkipListSetTest.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
/** * toArray contains all elements in sorted order */ public void testToArray() { ConcurrentSkipListSet q = populatedSet(SIZE); Object[] o = q.toArray(); for (int i = 0; i < o.length; i++) assertSame(o[i], q.pollFirst()); }
Example 3
Source File: ConcurrentSkipListSetTest.java From j2objc with Apache License 2.0 | 5 votes |
/** * toArray contains all elements in sorted order */ public void testToArray() { ConcurrentSkipListSet q = populatedSet(SIZE); Object[] o = q.toArray(); for (int i = 0; i < o.length; i++) assertSame(o[i], q.pollFirst()); }