Class WeakConcurrentMap.WithInlinedExpunction<K,​V>

    • Constructor Detail

      • WithInlinedExpunction

        public WithInlinedExpunction()
    • Method Detail

      • get

        public V get​(K key)
        Overrides:
        get in class AbstractWeakConcurrentMap<K,​V,​io.opentelemetry.context.internal.shaded.WeakConcurrentMap.LookupKey<K>>
        Parameters:
        key - The key of the entry.
        Returns:
        The value of the entry or the default value if it did not exist.
      • containsKey

        public boolean containsKey​(K key)
        Overrides:
        containsKey in class AbstractWeakConcurrentMap<K,​V,​io.opentelemetry.context.internal.shaded.WeakConcurrentMap.LookupKey<K>>
        Parameters:
        key - The key of the entry.
        Returns:
        true if the key already defines a value.
      • put

        public V put​(K key,
                     V value)
        Overrides:
        put in class AbstractWeakConcurrentMap<K,​V,​io.opentelemetry.context.internal.shaded.WeakConcurrentMap.LookupKey<K>>
        Parameters:
        key - The key of the entry.
        value - The value of the entry.
        Returns:
        The previous entry or null if it does not exist.
      • remove

        public V remove​(K key)
        Overrides:
        remove in class AbstractWeakConcurrentMap<K,​V,​io.opentelemetry.context.internal.shaded.WeakConcurrentMap.LookupKey<K>>
        Parameters:
        key - The key of the entry.
        Returns:
        The removed entry or null if it does not exist.
      • approximateSize

        public int approximateSize()
        Description copied from class: AbstractWeakConcurrentMap
        Returns the approximate size of this map where the returned number is at least as big as the actual number of entries.
        Overrides:
        approximateSize in class AbstractWeakConcurrentMap<K,​V,​io.opentelemetry.context.internal.shaded.WeakConcurrentMap.LookupKey<K>>
        Returns:
        The minimum size of this map.