gvsig-tools / org.gvsig.tools / library / trunk / org.gvsig.tools / org.gvsig.tools.dynform / org.gvsig.tools.dynform.api / src / main / java / org / gvsig / tools / dynform / JDynForm.java @ 1697
History | View | Annotate | Download (3.04 KB)
1 |
/**
|
---|---|
2 |
* gvSIG. Desktop Geographic Information System.
|
3 |
*
|
4 |
* Copyright (C) 2007-2013 gvSIG Association.
|
5 |
*
|
6 |
* This program is free software; you can redistribute it and/or
|
7 |
* modify it under the terms of the GNU General Public License
|
8 |
* as published by the Free Software Foundation; either version 3
|
9 |
* of the License, or (at your option) any later version.
|
10 |
*
|
11 |
* This program is distributed in the hope that it will be useful,
|
12 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14 |
* GNU General Public License for more details.
|
15 |
*
|
16 |
* You should have received a copy of the GNU General Public License
|
17 |
* along with this program; if not, write to the Free Software
|
18 |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
19 |
* MA 02110-1301, USA.
|
20 |
*
|
21 |
* For any additional information, do not hesitate to contact us
|
22 |
* at info AT gvsig.com, or visit our website www.gvsig.com.
|
23 |
*/
|
24 |
package org.gvsig.tools.dynform; |
25 |
|
26 |
import java.util.List; |
27 |
|
28 |
import javax.swing.Action; |
29 |
|
30 |
import org.gvsig.tools.dataTypes.DataType; |
31 |
import org.gvsig.tools.dynobject.DynObject; |
32 |
import org.gvsig.tools.swing.api.Component; |
33 |
import org.gvsig.tools.util.PropertiesSupport; |
34 |
|
35 |
public interface JDynForm extends Component, PropertiesSupport { |
36 |
|
37 |
public interface JDynFormListener { |
38 |
public void message(String message); |
39 |
/**
|
40 |
* This event is fired when a field of the form is changed by the user.
|
41 |
*
|
42 |
* Now this is not yet implemented.
|
43 |
*
|
44 |
* @param field
|
45 |
*/
|
46 |
public void fieldChanged(JDynFormField field); |
47 |
} |
48 |
|
49 |
public static final int USE_PLAIN = 0; |
50 |
public static final int USE_TABS = 1; |
51 |
public static final int USE_SEPARATORS = 2; |
52 |
public static final int USE_TREE = 3; |
53 |
|
54 |
public void setLayoutMode(int layoutMode); |
55 |
public int getLayoutMode(); |
56 |
|
57 |
public int getFormWidth(); |
58 |
public int getFormHeight(); |
59 |
public void setFormSize(int width, int height); |
60 |
|
61 |
public JDynFormField getField(String fieldName); |
62 |
|
63 |
// public Collection<JDynFormField> getShowFields();
|
64 |
|
65 |
public DynFormDefinition getDefinition();
|
66 |
|
67 |
public void setValues(DynObject values); |
68 |
public void getValues(DynObject values); |
69 |
|
70 |
public Object getValue(String fieldName); |
71 |
public void setValue(String fieldName, Object value); |
72 |
|
73 |
public boolean hasValidValues(); |
74 |
public boolean hasValidValues(List<String> fieldsName); |
75 |
|
76 |
public void message(); |
77 |
|
78 |
public void message(String msg); |
79 |
|
80 |
public void setReadOnly(boolean readOnly); |
81 |
public boolean isReadOnly(); |
82 |
|
83 |
public void setShowMessageStatus(boolean showMessageStatus); |
84 |
|
85 |
public boolean isShowMessageStatus(); |
86 |
|
87 |
public void setUseScrollBars(boolean usesScrolls); |
88 |
public boolean getUseScrollBars(); |
89 |
|
90 |
public boolean isModified(); |
91 |
|
92 |
public void addListener(JDynFormListener listener); |
93 |
public void removeListener(JDynFormListener listener); |
94 |
|
95 |
public void addActionToPopupMenu(DataType tipo, String name, Action action); |
96 |
public void addSeparatorToPopupMenu(DataType tipo); |
97 |
|
98 |
public void clear(); |
99 |
} |