svn-gvsig-desktop / trunk / applications / appgvSIG / src / com / iver / cit / gvsig / ExtDB_Spatial.java @ 11971
History | View | Annotate | Download (3.22 KB)
1 |
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
|
---|---|
2 |
*
|
3 |
* Copyright (C) 2006 Prodevelop and Generalitat Valenciana.
|
4 |
*
|
5 |
* This program is free software; you can redistribute it and/or
|
6 |
* modify it under the terms of the GNU General Public License
|
7 |
* as published by the Free Software Foundation; either version 2
|
8 |
* of the License, or (at your option) any later version.
|
9 |
*
|
10 |
* This program is distributed in the hope that it will be useful,
|
11 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
12 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
13 |
* GNU General Public License for more details.
|
14 |
*
|
15 |
* You should have received a copy of the GNU General Public License
|
16 |
* along with this program; if not, write to the Free Software
|
17 |
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,USA.
|
18 |
*
|
19 |
* For more information, contact:
|
20 |
*
|
21 |
* Generalitat Valenciana
|
22 |
* Conselleria d'Infraestructures i Transport
|
23 |
* Av. Blasco Ib??ez, 50
|
24 |
* 46010 VALENCIA
|
25 |
* SPAIN
|
26 |
*
|
27 |
* +34 963862235
|
28 |
* gvsig@gva.es
|
29 |
* www.gvsig.gva.es
|
30 |
*
|
31 |
* or
|
32 |
*
|
33 |
* Prodevelop Integraci?n de Tecnolog?as SL
|
34 |
* Conde Salvatierra de ?lava , 34-10
|
35 |
* 46004 Valencia
|
36 |
* Spain
|
37 |
*
|
38 |
* +34 963 510 612
|
39 |
* +34 963 510 968
|
40 |
* gis@prodevelop.es
|
41 |
* http://www.prodevelop.es
|
42 |
*/
|
43 |
package com.iver.cit.gvsig; |
44 |
|
45 |
import com.iver.andami.PluginServices; |
46 |
import com.iver.andami.plugins.Extension; |
47 |
import com.iver.andami.ui.mdiManager.IWindow; |
48 |
|
49 |
import com.iver.cit.gvsig.About; |
50 |
import com.iver.cit.gvsig.AddLayer; |
51 |
import com.iver.cit.gvsig.fmap.MapContext; |
52 |
import com.iver.cit.gvsig.fmap.MapControl; |
53 |
import com.iver.cit.gvsig.fmap.layers.FLayer; |
54 |
import com.iver.cit.gvsig.fmap.layers.FLayerVectorialDB; |
55 |
import com.iver.cit.gvsig.fmap.layers.FLyrVect; |
56 |
import com.iver.cit.gvsig.project.documents.view.gui.View; |
57 |
|
58 |
import com.iver.utiles.extensionPoints.ExtensionPoint; |
59 |
import com.iver.utiles.extensionPoints.ExtensionPoints; |
60 |
import com.iver.utiles.extensionPoints.ExtensionPointsSingleton; |
61 |
import com.prodevelop.cit.gvsig.vectorialdb.wizard.WizardVectorialDB; |
62 |
|
63 |
import org.apache.log4j.Logger; |
64 |
|
65 |
import java.security.KeyException; |
66 |
|
67 |
|
68 |
/**
|
69 |
* This extension adds the export-to-oracle button.
|
70 |
*
|
71 |
* @author jldominguez
|
72 |
*
|
73 |
*/
|
74 |
public class ExtDB_Spatial extends Extension { |
75 |
private static Logger logger = Logger.getLogger(ExtDB_Spatial.class.getName()); |
76 |
|
77 |
public void initialize() { |
78 |
|
79 |
System.out.println("A?ado WizardVectorialDB."); |
80 |
AddLayer.addWizard(WizardVectorialDB.class); |
81 |
|
82 |
ExtensionPoints extensionPoints = ExtensionPointsSingleton.getInstance(); |
83 |
|
84 |
extensionPoints.add("Layers", FLayerVectorialDB.class.getName(),
|
85 |
FLayerVectorialDB.class); |
86 |
|
87 |
try {
|
88 |
((ExtensionPoint) extensionPoints.get("Layers")).addAlias(FLayerVectorialDB.class.getName(),
|
89 |
"VectorialDB");
|
90 |
} |
91 |
catch (KeyException e) { |
92 |
// TODO Auto-generated catch block
|
93 |
e.printStackTrace(); |
94 |
} |
95 |
} |
96 |
|
97 |
public void execute(String actionCommand) { |
98 |
} |
99 |
|
100 |
public boolean isEnabled() { |
101 |
return isVisible();
|
102 |
|
103 |
// return true;
|
104 |
} |
105 |
|
106 |
/**
|
107 |
* Is visible when there is one vector layer selected
|
108 |
*/
|
109 |
public boolean isVisible() { |
110 |
return false; |
111 |
} |
112 |
} |