Class Short2ShortFunctions.EmptyFunction

java.lang.Object
it.unimi.dsi.fastutil.shorts.AbstractShort2ShortFunction
it.unimi.dsi.fastutil.shorts.Short2ShortFunctions.EmptyFunction
All Implemented Interfaces:
it.unimi.dsi.fastutil.Function<Short,Short>, it.unimi.dsi.fastutil.shorts.Short2ShortFunction, Serializable, Cloneable, Function<Short,Short>, IntUnaryOperator
Direct Known Subclasses:
Short2ShortMaps.EmptyMap
Enclosing class:
Short2ShortFunctions

public static class Short2ShortFunctions.EmptyFunction extends AbstractShort2ShortFunction implements Serializable, Cloneable
An immutable class representing an empty type-specific function.

This class may be useful to implement your own in case you subclass a type-specific function.

See Also:
  • Field Summary

    Fields inherited from class it.unimi.dsi.fastutil.shorts.AbstractShort2ShortFunction

    defRetValue
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
     
     
    boolean
    containsKey(short k)
     
    short
     
    void
    defaultReturnValue(short defRetValue)
     
    boolean
     
    short
    get(short k)
     
    short
    getOrDefault(short k, short defaultValue)
     
    int
     
    int
     
     

    Methods inherited from class java.lang.Object

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

    Methods inherited from interface it.unimi.dsi.fastutil.Function

    apply

    Methods inherited from interface java.util.function.IntUnaryOperator

    andThen, compose

    Methods inherited from interface it.unimi.dsi.fastutil.shorts.Short2ShortFunction

    andThen, andThenByte, andThenChar, andThenDouble, andThenFloat, andThenInt, andThenLong, andThenObject, andThenReference, andThenShort, applyAsInt, compose, composeByte, composeChar, composeDouble, composeFloat, composeInt, composeLong, composeObject, composeReference, composeShort, containsKey, get, getOrDefault, put, put, remove, remove
  • Constructor Details

    • EmptyFunction

      protected EmptyFunction()
  • Method Details

    • get

      public short get(short k)
      Specified by:
      get in interface it.unimi.dsi.fastutil.shorts.Short2ShortFunction
    • getOrDefault

      public short getOrDefault(short k, short defaultValue)
      Specified by:
      getOrDefault in interface it.unimi.dsi.fastutil.shorts.Short2ShortFunction
    • containsKey

      public boolean containsKey(short k)
      Specified by:
      containsKey in interface it.unimi.dsi.fastutil.shorts.Short2ShortFunction
    • defaultReturnValue

      public short defaultReturnValue()
      Specified by:
      defaultReturnValue in interface it.unimi.dsi.fastutil.shorts.Short2ShortFunction
      Overrides:
      defaultReturnValue in class AbstractShort2ShortFunction
    • defaultReturnValue

      public void defaultReturnValue(short defRetValue)
      Specified by:
      defaultReturnValue in interface it.unimi.dsi.fastutil.shorts.Short2ShortFunction
      Overrides:
      defaultReturnValue in class AbstractShort2ShortFunction
    • size

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

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

      public Object clone()
      Overrides:
      clone in class Object
    • 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