Class Collections2.TransformedCollection<F,​T>

  • All Implemented Interfaces:
    java.lang.Iterable<T>, java.util.Collection<T>
    Enclosing class:
    Collections2

    static class Collections2.TransformedCollection<F,​T>
    extends java.util.AbstractCollection<T>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) java.util.Collection<F> fromCollection  
      (package private) Function<? super F,​? extends T> function  
    • Constructor Summary

      Constructors 
      Constructor Description
      TransformedCollection​(java.util.Collection<F> fromCollection, Function<? super F,​? extends T> function)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()  
      boolean isEmpty()  
      java.util.Iterator<T> iterator()  
      int size()  
      • Methods inherited from class java.util.AbstractCollection

        add, addAll, contains, containsAll, remove, removeAll, retainAll, toArray, toArray, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Collection

        equals, hashCode, parallelStream, removeIf, spliterator, stream, toArray
      • Methods inherited from interface java.lang.Iterable

        forEach
    • Field Detail

      • fromCollection

        final java.util.Collection<F> fromCollection
      • function

        final Function<? super F,​? extends T> function
    • Constructor Detail

      • TransformedCollection

        TransformedCollection​(java.util.Collection<F> fromCollection,
                              Function<? super F,​? extends T> function)
    • Method Detail

      • clear

        public void clear()
        Specified by:
        clear in interface java.util.Collection<F>
        Overrides:
        clear in class java.util.AbstractCollection<T>
      • isEmpty

        public boolean isEmpty()
        Specified by:
        isEmpty in interface java.util.Collection<F>
        Overrides:
        isEmpty in class java.util.AbstractCollection<T>
      • iterator

        public java.util.Iterator<T> iterator()
        Specified by:
        iterator in interface java.util.Collection<F>
        Specified by:
        iterator in interface java.lang.Iterable<F>
        Specified by:
        iterator in class java.util.AbstractCollection<T>
      • size

        public int size()
        Specified by:
        size in interface java.util.Collection<F>
        Specified by:
        size in class java.util.AbstractCollection<T>