KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > ui > commands > IElementUpdater


1 /*******************************************************************************
2  * Copyright (c) 2007 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  ******************************************************************************/

11
12 package org.eclipse.ui.commands;
13
14 import java.util.Map JavaDoc;
15
16 import org.eclipse.ui.menus.UIElement;
17
18 /**
19  * An IHandler for a command that expects to provide feedback through the
20  * registered element mechanism must implement this interface.
21  *
22  * @since 3.3
23  *
24  */

25 public interface IElementUpdater {
26     /**
27      * Whenever the elements for a command are refreshed, this method is called
28      * on the active handler for that command.
29      * <p>
30      * <b>Note:</b> Handlers must never cache the element, which can disappear
31      * or be replaced at any time. Everybody should go through the
32      * ICommandService refreshElements(*) method.
33      * </p>
34      *
35      * @param element
36      * An element for a specific UI element. Will not be
37      * <code>null</code>.
38      * @param parameters
39      * Any parameters registered with the callback. Will not be
40      * <code>null</code>, but it may be empty.
41      */

42     public void updateElement(UIElement element, Map JavaDoc parameters);
43 }
44
Popular Tags