Java Code Examples for com.google.common.collect.Synchronized.SynchronizedSet

The following are top voted examples for showing how to use com.google.common.collect.Synchronized.SynchronizedSet. These examples are extracted from open source projects. You can vote up the examples you like and your votes will be used in our system to generate more good examples.
Example 1
Project: guava   File: SynchronizedBiMapTest.java   View source code 5 votes vote down vote up
@Override
public void testValues() {
  BiMap<String, Integer> map = create();
  Set<Integer> values = map.values();
  assertTrue(values instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) values).mutex);
}
 
Example 2
Project: guava   File: SynchronizedBiMapTest.java   View source code 5 votes vote down vote up
@Override
public void testValues() {
  BiMap<String, Integer> map = create();
  Set<Integer> values = map.values();
  assertTrue(values instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) values).mutex);
}
 
Example 3
Project: guava-mock   File: SynchronizedBiMapTest.java   View source code 4 votes vote down vote up
@Override public void testValues() {
  BiMap<String, Integer> map = create();
  Set<Integer> values = map.values();
  assertTrue(values instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) values).mutex);
}
 
Example 4
Project: guava-mock   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testKeySet() {
  Map<String, Integer> map = create();
  Set<String> keySet = map.keySet();
  assertTrue(keySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) keySet).mutex);
}
 
Example 5
Project: guava-mock   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testEntrySet() {
  Map<String, Integer> map = create();
  Set<Map.Entry<String, Integer>> entrySet = map.entrySet();
  assertTrue(entrySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) entrySet).mutex);
}
 
Example 6
Project: googles-monorepo-demo   File: SynchronizedBiMapTest.java   View source code 4 votes vote down vote up
@Override public void testValues() {
  BiMap<String, Integer> map = create();
  Set<Integer> values = map.values();
  assertTrue(values instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) values).mutex);
}
 
Example 7
Project: googles-monorepo-demo   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testKeySet() {
  Map<String, Integer> map = create();
  Set<String> keySet = map.keySet();
  assertTrue(keySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) keySet).mutex);
}
 
Example 8
Project: googles-monorepo-demo   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testEntrySet() {
  Map<String, Integer> map = create();
  Set<Map.Entry<String, Integer>> entrySet = map.entrySet();
  assertTrue(entrySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) entrySet).mutex);
}
 
Example 9
Project: guava-libraries   File: SynchronizedBiMapTest.java   View source code 4 votes vote down vote up
@Override public void testValues() {
  BiMap<String, Integer> map = create();
  Set<Integer> values = map.values();
  assertTrue(values instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) values).mutex);
}
 
Example 10
Project: guava-libraries   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testKeySet() {
  Map<String, Integer> map = create();
  Set<String> keySet = map.keySet();
  assertTrue(keySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) keySet).mutex);
}
 
Example 11
Project: guava-libraries   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testEntrySet() {
  Map<String, Integer> map = create();
  Set<Map.Entry<String, Integer>> entrySet = map.entrySet();
  assertTrue(entrySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) entrySet).mutex);
}
 
Example 12
Project: guava   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testKeySet() {
  Map<String, Integer> map = create();
  Set<String> keySet = map.keySet();
  assertTrue(keySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) keySet).mutex);
}
 
Example 13
Project: guava   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testEntrySet() {
  Map<String, Integer> map = create();
  Set<Entry<String, Integer>> entrySet = map.entrySet();
  assertTrue(entrySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) entrySet).mutex);
}
 
Example 14
Project: guava   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testKeySet() {
  Map<String, Integer> map = create();
  Set<String> keySet = map.keySet();
  assertTrue(keySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) keySet).mutex);
}
 
Example 15
Project: guava   File: SynchronizedMapTest.java   View source code 4 votes vote down vote up
public void testEntrySet() {
  Map<String, Integer> map = create();
  Set<Entry<String, Integer>> entrySet = map.entrySet();
  assertTrue(entrySet instanceof SynchronizedSet);
  assertSame(mutex, ((SynchronizedSet<?>) entrySet).mutex);
}