Interface XAddingMap<K,​V>

Type Parameters:
K - the key type
V - the value type
All Superinterfaces:
CapacityCarrying, CapacityExtendable, ExtendedCollection<KeyValue<K,​V>>, ExtendedMap<K,​V>, Sized
All Known Subinterfaces:
XAddGetMap<K,​V>, XAddingTable<K,​V>, XBasicTable<K,​V>, XChart<K,​V>, XMap<K,​V>, XPutGetMap<K,​V>, XPuttingMap<K,​V>, XTable<K,​V>
All Known Implementing Classes:
EqHashTable, HashTable, LockedMap

public interface XAddingMap<K,​V>
extends CapacityExtendable, ExtendedMap<K,​V>
  • Method Details

    • nullKeyAllowed

      boolean nullKeyAllowed()
    • nullValuesAllowed

      boolean nullValuesAllowed()
    • add

      boolean add​(K key, V value)
      Adds the passed key and value as an entry if key is not yet contained. Return value indicates new entry.
      Parameters:
      key - the key
      value - the value
      Returns:
      true if a new entry was created
    • set

      boolean set​(K key, V value)
      Sets the passed key and value to an appropriate entry if one can be found. Return value indicates entry change.
      Parameters:
      key - the key
      value - the value
      Returns:
      true if an entry was changed
    • valueSet

      boolean valueSet​(K sampleKey, V value)
      Sets only the passed value to an existing entry appropriate to the passed sampleKey. Returns value indicates change.
      Parameters:
      sampleKey - the key
      value - the value
      Returns:
      true if a value was changed