gvsig-raster / org.gvsig.raster / trunk / org.gvsig.raster / org.gvsig.raster.swing / org.gvsig.raster.swing.api / src / main / java / org / gvsig / raster / swing / RasterSwingManager.java @ 1836
History | View | Annotate | Download (6.08 KB)
1 |
/**
|
---|---|
2 |
* gvSIG. Desktop Geographic Information System.
|
3 |
*
|
4 |
* Copyright (C) 2007-2012 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 2
|
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.raster.swing; |
25 |
|
26 |
import java.awt.Color; |
27 |
import java.util.ArrayList; |
28 |
import java.util.HashMap; |
29 |
|
30 |
import javax.swing.ImageIcon; |
31 |
import javax.swing.JComponent; |
32 |
import javax.swing.JPanel; |
33 |
|
34 |
import org.gvsig.raster.swing.basepanel.IButtonsPanel; |
35 |
import org.gvsig.raster.swing.buttonbar.ButtonBar; |
36 |
import org.gvsig.raster.swing.gcanvas.GCanvas; |
37 |
import org.gvsig.raster.swing.infobypoint.MainInfoByPointPanel; |
38 |
import org.gvsig.raster.swing.newlayer.CreateNewLayerPanel; |
39 |
import org.gvsig.raster.swing.newlayer.FileNameManagement; |
40 |
import org.gvsig.raster.swing.openfile.OpenFileContainer; |
41 |
import org.gvsig.raster.swing.pagedtable.ModelLoader; |
42 |
import org.gvsig.raster.swing.pagedtable.PagedTable; |
43 |
import org.gvsig.raster.swing.pagedtable.TableModel; |
44 |
import org.gvsig.raster.swing.preview.DataSourcePreview; |
45 |
import org.gvsig.raster.swing.preview.PreviewPanel; |
46 |
import org.gvsig.raster.swing.preview.PreviewRenderProcess; |
47 |
import org.gvsig.raster.swing.roi.ROIPanel; |
48 |
|
49 |
|
50 |
/**
|
51 |
* This class is responsible of the management of the library's swing user
|
52 |
* interface. It is the swing library's main entry point, and provides all the
|
53 |
* services to manage library swing components.
|
54 |
*
|
55 |
* @see RasterWindowManager
|
56 |
* @see JValidationServicePanel
|
57 |
* @author gvSIG team
|
58 |
* @version $Id$
|
59 |
*/
|
60 |
public interface RasterSwingManager { |
61 |
|
62 |
/**
|
63 |
* Returns the translation of a string.
|
64 |
*
|
65 |
* @param key
|
66 |
* String to translate
|
67 |
* @return a String with the translation of the string passed by parameter
|
68 |
*/
|
69 |
public String getTranslation(String key); |
70 |
|
71 |
/**
|
72 |
* Registers a new instance of a WindowManager which provides services to
|
73 |
* the management of the application windows.
|
74 |
*
|
75 |
* @param manager
|
76 |
* {@link RasterWindowManager} to register in the
|
77 |
* ScriptingUIManager.
|
78 |
* @see RasterWindowManager
|
79 |
*/
|
80 |
public void registerWindowManager(RasterWindowManager manager); |
81 |
|
82 |
/**
|
83 |
* Returns the {@link RasterWindowManager}.
|
84 |
*
|
85 |
* @return {@link RasterWindowManager}
|
86 |
* @see {@link RasterWindowManager}
|
87 |
*/
|
88 |
public RasterWindowManager getWindowManager();
|
89 |
|
90 |
public BasePanel createGenericBasePanel();
|
91 |
|
92 |
/**
|
93 |
* Creates a canvas to draw graphic layers.
|
94 |
* @param backgroundColor
|
95 |
* @return
|
96 |
*/
|
97 |
public GCanvas createGraphicCanvas(Color backgroundColor); |
98 |
|
99 |
/**
|
100 |
* Creates a preview panel using a data source, a render process and a list
|
101 |
* of panels
|
102 |
* @param buttons
|
103 |
* @param list
|
104 |
* @param generalPanel
|
105 |
* @param downPreviewPanel
|
106 |
* @param renderProcess
|
107 |
* @param dataSource
|
108 |
* @return
|
109 |
*/
|
110 |
@SuppressWarnings("unchecked") |
111 |
public PreviewPanel createPreviewPanel(int buttons, |
112 |
ArrayList list,
|
113 |
JPanel generalPanel,
|
114 |
JPanel downPreviewPanel,
|
115 |
PreviewRenderProcess renderProcess, |
116 |
DataSourcePreview dataSource); |
117 |
|
118 |
/**
|
119 |
* Creates a preview panel using a data source and a render process. After
|
120 |
* the creation the function previewInitializeSizes in {@link PreviewPanel}
|
121 |
* should be invoked.
|
122 |
* @param renderProcess {@link PreviewRenderProcess}
|
123 |
* @param dataSource {@link DataSourcePreview}
|
124 |
* @return {@link PreviewPanel}
|
125 |
*/
|
126 |
public PreviewPanel createSinglePreviewPanel(
|
127 |
PreviewRenderProcess renderProcess, |
128 |
DataSourcePreview dataSource); |
129 |
|
130 |
|
131 |
/**
|
132 |
* Creates the information by point panel
|
133 |
* @param translations
|
134 |
* @param extended
|
135 |
* @return
|
136 |
*/
|
137 |
public MainInfoByPointPanel createInfoByPointPanel(
|
138 |
HashMap<String, String> translations, |
139 |
HashMap<String, ImageIcon> icons, |
140 |
JPanel extended);
|
141 |
|
142 |
/**
|
143 |
* Creates a button bar component
|
144 |
* @return
|
145 |
*/
|
146 |
public ButtonBar createButtonBar();
|
147 |
|
148 |
/**
|
149 |
* Creates a panel to build a new layer
|
150 |
* @param fileNameManagement
|
151 |
* @param extList
|
152 |
* List of file extensions to accept
|
153 |
* @return
|
154 |
*/
|
155 |
public CreateNewLayerPanel createNewLayerPanel(FileNameManagement fileNameManagement);
|
156 |
|
157 |
/**
|
158 |
* Creates a panel to build a new layer
|
159 |
* @param fileNameManagement
|
160 |
* @param extList
|
161 |
* List of file extensions to accept
|
162 |
* @param tittle
|
163 |
* Tittle for the window
|
164 |
* @return
|
165 |
*/
|
166 |
public CreateNewLayerPanel createNewLayerPanel(FileNameManagement fileNameManagement, String tittle); |
167 |
|
168 |
|
169 |
/**
|
170 |
* Creates a panel to open files
|
171 |
* @param showBorder
|
172 |
* @param fileFilter
|
173 |
* @return
|
174 |
*/
|
175 |
public OpenFileContainer createOpenFileContainer(boolean showBorder, String[] fileFilter, String defaultPath); |
176 |
|
177 |
/**
|
178 |
* Creates a panel for manage ROIs of raster
|
179 |
* @return
|
180 |
*/
|
181 |
public ROIPanel createROIPanel();
|
182 |
|
183 |
/**
|
184 |
* Creates a paged table component
|
185 |
* @param modelLoader
|
186 |
* @return
|
187 |
*/
|
188 |
public PagedTable createPagedTable(ModelLoader modelLoader);
|
189 |
|
190 |
/**
|
191 |
* Creates a model loader for a paged table
|
192 |
* @return
|
193 |
*/
|
194 |
public ModelLoader createModelLoader(TableModel tableModel); |
195 |
|
196 |
/**
|
197 |
* Creates a buttons panel
|
198 |
* @param parent
|
199 |
* @return
|
200 |
*/
|
201 |
public IButtonsPanel createButtonsPanel(int buttons, JComponent parent); |
202 |
|
203 |
} |