Class LongFloatMap.Entry

java.lang.Object
com.github.tommyettinger.ds.LongFloatMap.Entry
Enclosing class:
LongFloatMap

public static class LongFloatMap.Entry extends Object
  • Field Details

    • key

      public long key
    • value

      public float value
  • Constructor Details

    • Entry

      public Entry()
    • Entry

      public Entry(long key, float value)
    • Entry

      public Entry(LongFloatMap.Entry entry)
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getKey

      public long getKey()
      Returns the key corresponding to this entry.
      Returns:
      the key corresponding to this entry
      Throws:
      IllegalStateException - implementations may, but are not required to, throw this exception if the entry has been removed from the backing map.
    • getValue

      public float getValue()
      Returns the value corresponding to this entry. If the mapping has been removed from the backing map (by the iterator's remove operation), the results of this call are undefined.
      Returns:
      the value corresponding to this entry
    • setValue

      public float setValue(float value)
      Replaces the value corresponding to this entry with the specified value (optional operation). (Writes through to the map.) The behavior of this call is undefined if the mapping has already been removed from the map (by the iterator's remove operation).
      Parameters:
      value - new value to be stored in this entry
      Returns:
      old value corresponding to the entry
      Throws:
      UnsupportedOperationException - if the put operation is not supported by the backing map
      ClassCastException - if the class of the specified value prevents it from being stored in the backing map
      NullPointerException - if the backing map does not permit null values, and the specified value is null
      IllegalArgumentException - if some property of this value prevents it from being stored in the backing map
      IllegalStateException - implementations may, but are not required to, throw this exception if the entry has been removed from the backing map.
    • equals

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

      public int hashCode()
      Overrides:
      hashCode in class Object