Package org.jfree.ui

Class KeyedComboBoxModel.ComboBoxItemPair

  • Enclosing class:
    KeyedComboBoxModel

    private static class KeyedComboBoxModel.ComboBoxItemPair
    extends java.lang.Object
    The internal data carrier to map keys to values and vice versa.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.Object key
      The key.
      private java.lang.Object value
      The value for the key.
    • Constructor Summary

      Constructors 
      Constructor Description
      ComboBoxItemPair​(java.lang.Object key, java.lang.Object value)
      Creates a new item pair for the given key and value.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object getKey()
      Returns the key.
      java.lang.Object getValue()
      Returns the value.
      void setValue​(java.lang.Object value)
      Redefines the value stored for that key.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • key

        private java.lang.Object key
        The key.
      • value

        private java.lang.Object value
        The value for the key.
    • Constructor Detail

      • ComboBoxItemPair

        public ComboBoxItemPair​(java.lang.Object key,
                                java.lang.Object value)
        Creates a new item pair for the given key and value. The value can be changed later, if needed.
        Parameters:
        key - the key
        value - the value
    • Method Detail

      • getKey

        public java.lang.Object getKey()
        Returns the key.
        Returns:
        the key.
      • getValue

        public java.lang.Object getValue()
        Returns the value.
        Returns:
        the value for this key.
      • setValue

        public void setValue​(java.lang.Object value)
        Redefines the value stored for that key.
        Parameters:
        value - the new value.