Class TreeBidiMap.View

  • All Implemented Interfaces:
    java.lang.Iterable, java.util.Collection, java.util.Set
    Direct Known Subclasses:
    TreeBidiMap.EntryView
    Enclosing class:
    TreeBidiMap

    static class TreeBidiMap.View
    extends java.util.AbstractSet
    A view of this map.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected int dataType
      Whether to return KEY, VALUE, MAPENTRY or INVERSEMAPENTRY data.
      protected TreeBidiMap main
      The parent map.
      protected int orderType
      Whether to return KEY or VALUE order.
    • Constructor Summary

      Constructors 
      Constructor Description
      View​(TreeBidiMap main, int orderType, int dataType)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()  
      boolean contains​(java.lang.Object obj)  
      java.util.Iterator iterator()  
      boolean remove​(java.lang.Object obj)  
      int size()  
      • Methods inherited from class java.util.AbstractSet

        equals, hashCode, removeAll
      • Methods inherited from class java.util.AbstractCollection

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

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

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

        forEach
      • Methods inherited from interface java.util.Set

        add, addAll, containsAll, isEmpty, retainAll, spliterator, toArray, toArray
    • Field Detail

      • main

        protected final TreeBidiMap main
        The parent map.
      • orderType

        protected final int orderType
        Whether to return KEY or VALUE order.
      • dataType

        protected final int dataType
        Whether to return KEY, VALUE, MAPENTRY or INVERSEMAPENTRY data.
    • Constructor Detail

      • View

        View​(TreeBidiMap main,
             int orderType,
             int dataType)
        Constructor.
        Parameters:
        main - the main map
        orderType - the KEY or VALUE int for the order
        dataType - the KEY, VALUE, MAPENTRY or INVERSEMAPENTRY int
    • Method Detail

      • iterator

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

        public int size()
        Specified by:
        size in interface java.util.Collection
        Specified by:
        size in interface java.util.Set
        Specified by:
        size in class java.util.AbstractCollection
      • contains

        public boolean contains​(java.lang.Object obj)
        Specified by:
        contains in interface java.util.Collection
        Specified by:
        contains in interface java.util.Set
        Overrides:
        contains in class java.util.AbstractCollection
      • remove

        public boolean remove​(java.lang.Object obj)
        Specified by:
        remove in interface java.util.Collection
        Specified by:
        remove in interface java.util.Set
        Overrides:
        remove in class java.util.AbstractCollection
      • clear

        public void clear()
        Specified by:
        clear in interface java.util.Collection
        Specified by:
        clear in interface java.util.Set
        Overrides:
        clear in class java.util.AbstractCollection