gvsig-3d / 2.1 / trunk / org.gvsig.view3d / org.gvsig.view3d.swing / org.gvsig.view3d.swing.api / src / main / java / org / gvsig / view3d / swing / api / View3DSwingManager.java @ 509
History | View | Annotate | Download (5.14 KB)
1 |
/**
|
---|---|
2 |
* gvSIG. Desktop Geographic Information System.
|
3 |
*
|
4 |
* Copyright ? 2007-2015 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 |
|
25 |
package org.gvsig.view3d.swing.api; |
26 |
|
27 |
import java.util.List; |
28 |
|
29 |
import org.gvsig.fmap.mapcontext.MapContext; |
30 |
import org.gvsig.fmap.mapcontext.layers.ExtendedPropertiesSupport; |
31 |
import org.gvsig.fmap.mapcontext.layers.FLayer; |
32 |
import org.gvsig.view3d.swing.api.properties.GeneralProperties3D; |
33 |
import org.gvsig.view3d.swing.api.properties.GeneralProperties3DPanel; |
34 |
import org.gvsig.view3d.swing.api.properties.LayerProperties3DPanel; |
35 |
import org.gvsig.view3d.swing.api.properties.MapControlProperties3D; |
36 |
import org.gvsig.view3d.swing.api.properties.ViewProperties3DPanel; |
37 |
|
38 |
/**
|
39 |
* This class is responsible of the management of the library's swing user
|
40 |
* interface. It is the swing library's main entry point, and provides all the
|
41 |
* services to manage library swing components.
|
42 |
*
|
43 |
* @author <a href="mailto:lmarques@disid.com">Lluis Marques</a>
|
44 |
*
|
45 |
*/
|
46 |
public interface View3DSwingManager { |
47 |
|
48 |
public enum TYPE { |
49 |
SPHERE, FLAT |
50 |
} |
51 |
|
52 |
/**
|
53 |
* Creates a <code>View3DPanel</code> with a {@link MapControl3D}.
|
54 |
*
|
55 |
* @param theMapContext
|
56 |
* associated <code>MapContext</code> of
|
57 |
* <code>MapControl3D</code>
|
58 |
* @param title
|
59 |
* Title of window
|
60 |
* @param type
|
61 |
* Type of <code>MapControl3D</code>. See {@link TYPE}.
|
62 |
* @param viewProperties
|
63 |
* View properties to register this <code>MapControl3D</code>
|
64 |
* @see View3DSwingManager#createMapControl3D(MapContext, TYPE)
|
65 |
* @return
|
66 |
*/
|
67 |
public View3DPanel createView3DPanel(MapContext theMapContext,String title, TYPE type, |
68 |
ExtendedPropertiesSupport viewProperties); |
69 |
|
70 |
/**
|
71 |
* Registers and creatres a <code>MapControl3D</code> as from
|
72 |
* {@link MapContext} {@link TYPE}. When an {@link MapControl3D} is created,
|
73 |
* it automatically adds all available and visible layers of
|
74 |
* <code>MapControl</code>.
|
75 |
*
|
76 |
* @param theMapContext
|
77 |
* associated <code>MapContext</code> of
|
78 |
* <code>MapControl3D</code>
|
79 |
* @param type
|
80 |
* Type of <code>MapControl3D</code>. See {@link TYPE}.
|
81 |
* @param viewProperties
|
82 |
* View properties to register this <code>MapControl3D</code>
|
83 |
* @return an instance of <code>MapControl3D</code> ready to be shown.
|
84 |
*/
|
85 |
public MapControl3D createMapControl3D(MapContext theMapContext, TYPE type,
|
86 |
ExtendedPropertiesSupport viewProperties); |
87 |
|
88 |
/**
|
89 |
* Gets the {@link MapControl3D} associated with view properties
|
90 |
* {@link ExtendedPropertiesSupport}. If there are not indicated type of
|
91 |
* <code>MapControl3D</code> associated with view properties, it will return
|
92 |
* an empty list.
|
93 |
*
|
94 |
* @param viewProperties
|
95 |
* @return List of <code>MapControl3D</code> associated with the view
|
96 |
* propoerties.
|
97 |
*/
|
98 |
public List<MapControl3D> getMapControl3D( |
99 |
ExtendedPropertiesSupport viewProperties); |
100 |
|
101 |
/**
|
102 |
* Gets the {@link MapControl3D} associated with view properties
|
103 |
* {@link ExtendedPropertiesSupport}. Returns <code>null</code>, if there
|
104 |
* are
|
105 |
* not indicated type of <code>MapControl3D</code> registered at view
|
106 |
* properties.
|
107 |
*
|
108 |
* @param viewProperties
|
109 |
* @param type
|
110 |
* Type of <code>MapControl3D</code>
|
111 |
* @return
|
112 |
*/
|
113 |
public MapControl3D getMapControl3D(
|
114 |
ExtendedPropertiesSupport viewProperties, TYPE type); |
115 |
|
116 |
/**
|
117 |
*
|
118 |
* @param layer
|
119 |
* @return
|
120 |
*/
|
121 |
public LayerProperties3DPanel createLayerProperties3DPanel(FLayer layer);
|
122 |
|
123 |
/**
|
124 |
*
|
125 |
* @return
|
126 |
*/
|
127 |
public ViewProperties3DPanel createViewProperties3DPanel(
|
128 |
MapControlProperties3D properties); |
129 |
|
130 |
/**
|
131 |
*
|
132 |
* @param properties
|
133 |
* @return
|
134 |
*/
|
135 |
public GeneralProperties3DPanel createGeneralProperties3DPanel(
|
136 |
GeneralProperties3D properties); |
137 |
|
138 |
public MapControlProperties3D getMapControl3DProperties(
|
139 |
ExtendedPropertiesSupport viewProperties); |
140 |
|
141 |
public void setMapControlProperties3D( |
142 |
ExtendedPropertiesSupport viewProperties, |
143 |
MapControlProperties3D mapControl3DProperties); |
144 |
|
145 |
public GeneralProperties3D getGeneral3DProperties();
|
146 |
|
147 |
public void setGeneral3DProperties(GeneralProperties3D properties); |
148 |
|
149 |
} |