Class Object2LongFunctions.SynchronizedFunction<K>

java.lang.Object
it.unimi.dsi.fastutil.objects.Object2LongFunctions.SynchronizedFunction<K>
All Implemented Interfaces:
it.unimi.dsi.fastutil.Function<K,Long>, it.unimi.dsi.fastutil.objects.Object2LongFunction<K>, Serializable, Function<K,Long>, ToLongFunction<K>
Direct Known Subclasses:
Object2LongMaps.SynchronizedMap
Enclosing class:
Object2LongFunctions

public static class Object2LongFunctions.SynchronizedFunction<K> extends Object implements it.unimi.dsi.fastutil.objects.Object2LongFunction<K>, Serializable
A synchronized wrapper class for functions.
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
     
    protected final Object
     
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    SynchronizedFunction(it.unimi.dsi.fastutil.objects.Object2LongFunction<K> f)
     
    protected
    SynchronizedFunction(it.unimi.dsi.fastutil.objects.Object2LongFunction<K> f, Object sync)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    apply(K key)
    Deprecated.
    Please use the corresponding type-specific method instead.
    long
    applyAsLong(K operand)
     
    void
     
    boolean
     
    long
     
    void
    defaultReturnValue(long defRetValue)
     
    boolean
     
    Deprecated.
    Please use the corresponding type-specific method instead.
    long
     
    long
    getOrDefault(Object k, long defaultValue)
     
    getOrDefault(Object k, Long defaultValue)
    Deprecated.
    Please use the corresponding type-specific method instead.
    int
     
    long
    put(K k, long v)
     
    put(K k, Long v)
    Deprecated.
    Please use the corresponding type-specific method instead.
    Deprecated.
    Please use the corresponding type-specific method instead.
    long
     
    int
     
     

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface java.util.function.Function

    compose

    Methods inherited from interface it.unimi.dsi.fastutil.objects.Object2LongFunction

    andThen, andThenByte, andThenChar, andThenDouble, andThenFloat, andThenInt, andThenLong, andThenObject, andThenReference, andThenShort, composeByte, composeChar, composeDouble, composeFloat, composeInt, composeLong, composeObject, composeReference, composeShort
  • Field Details

    • function

      protected final it.unimi.dsi.fastutil.objects.Object2LongFunction<K> function
    • sync

      protected final Object sync
  • Constructor Details

    • SynchronizedFunction

      protected SynchronizedFunction(it.unimi.dsi.fastutil.objects.Object2LongFunction<K> f, Object sync)
    • SynchronizedFunction

      protected SynchronizedFunction(it.unimi.dsi.fastutil.objects.Object2LongFunction<K> f)
  • Method Details

    • applyAsLong

      public long applyAsLong(K operand)
      Specified by:
      applyAsLong in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
      Specified by:
      applyAsLong in interface ToLongFunction<K>
    • apply

      @Deprecated public Long apply(K key)
      Deprecated.
      Please use the corresponding type-specific method instead.
      Specified by:
      apply in interface it.unimi.dsi.fastutil.Function<K,Long>
      Specified by:
      apply in interface Function<K,Long>
    • size

      public int size()
      Specified by:
      size in interface it.unimi.dsi.fastutil.Function<K,Long>
    • defaultReturnValue

      public long defaultReturnValue()
      Specified by:
      defaultReturnValue in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • defaultReturnValue

      public void defaultReturnValue(long defRetValue)
      Specified by:
      defaultReturnValue in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • containsKey

      public boolean containsKey(Object k)
      Specified by:
      containsKey in interface it.unimi.dsi.fastutil.Function<K,Long>
    • put

      public long put(K k, long v)
      Specified by:
      put in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • getLong

      public long getLong(Object k)
      Specified by:
      getLong in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • getOrDefault

      public long getOrDefault(Object k, long defaultValue)
      Specified by:
      getOrDefault in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • removeLong

      public long removeLong(Object k)
      Specified by:
      removeLong in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • clear

      public void clear()
      Specified by:
      clear in interface it.unimi.dsi.fastutil.Function<K,Long>
    • put

      @Deprecated public Long put(K k, Long v)
      Deprecated.
      Please use the corresponding type-specific method instead.
      Specified by:
      put in interface it.unimi.dsi.fastutil.Function<K,Long>
      Specified by:
      put in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • get

      @Deprecated public Long get(Object k)
      Deprecated.
      Please use the corresponding type-specific method instead.
      Specified by:
      get in interface it.unimi.dsi.fastutil.Function<K,Long>
      Specified by:
      get in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • getOrDefault

      @Deprecated public Long getOrDefault(Object k, Long defaultValue)
      Deprecated.
      Please use the corresponding type-specific method instead.
      Specified by:
      getOrDefault in interface it.unimi.dsi.fastutil.Function<K,Long>
      Specified by:
      getOrDefault in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • remove

      @Deprecated public Long remove(Object k)
      Deprecated.
      Please use the corresponding type-specific method instead.
      Specified by:
      remove in interface it.unimi.dsi.fastutil.Function<K,Long>
      Specified by:
      remove in interface it.unimi.dsi.fastutil.objects.Object2LongFunction<K>
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object