KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > compiere > grid > ed > VEditor


1 /******************************************************************************
2  * The contents of this file are subject to the Compiere License Version 1.1
3  * ("License"); You may not use this file except in compliance with the License
4  * You may obtain a copy of the License at http://www.compiere.org/license.html
5  * Software distributed under the License is distributed on an "AS IS" basis,
6  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
7  * the specific language governing rights and limitations under the License.
8  * The Original Code is Compiere ERP & CRM Business Solution
9  * The Initial Developer of the Original Code is Jorg Janke and ComPiere, Inc.
10  * Portions created by Jorg Janke are Copyright (C) 1999-2001 Jorg Janke, parts
11  * created by ComPiere are Copyright (C) ComPiere, Inc.; All Rights Reserved.
12  * Contributor(s): ______________________________________.
13  *****************************************************************************/

14 package org.compiere.grid.ed;
15
16 import java.awt.*;
17 import java.awt.event.*;
18 import java.beans.*;
19 import javax.swing.*;
20 import javax.swing.border.*;
21
22 import org.compiere.model.*;
23 import org.compiere.swing.*;
24
25 /**
26  * Editor Interface for single Row Editors (also used as TableCellEditors).
27  * <p>
28  * Editors fire VetoableChange to inform about new entered values
29  * and listen to propertyChange (MField.PROPERTY) to receive new values
30  * or to (MField.ATTRIBUTE) in changes of Background or Editability
31  *
32  * @author Jorg Janke
33  * @version $Id: VEditor.java,v 1.8 2003/09/05 04:58:59 jjanke Exp $
34  */

35 public interface VEditor extends CEditor, PropertyChangeListener
36 {
37     /**
38      * Get Column Name
39      * @return column name
40      */

41     public String JavaDoc getName();
42
43     /**
44      * Change Listener Interface
45      * @param listener
46      */

47     public void addVetoableChangeListener(VetoableChangeListener listener);
48     /**
49      * Change Listener Interface
50      * @param listener
51      */

52     public void removeVetoableChangeListener(VetoableChangeListener listener);
53     /**
54      * Action Listener
55      * @param listener
56      */

57     public void addActionListener(ActionListener listener);
58 // public void removeActionListener(ActionListener listener);
59

60     /**
61      * Used to set border for table editors
62      * @param border
63      */

64     public void setBorder(Border border);
65
66     /**
67      * Set Font
68      * @param font
69      */

70     public void setFont(Font font);
71
72     /**
73      * Set Foreground
74      * @param color
75      */

76     public void setForeground(Color color);
77
78     /**
79      * Set Field/WindowNo for ValuePreference
80      * @param mField
81      */

82     public void setField (MField mField);
83
84     /**
85      * Dispose
86      */

87     public void dispose();
88
89 } // VEditor
90
Popular Tags