Class Sets.UnmodifiableNavigableSet<E>

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Iterable<E>, java.util.Collection<E>, java.util.NavigableSet<E>, java.util.Set<E>, java.util.SortedSet<E>
    Enclosing class:
    Sets

    static final class Sets.UnmodifiableNavigableSet<E>
    extends ForwardingSortedSet<E>
    implements java.util.NavigableSet<E>, java.io.Serializable
    • Field Detail

      • delegate

        private final java.util.NavigableSet<E> delegate
      • unmodifiableDelegate

        private final java.util.SortedSet<E> unmodifiableDelegate
    • Constructor Detail

      • UnmodifiableNavigableSet

        UnmodifiableNavigableSet​(java.util.NavigableSet<E> delegate)
    • Method Detail

      • delegate

        protected java.util.SortedSet<E> delegate()
        Description copied from class: ForwardingObject
        Returns the backing delegate instance that methods are forwarded to. Abstract subclasses generally override this method with an abstract method that has a more specific return type, such as ForwardingSet.delegate(). Concrete subclasses override this method to supply the instance being decorated.
        Specified by:
        delegate in class ForwardingSortedSet<E>
      • removeIf

        public boolean removeIf​(java.util.function.Predicate<? super E> filter)
        Specified by:
        removeIf in interface java.util.Collection<E>
      • stream

        public java.util.stream.Stream<E> stream()
        Specified by:
        stream in interface java.util.Collection<E>
      • parallelStream

        public java.util.stream.Stream<E> parallelStream()
        Specified by:
        parallelStream in interface java.util.Collection<E>
      • forEach

        public void forEach​(java.util.function.Consumer<? super E> action)
        Specified by:
        forEach in interface java.lang.Iterable<E>
      • lower

        @CheckForNull
        public E lower​(E e)
        Specified by:
        lower in interface java.util.NavigableSet<E>
      • floor

        @CheckForNull
        public E floor​(E e)
        Specified by:
        floor in interface java.util.NavigableSet<E>
      • ceiling

        @CheckForNull
        public E ceiling​(E e)
        Specified by:
        ceiling in interface java.util.NavigableSet<E>
      • higher

        @CheckForNull
        public E higher​(E e)
        Specified by:
        higher in interface java.util.NavigableSet<E>
      • pollFirst

        @CheckForNull
        public E pollFirst()
        Specified by:
        pollFirst in interface java.util.NavigableSet<E>
      • pollLast

        @CheckForNull
        public E pollLast()
        Specified by:
        pollLast in interface java.util.NavigableSet<E>
      • descendingSet

        public java.util.NavigableSet<E> descendingSet()
        Specified by:
        descendingSet in interface java.util.NavigableSet<E>
      • descendingIterator

        public java.util.Iterator<E> descendingIterator()
        Specified by:
        descendingIterator in interface java.util.NavigableSet<E>
      • subSet

        public java.util.NavigableSet<E> subSet​(E fromElement,
                                                boolean fromInclusive,
                                                E toElement,
                                                boolean toInclusive)
        Specified by:
        subSet in interface java.util.NavigableSet<E>
      • headSet

        public java.util.NavigableSet<E> headSet​(E toElement,
                                                 boolean inclusive)
        Specified by:
        headSet in interface java.util.NavigableSet<E>
      • tailSet

        public java.util.NavigableSet<E> tailSet​(E fromElement,
                                                 boolean inclusive)
        Specified by:
        tailSet in interface java.util.NavigableSet<E>