Code example for NavigableSet

Methods: pollFirst

0
  } 
 
  @CollectionFeature.Require(SUPPORTS_REMOVE) 
  @CollectionSize.Require(SEVERAL) 
  public void testPollFirst() { 
    assertEquals(a, navigableSet.pollFirst());
    assertEquals( 
        values.subList(1, values.size()), Helpers.copyToList(navigableSet));
  } 
 
  @CollectionFeature.Require(absent = SUPPORTS_REMOVE) 
  public void testPollFirstUnsupported() { 
    try { 
      navigableSet.pollFirst();
      fail(); 
    } catch (UnsupportedOperationException e) {
    } 
  } 
 
  @CollectionSize.Require(SEVERAL) 
Contextual code suggestions in your IDE  Get Codota for Java