KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > openide > explorer > propertysheet > PropertyDisplayer


1 /*
2  * The contents of this file are subject to the terms of the Common Development
3  * and Distribution License (the License). You may not use this file except in
4  * compliance with the License.
5  *
6  * You can obtain a copy of the License at http://www.netbeans.org/cddl.html
7  * or http://www.netbeans.org/cddl.txt.
8  *
9  * When distributing Covered Code, include this CDDL Header Notice in each file
10  * and include the License file at http://www.netbeans.org/cddl.txt.
11  * If applicable, add the following below the CDDL Header, with the fields
12  * enclosed by brackets [] replaced by your own identifying information:
13  * "Portions Copyrighted [year] [name of copyright owner]"
14  *
15  * The Original Software is NetBeans. The Initial Developer of the Original
16  * Software is Sun Microsystems, Inc. Portions Copyright 1997-2006 Sun
17  * Microsystems, Inc. All Rights Reserved.
18  */

19 /*
20  * PropertyDisplayer.java
21  *
22  * Created on 17 October 2003, 15:31
23  */

24 package org.openide.explorer.propertysheet;
25
26 import org.openide.nodes.Node.*;
27
28 import java.awt.Component JavaDoc;
29 import java.awt.event.ActionListener JavaDoc;
30
31 import javax.swing.event.ChangeListener JavaDoc;
32
33
34 /** A set of interfaces which define the contract for different types of
35  * components that can display or edit properties. There is the base interface
36  * for any component that can display a property, and sub interfaces describing
37  * aspects such as editability. Eventually this interfaces and a factory
38  * should become public as a replacement for PropertyPanel - they are much
39  * more straightforward in terms of setting expectations correctly about
40  * the behavior of the underlying component.
41  * <p>
42  * Note that to avoid making them public, the subinterfaces have been factored
43  * out for the time being.
44  *
45  * @author Tim Boudreau */

46 interface PropertyDisplayer {
47     /**Update policy constant - update whenever an ActionEvent is received from
48      * an editor component */

49     public static final int UPDATE_ON_CONFIRMATION = 0;
50
51     /**Update policy constant - update if the user tabs out of the editor
52      * component or it otherwise loses focus */

53     public static final int UPDATE_ON_FOCUS_LOST = 1;
54
55     /**Update policy constant - fire an action event but do not actually
56      * update the property */

57     public static final int UPDATE_ON_EXPLICIT_REQUEST = 2;
58
59     public Property getProperty();
60
61     public void refresh();
62
63     public Component JavaDoc getComponent();
64 }
65
Popular Tags