Package gnu.trove

Class TCollections


  • public class TCollections
    extends java.lang.Object
    Trove equivalent of the Collections class.
    • Method Detail

      • unmodifiableCollection

        public static TDoubleCollection unmodifiableCollection​(TDoubleCollection c)
        Returns an unmodifiable view of the specified Trove primitive collection. This method allows modules to provide users with "read-only" access to internal collections. Query operations on the returned collection "read through" to the specified collection, and attempts to modify the returned collection, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive collection.
      • unmodifiableCollection

        public static TFloatCollection unmodifiableCollection​(TFloatCollection c)
        Returns an unmodifiable view of the specified Trove primitive collection. This method allows modules to provide users with "read-only" access to internal collections. Query operations on the returned collection "read through" to the specified collection, and attempts to modify the returned collection, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive collection.
      • unmodifiableCollection

        public static TIntCollection unmodifiableCollection​(TIntCollection c)
        Returns an unmodifiable view of the specified Trove primitive collection. This method allows modules to provide users with "read-only" access to internal collections. Query operations on the returned collection "read through" to the specified collection, and attempts to modify the returned collection, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive collection.
      • unmodifiableCollection

        public static TLongCollection unmodifiableCollection​(TLongCollection c)
        Returns an unmodifiable view of the specified Trove primitive collection. This method allows modules to provide users with "read-only" access to internal collections. Query operations on the returned collection "read through" to the specified collection, and attempts to modify the returned collection, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive collection.
      • unmodifiableCollection

        public static TByteCollection unmodifiableCollection​(TByteCollection c)
        Returns an unmodifiable view of the specified Trove primitive collection. This method allows modules to provide users with "read-only" access to internal collections. Query operations on the returned collection "read through" to the specified collection, and attempts to modify the returned collection, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive collection.
      • unmodifiableCollection

        public static TShortCollection unmodifiableCollection​(TShortCollection c)
        Returns an unmodifiable view of the specified Trove primitive collection. This method allows modules to provide users with "read-only" access to internal collections. Query operations on the returned collection "read through" to the specified collection, and attempts to modify the returned collection, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive collection.
      • unmodifiableCollection

        public static TCharCollection unmodifiableCollection​(TCharCollection c)
        Returns an unmodifiable view of the specified Trove primitive collection. This method allows modules to provide users with "read-only" access to internal collections. Query operations on the returned collection "read through" to the specified collection, and attempts to modify the returned collection, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive collection.
      • unmodifiableSet

        public static TDoubleSet unmodifiableSet​(TDoubleSet s)
        Returns an unmodifiable view of the specified Trove primitive set. This method allows modules to provide users with "read-only" access to internal sets. Query operations on the returned set "read through" to the specified set, and attempts to modify the returned set, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive set.
      • unmodifiableSet

        public static TFloatSet unmodifiableSet​(TFloatSet s)
        Returns an unmodifiable view of the specified Trove primitive set. This method allows modules to provide users with "read-only" access to internal sets. Query operations on the returned set "read through" to the specified set, and attempts to modify the returned set, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive set.
      • unmodifiableSet

        public static TIntSet unmodifiableSet​(TIntSet s)
        Returns an unmodifiable view of the specified Trove primitive set. This method allows modules to provide users with "read-only" access to internal sets. Query operations on the returned set "read through" to the specified set, and attempts to modify the returned set, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive set.
      • unmodifiableSet

        public static TLongSet unmodifiableSet​(TLongSet s)
        Returns an unmodifiable view of the specified Trove primitive set. This method allows modules to provide users with "read-only" access to internal sets. Query operations on the returned set "read through" to the specified set, and attempts to modify the returned set, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive set.
      • unmodifiableSet

        public static TByteSet unmodifiableSet​(TByteSet s)
        Returns an unmodifiable view of the specified Trove primitive set. This method allows modules to provide users with "read-only" access to internal sets. Query operations on the returned set "read through" to the specified set, and attempts to modify the returned set, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive set.
      • unmodifiableSet

        public static TShortSet unmodifiableSet​(TShortSet s)
        Returns an unmodifiable view of the specified Trove primitive set. This method allows modules to provide users with "read-only" access to internal sets. Query operations on the returned set "read through" to the specified set, and attempts to modify the returned set, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive set.
      • unmodifiableSet

        public static TCharSet unmodifiableSet​(TCharSet s)
        Returns an unmodifiable view of the specified Trove primitive set. This method allows modules to provide users with "read-only" access to internal sets. Query operations on the returned set "read through" to the specified set, and attempts to modify the returned set, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive set.
      • unmodifiableList

        public static TDoubleList unmodifiableList​(TDoubleList list)
        Returns an unmodifiable view of the specified Trove primitive list. This method allows modules to provide users with "read-only" access to internal lists. Query operations on the returned list "read through" to the specified list, and attempts to modify the returned list, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned list will be serializable if the specified list is serializable. Similarly, the returned list will implement RandomAccess if the specified list does.

        Parameters:
        list - the list for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive list.
      • unmodifiableList

        public static TFloatList unmodifiableList​(TFloatList list)
        Returns an unmodifiable view of the specified Trove primitive list. This method allows modules to provide users with "read-only" access to internal lists. Query operations on the returned list "read through" to the specified list, and attempts to modify the returned list, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned list will be serializable if the specified list is serializable. Similarly, the returned list will implement RandomAccess if the specified list does.

        Parameters:
        list - the list for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive list.
      • unmodifiableList

        public static TIntList unmodifiableList​(TIntList list)
        Returns an unmodifiable view of the specified Trove primitive list. This method allows modules to provide users with "read-only" access to internal lists. Query operations on the returned list "read through" to the specified list, and attempts to modify the returned list, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned list will be serializable if the specified list is serializable. Similarly, the returned list will implement RandomAccess if the specified list does.

        Parameters:
        list - the list for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive list.
      • unmodifiableList

        public static TLongList unmodifiableList​(TLongList list)
        Returns an unmodifiable view of the specified Trove primitive list. This method allows modules to provide users with "read-only" access to internal lists. Query operations on the returned list "read through" to the specified list, and attempts to modify the returned list, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned list will be serializable if the specified list is serializable. Similarly, the returned list will implement RandomAccess if the specified list does.

        Parameters:
        list - the list for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive list.
      • unmodifiableList

        public static TByteList unmodifiableList​(TByteList list)
        Returns an unmodifiable view of the specified Trove primitive list. This method allows modules to provide users with "read-only" access to internal lists. Query operations on the returned list "read through" to the specified list, and attempts to modify the returned list, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned list will be serializable if the specified list is serializable. Similarly, the returned list will implement RandomAccess if the specified list does.

        Parameters:
        list - the list for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive list.
      • unmodifiableList

        public static TShortList unmodifiableList​(TShortList list)
        Returns an unmodifiable view of the specified Trove primitive list. This method allows modules to provide users with "read-only" access to internal lists. Query operations on the returned list "read through" to the specified list, and attempts to modify the returned list, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned list will be serializable if the specified list is serializable. Similarly, the returned list will implement RandomAccess if the specified list does.

        Parameters:
        list - the list for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive list.
      • unmodifiableList

        public static TCharList unmodifiableList​(TCharList list)
        Returns an unmodifiable view of the specified Trove primitive list. This method allows modules to provide users with "read-only" access to internal lists. Query operations on the returned list "read through" to the specified list, and attempts to modify the returned list, whether direct or via its iterator, result in an UnsupportedOperationException.

        The returned list will be serializable if the specified list is serializable. Similarly, the returned list will implement RandomAccess if the specified list does.

        Parameters:
        list - the list for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive list.
      • unmodifiableMap

        public static TDoubleDoubleMap unmodifiableMap​(TDoubleDoubleMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TDoubleFloatMap unmodifiableMap​(TDoubleFloatMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TDoubleIntMap unmodifiableMap​(TDoubleIntMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TDoubleLongMap unmodifiableMap​(TDoubleLongMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TDoubleByteMap unmodifiableMap​(TDoubleByteMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TDoubleShortMap unmodifiableMap​(TDoubleShortMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TDoubleCharMap unmodifiableMap​(TDoubleCharMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TFloatDoubleMap unmodifiableMap​(TFloatDoubleMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TFloatFloatMap unmodifiableMap​(TFloatFloatMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TFloatIntMap unmodifiableMap​(TFloatIntMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TFloatLongMap unmodifiableMap​(TFloatLongMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TFloatByteMap unmodifiableMap​(TFloatByteMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TFloatShortMap unmodifiableMap​(TFloatShortMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TFloatCharMap unmodifiableMap​(TFloatCharMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TIntDoubleMap unmodifiableMap​(TIntDoubleMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TIntFloatMap unmodifiableMap​(TIntFloatMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TIntIntMap unmodifiableMap​(TIntIntMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TIntLongMap unmodifiableMap​(TIntLongMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TIntByteMap unmodifiableMap​(TIntByteMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TIntShortMap unmodifiableMap​(TIntShortMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TIntCharMap unmodifiableMap​(TIntCharMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TLongDoubleMap unmodifiableMap​(TLongDoubleMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TLongFloatMap unmodifiableMap​(TLongFloatMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TLongIntMap unmodifiableMap​(TLongIntMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TLongLongMap unmodifiableMap​(TLongLongMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TLongByteMap unmodifiableMap​(TLongByteMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TLongShortMap unmodifiableMap​(TLongShortMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TLongCharMap unmodifiableMap​(TLongCharMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TByteDoubleMap unmodifiableMap​(TByteDoubleMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TByteFloatMap unmodifiableMap​(TByteFloatMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TByteIntMap unmodifiableMap​(TByteIntMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TByteLongMap unmodifiableMap​(TByteLongMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TByteByteMap unmodifiableMap​(TByteByteMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TByteShortMap unmodifiableMap​(TByteShortMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TByteCharMap unmodifiableMap​(TByteCharMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TShortDoubleMap unmodifiableMap​(TShortDoubleMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TShortFloatMap unmodifiableMap​(TShortFloatMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TShortIntMap unmodifiableMap​(TShortIntMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TShortLongMap unmodifiableMap​(TShortLongMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TShortByteMap unmodifiableMap​(TShortByteMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TShortShortMap unmodifiableMap​(TShortShortMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TShortCharMap unmodifiableMap​(TShortCharMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TCharDoubleMap unmodifiableMap​(TCharDoubleMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TCharFloatMap unmodifiableMap​(TCharFloatMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TCharIntMap unmodifiableMap​(TCharIntMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TCharLongMap unmodifiableMap​(TCharLongMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TCharByteMap unmodifiableMap​(TCharByteMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TCharShortMap unmodifiableMap​(TCharShortMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static TCharCharMap unmodifiableMap​(TCharCharMap m)
        Returns an unmodifiable view of the specified Trove primitive/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <V> TDoubleObjectMap<V> unmodifiableMap​(TDoubleObjectMap<V> m)
        Returns an unmodifiable view of the specified Trove primitive/Object map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <V> TFloatObjectMap<V> unmodifiableMap​(TFloatObjectMap<V> m)
        Returns an unmodifiable view of the specified Trove primitive/Object map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <V> TIntObjectMap<V> unmodifiableMap​(TIntObjectMap<V> m)
        Returns an unmodifiable view of the specified Trove primitive/Object map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <V> TLongObjectMap<V> unmodifiableMap​(TLongObjectMap<V> m)
        Returns an unmodifiable view of the specified Trove primitive/Object map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <V> TByteObjectMap<V> unmodifiableMap​(TByteObjectMap<V> m)
        Returns an unmodifiable view of the specified Trove primitive/Object map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <V> TShortObjectMap<V> unmodifiableMap​(TShortObjectMap<V> m)
        Returns an unmodifiable view of the specified Trove primitive/Object map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <V> TCharObjectMap<V> unmodifiableMap​(TCharObjectMap<V> m)
        Returns an unmodifiable view of the specified Trove primitive/Object map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <K> TObjectDoubleMap<K> unmodifiableMap​(TObjectDoubleMap<K> m)
        Returns an unmodifiable view of the specified Trove Object/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <K> TObjectFloatMap<K> unmodifiableMap​(TObjectFloatMap<K> m)
        Returns an unmodifiable view of the specified Trove Object/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <K> TObjectIntMap<K> unmodifiableMap​(TObjectIntMap<K> m)
        Returns an unmodifiable view of the specified Trove Object/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <K> TObjectLongMap<K> unmodifiableMap​(TObjectLongMap<K> m)
        Returns an unmodifiable view of the specified Trove Object/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <K> TObjectByteMap<K> unmodifiableMap​(TObjectByteMap<K> m)
        Returns an unmodifiable view of the specified Trove Object/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <K> TObjectShortMap<K> unmodifiableMap​(TObjectShortMap<K> m)
        Returns an unmodifiable view of the specified Trove Object/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • unmodifiableMap

        public static <K> TObjectCharMap<K> unmodifiableMap​(TObjectCharMap<K> m)
        Returns an unmodifiable view of the specified Trove Object/primitive map. This method allows modules to provide users with "read-only" access to internal maps. Query operations on the returned map "read through" to the specified map, and attempts to modify the returned map, whether direct or via its collection views, result in an UnsupportedOperationException.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map for which an unmodifiable view is to be returned.
        Returns:
        an unmodifiable view of the specified Trove primitive/primitive map.
      • synchronizedCollection

        public static TDoubleCollection synchronizedCollection​(TDoubleCollection c)
        Returns a synchronized (thread-safe) Trove collection backed by the specified Trove collection. In order to guarantee serial access, it is critical that all access to the backing collection is accomplished through the returned collection.

        It is imperative that the user manually synchronize on the returned collection when iterating over it:

          TDoubleCollection c = TCollections.synchronizedCollection( myCollection );
             ...
          synchronized( c ) {
              TDoubleIterator i = c.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                 foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection to be "wrapped" in a synchronized collection.
        Returns:
        a synchronized view of the specified collection.
      • synchronizedCollection

        public static TFloatCollection synchronizedCollection​(TFloatCollection c)
        Returns a synchronized (thread-safe) Trove collection backed by the specified Trove collection. In order to guarantee serial access, it is critical that all access to the backing collection is accomplished through the returned collection.

        It is imperative that the user manually synchronize on the returned collection when iterating over it:

          TFloatCollection c = TCollections.synchronizedCollection( myCollection );
             ...
          synchronized( c ) {
              TFloatIterator i = c.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                 foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection to be "wrapped" in a synchronized collection.
        Returns:
        a synchronized view of the specified collection.
      • synchronizedCollection

        public static TIntCollection synchronizedCollection​(TIntCollection c)
        Returns a synchronized (thread-safe) Trove collection backed by the specified Trove collection. In order to guarantee serial access, it is critical that all access to the backing collection is accomplished through the returned collection.

        It is imperative that the user manually synchronize on the returned collection when iterating over it:

          TIntCollection c = TCollections.synchronizedCollection( myCollection );
             ...
          synchronized( c ) {
              TIntIterator i = c.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                 foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection to be "wrapped" in a synchronized collection.
        Returns:
        a synchronized view of the specified collection.
      • synchronizedCollection

        public static TLongCollection synchronizedCollection​(TLongCollection c)
        Returns a synchronized (thread-safe) Trove collection backed by the specified Trove collection. In order to guarantee serial access, it is critical that all access to the backing collection is accomplished through the returned collection.

        It is imperative that the user manually synchronize on the returned collection when iterating over it:

          TLongCollection c = TCollections.synchronizedCollection( myCollection );
             ...
          synchronized( c ) {
              TLongIterator i = c.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                 foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection to be "wrapped" in a synchronized collection.
        Returns:
        a synchronized view of the specified collection.
      • synchronizedCollection

        public static TByteCollection synchronizedCollection​(TByteCollection c)
        Returns a synchronized (thread-safe) Trove collection backed by the specified Trove collection. In order to guarantee serial access, it is critical that all access to the backing collection is accomplished through the returned collection.

        It is imperative that the user manually synchronize on the returned collection when iterating over it:

          TByteCollection c = TCollections.synchronizedCollection( myCollection );
             ...
          synchronized( c ) {
              TByteIterator i = c.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                 foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection to be "wrapped" in a synchronized collection.
        Returns:
        a synchronized view of the specified collection.
      • synchronizedCollection

        public static TShortCollection synchronizedCollection​(TShortCollection c)
        Returns a synchronized (thread-safe) Trove collection backed by the specified Trove collection. In order to guarantee serial access, it is critical that all access to the backing collection is accomplished through the returned collection.

        It is imperative that the user manually synchronize on the returned collection when iterating over it:

          TShortCollection c = TCollections.synchronizedCollection( myCollection );
             ...
          synchronized( c ) {
              TShortIterator i = c.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                 foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection to be "wrapped" in a synchronized collection.
        Returns:
        a synchronized view of the specified collection.
      • synchronizedCollection

        public static TCharCollection synchronizedCollection​(TCharCollection c)
        Returns a synchronized (thread-safe) Trove collection backed by the specified Trove collection. In order to guarantee serial access, it is critical that all access to the backing collection is accomplished through the returned collection.

        It is imperative that the user manually synchronize on the returned collection when iterating over it:

          TCharCollection c = TCollections.synchronizedCollection( myCollection );
             ...
          synchronized( c ) {
              TCharIterator i = c.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                 foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned collection does not pass the hashCode and equals operations through to the backing collection, but relies on Object's equals and hashCode methods. This is necessary to preserve the contracts of these operations in the case that the backing collection is a set or a list.

        The returned collection will be serializable if the specified collection is serializable.

        Parameters:
        c - the collection to be "wrapped" in a synchronized collection.
        Returns:
        a synchronized view of the specified collection.
      • synchronizedSet

        public static TDoubleSet synchronizedSet​(TDoubleSet s)
        Returns a synchronized (thread-safe) Trove set backed by the specified set. In order to guarantee serial access, it is critical that all access to the backing set is accomplished through the returned set.

        It is imperative that the user manually synchronize on the returned set when iterating over it:

          TDoubleSet s = TCollections.synchronizedSet( new TDoubleHashSet() );
              ...
          synchronized(s) {
              TDoubleIterator i = s.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set to be "wrapped" in a synchronized set.
        Returns:
        a synchronized view of the specified set.
      • synchronizedSet

        public static TFloatSet synchronizedSet​(TFloatSet s)
        Returns a synchronized (thread-safe) Trove set backed by the specified set. In order to guarantee serial access, it is critical that all access to the backing set is accomplished through the returned set.

        It is imperative that the user manually synchronize on the returned set when iterating over it:

          TFloatSet s = TCollections.synchronizedSet( new TFloatHashSet() );
              ...
          synchronized(s) {
              TFloatIterator i = s.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set to be "wrapped" in a synchronized set.
        Returns:
        a synchronized view of the specified set.
      • synchronizedSet

        public static TIntSet synchronizedSet​(TIntSet s)
        Returns a synchronized (thread-safe) Trove set backed by the specified set. In order to guarantee serial access, it is critical that all access to the backing set is accomplished through the returned set.

        It is imperative that the user manually synchronize on the returned set when iterating over it:

          TIntSet s = TCollections.synchronizedSet( new TIntHashSet() );
              ...
          synchronized(s) {
              TIntIterator i = s.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set to be "wrapped" in a synchronized set.
        Returns:
        a synchronized view of the specified set.
      • synchronizedSet

        public static TLongSet synchronizedSet​(TLongSet s)
        Returns a synchronized (thread-safe) Trove set backed by the specified set. In order to guarantee serial access, it is critical that all access to the backing set is accomplished through the returned set.

        It is imperative that the user manually synchronize on the returned set when iterating over it:

          TLongSet s = TCollections.synchronizedSet( new TLongHashSet() );
              ...
          synchronized(s) {
              TLongIterator i = s.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set to be "wrapped" in a synchronized set.
        Returns:
        a synchronized view of the specified set.
      • synchronizedSet

        public static TByteSet synchronizedSet​(TByteSet s)
        Returns a synchronized (thread-safe) Trove set backed by the specified set. In order to guarantee serial access, it is critical that all access to the backing set is accomplished through the returned set.

        It is imperative that the user manually synchronize on the returned set when iterating over it:

          TByteSet s = TCollections.synchronizedSet( new TByteHashSet() );
              ...
          synchronized(s) {
              TByteIterator i = s.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set to be "wrapped" in a synchronized set.
        Returns:
        a synchronized view of the specified set.
      • synchronizedSet

        public static TShortSet synchronizedSet​(TShortSet s)
        Returns a synchronized (thread-safe) Trove set backed by the specified set. In order to guarantee serial access, it is critical that all access to the backing set is accomplished through the returned set.

        It is imperative that the user manually synchronize on the returned set when iterating over it:

          TShortSet s = TCollections.synchronizedSet( new TShortHashSet() );
              ...
          synchronized(s) {
              TShortIterator i = s.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set to be "wrapped" in a synchronized set.
        Returns:
        a synchronized view of the specified set.
      • synchronizedSet

        public static TCharSet synchronizedSet​(TCharSet s)
        Returns a synchronized (thread-safe) Trove set backed by the specified set. In order to guarantee serial access, it is critical that all access to the backing set is accomplished through the returned set.

        It is imperative that the user manually synchronize on the returned set when iterating over it:

          TCharSet s = TCollections.synchronizedSet( new TCharHashSet() );
              ...
          synchronized(s) {
              TCharIterator i = s.iterator(); // Must be in the synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned set will be serializable if the specified set is serializable.

        Parameters:
        s - the set to be "wrapped" in a synchronized set.
        Returns:
        a synchronized view of the specified set.
      • synchronizedList

        public static TDoubleList synchronizedList​(TDoubleList list)
        Returns a synchronized (thread-safe) Trove list backed by the specified list. In order to guarantee serial access, it is critical that all access to the backing list is accomplished through the returned list.

        It is imperative that the user manually synchronize on the returned list when iterating over it:

          TDoubleList list = TCollections.synchronizedList( new TDoubleArrayList() );
              ...
          synchronized( list ) {
              TDoubleIterator i = list.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned list will be serializable if the specified list is serializable.

        Parameters:
        list - the list to be "wrapped" in a synchronized list.
        Returns:
        a synchronized view of the specified list.
      • synchronizedList

        public static TFloatList synchronizedList​(TFloatList list)
        Returns a synchronized (thread-safe) Trove list backed by the specified list. In order to guarantee serial access, it is critical that all access to the backing list is accomplished through the returned list.

        It is imperative that the user manually synchronize on the returned list when iterating over it:

          TFloatList list = TCollections.synchronizedList( new TFloatArrayList() );
              ...
          synchronized( list ) {
              TFloatIterator i = list.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned list will be serializable if the specified list is serializable.

        Parameters:
        list - the list to be "wrapped" in a synchronized list.
        Returns:
        a synchronized view of the specified list.
      • synchronizedList

        public static TIntList synchronizedList​(TIntList list)
        Returns a synchronized (thread-safe) Trove list backed by the specified list. In order to guarantee serial access, it is critical that all access to the backing list is accomplished through the returned list.

        It is imperative that the user manually synchronize on the returned list when iterating over it:

          TIntList list = TCollections.synchronizedList( new TIntArrayList() );
              ...
          synchronized( list ) {
              TIntIterator i = list.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned list will be serializable if the specified list is serializable.

        Parameters:
        list - the list to be "wrapped" in a synchronized list.
        Returns:
        a synchronized view of the specified list.
      • synchronizedList

        public static TLongList synchronizedList​(TLongList list)
        Returns a synchronized (thread-safe) Trove list backed by the specified list. In order to guarantee serial access, it is critical that all access to the backing list is accomplished through the returned list.

        It is imperative that the user manually synchronize on the returned list when iterating over it:

          TLongList list = TCollections.synchronizedList( new TLongArrayList() );
              ...
          synchronized( list ) {
              TLongIterator i = list.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned list will be serializable if the specified list is serializable.

        Parameters:
        list - the list to be "wrapped" in a synchronized list.
        Returns:
        a synchronized view of the specified list.
      • synchronizedList

        public static TByteList synchronizedList​(TByteList list)
        Returns a synchronized (thread-safe) Trove list backed by the specified list. In order to guarantee serial access, it is critical that all access to the backing list is accomplished through the returned list.

        It is imperative that the user manually synchronize on the returned list when iterating over it:

          TByteList list = TCollections.synchronizedList( new TByteArrayList() );
              ...
          synchronized( list ) {
              TByteIterator i = list.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned list will be serializable if the specified list is serializable.

        Parameters:
        list - the list to be "wrapped" in a synchronized list.
        Returns:
        a synchronized view of the specified list.
      • synchronizedList

        public static TShortList synchronizedList​(TShortList list)
        Returns a synchronized (thread-safe) Trove list backed by the specified list. In order to guarantee serial access, it is critical that all access to the backing list is accomplished through the returned list.

        It is imperative that the user manually synchronize on the returned list when iterating over it:

          TShortList list = TCollections.synchronizedList( new TShortArrayList() );
              ...
          synchronized( list ) {
              TShortIterator i = list.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned list will be serializable if the specified list is serializable.

        Parameters:
        list - the list to be "wrapped" in a synchronized list.
        Returns:
        a synchronized view of the specified list.
      • synchronizedList

        public static TCharList synchronizedList​(TCharList list)
        Returns a synchronized (thread-safe) Trove list backed by the specified list. In order to guarantee serial access, it is critical that all access to the backing list is accomplished through the returned list.

        It is imperative that the user manually synchronize on the returned list when iterating over it:

          TCharList list = TCollections.synchronizedList( new TCharArrayList() );
              ...
          synchronized( list ) {
              TCharIterator i = list.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned list will be serializable if the specified list is serializable.

        Parameters:
        list - the list to be "wrapped" in a synchronized list.
        Returns:
        a synchronized view of the specified list.
      • synchronizedMap

        public static TDoubleDoubleMap synchronizedMap​(TDoubleDoubleMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TDoubleDoubleMap m = TCollections.synchronizedMap( new TDoubleDoubleHashMap() );
              ...
          TDoubleSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TDoubleIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TDoubleFloatMap synchronizedMap​(TDoubleFloatMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TDoubleFloatMap m = TCollections.synchronizedMap( new TDoubleFloatHashMap() );
              ...
          TDoubleSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TDoubleIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TDoubleIntMap synchronizedMap​(TDoubleIntMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TDoubleIntMap m = TCollections.synchronizedMap( new TDoubleIntHashMap() );
              ...
          TDoubleSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TDoubleIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TDoubleLongMap synchronizedMap​(TDoubleLongMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TDoubleLongMap m = TCollections.synchronizedMap( new TDoubleLongHashMap() );
              ...
          TDoubleSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TDoubleIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TDoubleByteMap synchronizedMap​(TDoubleByteMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TDoubleByteMap m = TCollections.synchronizedMap( new TDoubleByteHashMap() );
              ...
          TDoubleSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TDoubleIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TDoubleShortMap synchronizedMap​(TDoubleShortMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TDoubleShortMap m = TCollections.synchronizedMap( new TDoubleShortHashMap() );
              ...
          TDoubleSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TDoubleIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TDoubleCharMap synchronizedMap​(TDoubleCharMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TDoubleCharMap m = TCollections.synchronizedMap( new TDoubleCharHashMap() );
              ...
          TDoubleSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TDoubleIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TFloatDoubleMap synchronizedMap​(TFloatDoubleMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TFloatDoubleMap m = TCollections.synchronizedMap( new TFloatDoubleHashMap() );
              ...
          TFloatSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TFloatIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TFloatFloatMap synchronizedMap​(TFloatFloatMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TFloatFloatMap m = TCollections.synchronizedMap( new TFloatFloatHashMap() );
              ...
          TFloatSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TFloatIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TFloatIntMap synchronizedMap​(TFloatIntMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TFloatIntMap m = TCollections.synchronizedMap( new TFloatIntHashMap() );
              ...
          TFloatSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TFloatIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TFloatLongMap synchronizedMap​(TFloatLongMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TFloatLongMap m = TCollections.synchronizedMap( new TFloatLongHashMap() );
              ...
          TFloatSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TFloatIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TFloatByteMap synchronizedMap​(TFloatByteMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TFloatByteMap m = TCollections.synchronizedMap( new TFloatByteHashMap() );
              ...
          TFloatSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TFloatIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TFloatShortMap synchronizedMap​(TFloatShortMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TFloatShortMap m = TCollections.synchronizedMap( new TFloatShortHashMap() );
              ...
          TFloatSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TFloatIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TFloatCharMap synchronizedMap​(TFloatCharMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TFloatCharMap m = TCollections.synchronizedMap( new TFloatCharHashMap() );
              ...
          TFloatSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TFloatIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TIntDoubleMap synchronizedMap​(TIntDoubleMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TIntDoubleMap m = TCollections.synchronizedMap( new TIntDoubleHashMap() );
              ...
          TIntSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TIntIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TIntFloatMap synchronizedMap​(TIntFloatMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TIntFloatMap m = TCollections.synchronizedMap( new TIntFloatHashMap() );
              ...
          TIntSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TIntIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TIntIntMap synchronizedMap​(TIntIntMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TIntIntMap m = TCollections.synchronizedMap( new TIntIntHashMap() );
              ...
          TIntSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TIntIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TIntLongMap synchronizedMap​(TIntLongMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TIntLongMap m = TCollections.synchronizedMap( new TIntLongHashMap() );
              ...
          TIntSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TIntIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TIntByteMap synchronizedMap​(TIntByteMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TIntByteMap m = TCollections.synchronizedMap( new TIntByteHashMap() );
              ...
          TIntSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TIntIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TIntShortMap synchronizedMap​(TIntShortMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TIntShortMap m = TCollections.synchronizedMap( new TIntShortHashMap() );
              ...
          TIntSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TIntIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TIntCharMap synchronizedMap​(TIntCharMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TIntCharMap m = TCollections.synchronizedMap( new TIntCharHashMap() );
              ...
          TIntSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TIntIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TLongDoubleMap synchronizedMap​(TLongDoubleMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TLongDoubleMap m = TCollections.synchronizedMap( new TLongDoubleHashMap() );
              ...
          TLongSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TLongIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TLongFloatMap synchronizedMap​(TLongFloatMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TLongFloatMap m = TCollections.synchronizedMap( new TLongFloatHashMap() );
              ...
          TLongSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TLongIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TLongIntMap synchronizedMap​(TLongIntMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TLongIntMap m = TCollections.synchronizedMap( new TLongIntHashMap() );
              ...
          TLongSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TLongIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TLongLongMap synchronizedMap​(TLongLongMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TLongLongMap m = TCollections.synchronizedMap( new TLongLongHashMap() );
              ...
          TLongSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TLongIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TLongByteMap synchronizedMap​(TLongByteMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TLongByteMap m = TCollections.synchronizedMap( new TLongByteHashMap() );
              ...
          TLongSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TLongIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TLongShortMap synchronizedMap​(TLongShortMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TLongShortMap m = TCollections.synchronizedMap( new TLongShortHashMap() );
              ...
          TLongSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TLongIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TLongCharMap synchronizedMap​(TLongCharMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TLongCharMap m = TCollections.synchronizedMap( new TLongCharHashMap() );
              ...
          TLongSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TLongIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TByteDoubleMap synchronizedMap​(TByteDoubleMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TByteDoubleMap m = TCollections.synchronizedMap( new TByteDoubleHashMap() );
              ...
          TByteSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TByteIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TByteFloatMap synchronizedMap​(TByteFloatMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TByteFloatMap m = TCollections.synchronizedMap( new TByteFloatHashMap() );
              ...
          TByteSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TByteIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TByteIntMap synchronizedMap​(TByteIntMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TByteIntMap m = TCollections.synchronizedMap( new TByteIntHashMap() );
              ...
          TByteSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TByteIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TByteLongMap synchronizedMap​(TByteLongMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TByteLongMap m = TCollections.synchronizedMap( new TByteLongHashMap() );
              ...
          TByteSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TByteIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TByteByteMap synchronizedMap​(TByteByteMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TByteByteMap m = TCollections.synchronizedMap( new TByteByteHashMap() );
              ...
          TByteSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TByteIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TByteShortMap synchronizedMap​(TByteShortMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TByteShortMap m = TCollections.synchronizedMap( new TByteShortHashMap() );
              ...
          TByteSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TByteIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TByteCharMap synchronizedMap​(TByteCharMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TByteCharMap m = TCollections.synchronizedMap( new TByteCharHashMap() );
              ...
          TByteSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TByteIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TShortDoubleMap synchronizedMap​(TShortDoubleMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TShortDoubleMap m = TCollections.synchronizedMap( new TShortDoubleHashMap() );
              ...
          TShortSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TShortIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TShortFloatMap synchronizedMap​(TShortFloatMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TShortFloatMap m = TCollections.synchronizedMap( new TShortFloatHashMap() );
              ...
          TShortSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TShortIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TShortIntMap synchronizedMap​(TShortIntMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TShortIntMap m = TCollections.synchronizedMap( new TShortIntHashMap() );
              ...
          TShortSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TShortIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TShortLongMap synchronizedMap​(TShortLongMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TShortLongMap m = TCollections.synchronizedMap( new TShortLongHashMap() );
              ...
          TShortSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TShortIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TShortByteMap synchronizedMap​(TShortByteMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TShortByteMap m = TCollections.synchronizedMap( new TShortByteHashMap() );
              ...
          TShortSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TShortIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TShortShortMap synchronizedMap​(TShortShortMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TShortShortMap m = TCollections.synchronizedMap( new TShortShortHashMap() );
              ...
          TShortSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TShortIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TShortCharMap synchronizedMap​(TShortCharMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TShortCharMap m = TCollections.synchronizedMap( new TShortCharHashMap() );
              ...
          TShortSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TShortIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TCharDoubleMap synchronizedMap​(TCharDoubleMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TCharDoubleMap m = TCollections.synchronizedMap( new TCharDoubleHashMap() );
              ...
          TCharSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TCharIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TCharFloatMap synchronizedMap​(TCharFloatMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TCharFloatMap m = TCollections.synchronizedMap( new TCharFloatHashMap() );
              ...
          TCharSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TCharIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TCharIntMap synchronizedMap​(TCharIntMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TCharIntMap m = TCollections.synchronizedMap( new TCharIntHashMap() );
              ...
          TCharSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TCharIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TCharLongMap synchronizedMap​(TCharLongMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TCharLongMap m = TCollections.synchronizedMap( new TCharLongHashMap() );
              ...
          TCharSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TCharIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TCharByteMap synchronizedMap​(TCharByteMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TCharByteMap m = TCollections.synchronizedMap( new TCharByteHashMap() );
              ...
          TCharSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TCharIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TCharShortMap synchronizedMap​(TCharShortMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TCharShortMap m = TCollections.synchronizedMap( new TCharShortHashMap() );
              ...
          TCharSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TCharIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static TCharCharMap synchronizedMap​(TCharCharMap m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TCharCharMap m = TCollections.synchronizedMap( new TCharCharHashMap() );
              ...
          TCharSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TCharIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <V> TDoubleObjectMap<V> synchronizedMap​(TDoubleObjectMap<V> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TDoubleObjectMap m = TCollections.synchronizedMap( new TDoubleObjectHashMap() );
              ...
          TDoubleSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TDoubleIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <V> TFloatObjectMap<V> synchronizedMap​(TFloatObjectMap<V> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TFloatObjectMap m = TCollections.synchronizedMap( new TFloatObjectHashMap() );
              ...
          TFloatSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TFloatIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <V> TIntObjectMap<V> synchronizedMap​(TIntObjectMap<V> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TIntObjectMap m = TCollections.synchronizedMap( new TIntObjectHashMap() );
              ...
          TIntSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TIntIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <V> TLongObjectMap<V> synchronizedMap​(TLongObjectMap<V> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TLongObjectMap m = TCollections.synchronizedMap( new TLongObjectHashMap() );
              ...
          TLongSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TLongIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <V> TByteObjectMap<V> synchronizedMap​(TByteObjectMap<V> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TByteObjectMap m = TCollections.synchronizedMap( new TByteObjectHashMap() );
              ...
          TByteSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TByteIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <V> TShortObjectMap<V> synchronizedMap​(TShortObjectMap<V> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TShortObjectMap m = TCollections.synchronizedMap( new TShortObjectHashMap() );
              ...
          TShortSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TShortIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <V> TCharObjectMap<V> synchronizedMap​(TCharObjectMap<V> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TCharObjectMap m = TCollections.synchronizedMap( new TCharObjectHashMap() );
              ...
          TCharSet s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              TCharIterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <K> TObjectDoubleMap<K> synchronizedMap​(TObjectDoubleMap<K> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TObjectDoubleMap m = TCollections.synchronizedMap( new TObjectDoubleHashMap() );
              ...
          Set s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              Iterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <K> TObjectFloatMap<K> synchronizedMap​(TObjectFloatMap<K> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TObjectFloatMap m = TCollections.synchronizedMap( new TObjectFloatHashMap() );
              ...
          Set s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              Iterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <K> TObjectIntMap<K> synchronizedMap​(TObjectIntMap<K> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TObjectIntMap m = TCollections.synchronizedMap( new TObjectIntHashMap() );
              ...
          Set s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              Iterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <K> TObjectLongMap<K> synchronizedMap​(TObjectLongMap<K> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TObjectLongMap m = TCollections.synchronizedMap( new TObjectLongHashMap() );
              ...
          Set s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              Iterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <K> TObjectByteMap<K> synchronizedMap​(TObjectByteMap<K> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TObjectByteMap m = TCollections.synchronizedMap( new TObjectByteHashMap() );
              ...
          Set s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              Iterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <K> TObjectShortMap<K> synchronizedMap​(TObjectShortMap<K> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TObjectShortMap m = TCollections.synchronizedMap( new TObjectShortHashMap() );
              ...
          Set s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              Iterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.
      • synchronizedMap

        public static <K> TObjectCharMap<K> synchronizedMap​(TObjectCharMap<K> m)
        Returns a synchronized (thread-safe) Trove map backed by the specified map. In order to guarantee serial access, it is critical that all access to the backing map is accomplished through the returned map.

        It is imperative that the user manually synchronize on the returned map when iterating over any of its collection views:

          TObjectCharMap m = TCollections.synchronizedMap( new TObjectCharHashMap() );
              ...
          Set s = m.keySet();  // Needn't be in synchronized block
              ...
          synchronized( m ) {  // Synchronizing on m, not s!
              Iterator i = s.iterator(); // Must be in synchronized block
              while ( i.hasNext() )
                  foo( i.next() );
          }
         
        Failure to follow this advice may result in non-deterministic behavior.

        The returned map will be serializable if the specified map is serializable.

        Parameters:
        m - the map to be "wrapped" in a synchronized map.
        Returns:
        a synchronized view of the specified map.