@GwtIncompatible // NavigableSet @VisibleForTesting static class SynchronizedNavigableSet<E> extends SynchronizedSortedSet<E> implements NavigableSet<E> { SynchronizedNavigableSet(NavigableSet<E> delegate, @NullableDecl Object mutex) { super(delegate, mutex); } @Override NavigableSet<E> delegate() { return (NavigableSet<E>) super.delegate(); } @Override public E ceiling(E e) { synchronized (mutex) { return delegate().ceiling(e); } } @Override public Iterator<E> descendingIterator() { return delegate().descendingIterator(); // manually synchronized } @MonotonicNonNullDecl transient NavigableSet<E> descendingSet; @Override public NavigableSet<E> descendingSet() { synchronized (mutex) {
@GwtIncompatible("NavigableSet") static <E> NavigableSet<E> navigableSet( NavigableSet<E> navigableSet, @Nullable Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible("NavigableSet") static <E> NavigableSet<E> navigableSet( NavigableSet<E> navigableSet, @Nullable Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible // NavigableSet static <E> NavigableSet<E> navigableSet(NavigableSet<E> navigableSet, @Nullable Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible("NavigableSet") static <E> NavigableSet<E> navigableSet(NavigableSet<E> navigableSet, @Nullable Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible("NavigableSet") static <E> NavigableSet<E> navigableSet( NavigableSet<E> navigableSet, @Nullable Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible // NavigableSet static <E> NavigableSet<E> navigableSet( NavigableSet<E> navigableSet, @NullableDecl Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible("NavigableSet") static <E> NavigableSet<E> navigableSet( NavigableSet<E> navigableSet, @Nullable Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible("NavigableSet") static <E> NavigableSet<E> navigableSet( NavigableSet<E> navigableSet, @Nullable Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible("NavigableSet") static <E> NavigableSet<E> navigableSet( NavigableSet<E> navigableSet, @Nullable Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible // NavigableSet static <E> NavigableSet<E> navigableSet( NavigableSet<E> navigableSet, @NullableDecl Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }
@GwtIncompatible // NavigableSet static <E> NavigableSet<E> navigableSet(NavigableSet<E> navigableSet, @Nullable Object mutex) { return new SynchronizedNavigableSet<E>(navigableSet, mutex); }