Class GridBoundedConcurrentOrderedMap<K,​V>

    • Constructor Detail

      • GridBoundedConcurrentOrderedMap

        public GridBoundedConcurrentOrderedMap​(int max)
        Constructs a new, empty map that orders its elements according to their natural ordering.
        Parameters:
        max - Upper bound of this map.
      • GridBoundedConcurrentOrderedMap

        public GridBoundedConcurrentOrderedMap​(int max,
                                               Comparator<? super K> comparator)
        Constructs a new, empty set that orders its elements according to the specified comparator.
        Parameters:
        max - Upper bound of this map.
        comparator - The comparator that will be used to order this map. If null, the natural ordering of the elements will be used.
      • GridBoundedConcurrentOrderedMap

        public GridBoundedConcurrentOrderedMap​(int max,
                                               Map<? extends K,​? extends V> map)
        Constructs a new map containing the elements in the specified map, that orders its elements according to their natural ordering.
        Parameters:
        max - Upper bound of this map.
        map - The elements that will comprise the new map.
        Throws:
        ClassCastException - if the elements in map are not Comparable, or are not mutually comparable.
        NullPointerException - if the specified map or any of its elements are null.
      • GridBoundedConcurrentOrderedMap

        public GridBoundedConcurrentOrderedMap​(int max,
                                               SortedMap<K,​V> map)
        Constructs a new map containing the same elements and using the same ordering as the specified sorted map.
        Parameters:
        max - Upper bound of this map.
        map - Sorted map whose elements will comprise the new map.
        Throws:
        NullPointerException - if the specified sorted map or any of its elements are null.