org.apache.commons.collections4

## Interface KeyValue<K,V>

- Type Parameters:
    `K` - the type of the key
    `V` - the type of the value
  All Known Implementing Classes:
    AbstractDualBidiMap.MapEntry, AbstractHashedMap.HashEntry, AbstractKeyValue, AbstractLinkedMap.LinkEntry, AbstractMapEntry, AbstractMapEntryDecorator, AbstractReferenceMap.ReferenceEntry, DefaultKeyValue, DefaultMapEntry, SingletonMap, TiedMapEntry, UnmodifiableMapEntry

      public interface KeyValue<K,V>

  Defines a simple key value pair.

  A Map Entry has considerable additional semantics over and above a simple key-value pair. This interface defines the minimum key value, with just the two get methods.

  Since:
    3.0

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `K` | `getKey()` Gets the key from the pair.
    `V` | `getValue()` Gets the value from the pair.

- - ### Method Detail

    - #### getKey

          K getKey()

      Gets the key from the pair.
      Returns:
        the key

    - #### getValue

          V getValue()

      Gets the value from the pair.
      Returns:
        the value

Copyright © 2001–2019 The Apache Software Foundation. All rights reserved.