| ActionsPublisher.java |
1 /*
2 * Copyright (c) 1998-2004, The University of Sheffield.
3 *
4 * This file is part of GATE (see http://gate.ac.uk/), and is free
5 * software, licenced under the GNU Library General Public License,
6 * Version 2, June 1991 (in the distribution as file licence.html,
7 * and also available at http://gate.ac.uk/gate/licence.html).
8 *
9 * Valentin Tablan 21/11/2002
10 *
11 * $Id: ActionsPublisher.java,v 1.3 2004/07/21 17:10:06 akshay Exp $
12 *
13 */
14
15 package gate.gui;
16
17 import java.util.List;
18
19 /**
20 * This interface is used to mark resources that publish a list of actions
21 * that can be performed on them.
22 * Those actions will automatically be added to the appropriate menus when
23 * needed.
24 */
25
26 public interface ActionsPublisher {
27 /**
28 * Returns a list of Action objects. This method will be called everytime a
29 * menu for this resource needs to be built, thus allowing for dynamic updates
30 * to the list of actions.
31 * A <tt>null</tt> value in this list will cause a separator to be created.
32 * @return a {@link List} of {@link javax.swing.Action}s.
33 */
34 public List getActions();
35 }