svn-gvsig-desktop / tags / v1_1_Build_1014 / libraries / libFMap / src / com / iver / cit / gvsig / fmap / drivers / IVectorialDatabaseDriver.java @ 13593
History | View | Annotate | Download (4.27 KB)
1 | 11926 | caballero | /* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
|
---|---|---|---|
2 | *
|
||
3 | * Copyright (C) 2004 IVER T.I. 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 | * IVER T.I. S.A
|
||
34 | * Salamanca 50
|
||
35 | * 46005 Valencia
|
||
36 | * Spain
|
||
37 | *
|
||
38 | * +34 963163400
|
||
39 | * dac@iver.es
|
||
40 | */
|
||
41 | package com.iver.cit.gvsig.fmap.drivers; |
||
42 | |||
43 | import java.awt.geom.Rectangle2D; |
||
44 | 12351 | caballero | import java.io.IOException; |
45 | 11926 | caballero | |
46 | import com.iver.cit.gvsig.fmap.DriverException; |
||
47 | import com.iver.cit.gvsig.fmap.core.IFeature; |
||
48 | import com.iver.cit.gvsig.fmap.layers.XMLException; |
||
49 | import com.iver.utiles.XMLEntity; |
||
50 | |||
51 | public interface IVectorialDatabaseDriver extends VectorialDriver { |
||
52 | /**
|
||
53 | * @param conn
|
||
54 | * @param tableName
|
||
55 | * @param fields (Todos los campos, el primero ha de ser el de las geometr?as
|
||
56 | * @param whereClause
|
||
57 | * @param id_FID_field El identificador del campo que contiene una clave ?nica. 1=> primer campo, 2 => segundo campo, etc
|
||
58 | 12351 | caballero | * @throws IOException
|
59 | 11926 | caballero | *
|
60 | */
|
||
61 | // public void setData(Connection conn, String tableName, String fields, String whereClause, int id_FID_field);
|
||
62 | 12351 | caballero | public Rectangle2D getFullExtent() throws IOException; |
63 | 11926 | caballero | public int getShapeType(); |
64 | |||
65 | public IFeatureIterator getFeatureIterator(Rectangle2D r, String strEPSG) throws DriverException; |
||
66 | public IFeatureIterator getFeatureIterator(Rectangle2D r, String strEPSG, String[] alphaNumericFieldsNeeded) throws DriverException; |
||
67 | public String[] getFields(); |
||
68 | public String getWhereClause(); |
||
69 | public String getTableName(); |
||
70 | public void close(); |
||
71 | public void open() throws com.iver.cit.gvsig.fmap.DriverException; |
||
72 | /**
|
||
73 | * @param FID
|
||
74 | * @return el n?mero de registro asociado a ese FID. Se usa dentro
|
||
75 | * del DBStrategy para averig?ar si un Feature est? seleccionado
|
||
76 | * o no.
|
||
77 | */
|
||
78 | public int getRowIndexByFID(IFeature FID); |
||
79 | public String getGeometryField(String fieldName); |
||
80 | |||
81 | public XMLEntity getXMLEntity();
|
||
82 | /**
|
||
83 | * Para evitar que una clase no se pueda instanciar,
|
||
84 | * el setXMLEntity deber?a devolver una referencia
|
||
85 | * a la clase que crea. Ya vorem.
|
||
86 | */
|
||
87 | public void setXMLEntity(XMLEntity xml) throws XMLException; |
||
88 | |||
89 | /**
|
||
90 | * @return information about catalog, fields, tablename, etc
|
||
91 | */
|
||
92 | public DBLayerDefinition getLyrDef();
|
||
93 | |||
94 | /**
|
||
95 | * This method is called by FLyrVect when its goig to be removed from the
|
||
96 | * view. The driver can then do what it has to do.
|
||
97 | *
|
||
98 | */
|
||
99 | public void remove(); |
||
100 | public void load() throws DriverException; |
||
101 | public IConnection getConnection();
|
||
102 | public String getConnectionString(String _host, String _port, String _db, String _user, String _pw); |
||
103 | public int getDefaultPort(); |
||
104 | public String getConnectionStringBeginning(); |
||
105 | 12351 | caballero | public void setData(IConnection conn, DBLayerDefinition lyrDef) throws DBException; |
106 | 11926 | caballero | public String[] getAllFields(IConnection conn, String tableName) throws DBException; |
107 | public String[] getAllFieldTypeNames(IConnection conn, String tableName) throws DBException; |
||
108 | public String[] getIdFieldsCandidates(IConnection conn, String tableName) throws DBException; |
||
109 | public String[] getGeometryFieldsCandidates(IConnection conn, String tableName)throws DBException; |
||
110 | public void setWorkingArea(Rectangle2D _wa); |
||
111 | public String[] getTableNames(IConnection conex, String dbName) throws DBException; |
||
112 | public Rectangle2D getWorkingArea(); |
||
113 | 12268 | caballero | // public String[] getTableFields(IConnection conex,String table) throws DBException;
|
114 | 11926 | caballero | |
115 | } |