1. /*
  2. * @(#)ComboBoxEditor.java 1.10 00/02/02
  3. *
  4. * Copyright 1997-2000 Sun Microsystems, Inc. All Rights Reserved.
  5. *
  6. * This software is the proprietary information of Sun Microsystems, Inc.
  7. * Use is subject to license terms.
  8. *
  9. */
  10. package javax.swing;
  11. import java.awt.*;
  12. import java.awt.event.*;
  13. /**
  14. * The editor component used for JComboBox components.
  15. *
  16. * @version 1.10 02/02/00
  17. * @author Arnaud Weber
  18. */
  19. public interface ComboBoxEditor {
  20. /** Return the component that should be added to the tree hierarchy for
  21. * this editor
  22. */
  23. public Component getEditorComponent();
  24. /** Set the item that should be edited. Cancel any editing if necessary **/
  25. public void setItem(Object anObject);
  26. /** Return the edited item **/
  27. public Object getItem();
  28. /** Ask the editor to start editing and to select everything **/
  29. public void selectAll();
  30. /** Add an ActionListener. An action event is generated when the edited item changes **/
  31. public void addActionListener(ActionListener l);
  32. /** Remove an ActionListener **/
  33. public void removeActionListener(ActionListener l);
  34. }