Revision 10051
branches/v10/libraries/libGDBMS/src/main/java/com/hardcode/gdbms/driver/mysql/MySQLDriver.java | ||
---|---|---|
58 | 58 |
writer.setWriteAll(false); |
59 | 59 |
DBDataWare dw = DBDataSourceFactory.newDataWareInstance(this, DataSourceFactory.DATA_WARE_DIRECT_MODE); |
60 | 60 |
dw.setDriver(this); |
61 |
ITableDefinition schema = super.getTableDefinition(); |
|
61 |
// ITableDefinition schema = super.getTableDefinition();
|
|
62 | 62 |
ResultSetMetaData metadata = jdbcSupport.getResultSet(). |
63 | 63 |
getMetaData(); |
64 | 64 |
|
... | ... | |
131 | 131 |
*Como se necesita construir la query al vuelo, as? se le proporciona |
132 | 132 |
*al ITableDefinition el nombre de la tabla |
133 | 133 |
* */ |
134 |
public ITableDefinition getTableDefinition(){ |
|
135 |
DBLayerDefinition solution = new DBLayerDefinition(); |
|
136 |
ITableDefinition schema = super.getTableDefinition(); |
|
137 |
solution.setFieldsDesc(schema.getFieldsDesc()); |
|
138 |
solution.setName(schema.getName()); |
|
139 |
try { |
|
140 |
ResultSetMetaData metadata = jdbcSupport.getResultSet(). |
|
141 |
getMetaData(); |
|
142 |
solution.setTableName(metadata.getTableName(1)); |
|
143 |
} catch (SQLException e) { |
|
144 |
throw new RuntimeException(e); |
|
145 |
} |
|
146 |
return solution; |
|
147 |
|
|
148 |
|
|
149 |
} |
|
134 |
// public ITableDefinition getTableDefinition(){
|
|
135 |
// DBLayerDefinition solution = new DBLayerDefinition();
|
|
136 |
// ITableDefinition schema = super.getTableDefinition();
|
|
137 |
// solution.setFieldsDesc(schema.getFieldsDesc());
|
|
138 |
// solution.setName(schema.getName());
|
|
139 |
// try {
|
|
140 |
// ResultSetMetaData metadata = jdbcSupport.getResultSet().
|
|
141 |
// getMetaData();
|
|
142 |
// solution.setTableName(metadata.getTableName(1));
|
|
143 |
// } catch (SQLException e) {
|
|
144 |
// throw new RuntimeException(e);
|
|
145 |
// }
|
|
146 |
// return solution;
|
|
147 |
// |
|
148 |
// |
|
149 |
// }
|
|
150 | 150 |
|
151 | 151 |
public void beginTrans(Connection con) throws SQLException { |
152 | 152 |
// TODO Auto-generated method stub |
branches/v10/libraries/libGDBMS/src/main/java/com/hardcode/gdbms/engine/data/driver/AbstractJDBCDriver.java | ||
---|---|---|
293 | 293 |
* this. |
294 | 294 |
* |
295 | 295 |
* */ |
296 |
public ITableDefinition getTableDefinition(){ |
|
297 |
TableDefinition tableDef = new TableDefinition(); |
|
298 |
try { |
|
299 |
tableDef.setFieldsDesc(getFieldsDescription()); |
|
300 |
} catch (DriverException e) { |
|
301 |
throw new RuntimeException(e);//excepcion sin chequear |
|
302 |
} |
|
303 |
return tableDef; |
|
304 |
} |
|
296 |
// public ITableDefinition getTableDefinition(){
|
|
297 |
// TableDefinition tableDef = new TableDefinition();
|
|
298 |
// try {
|
|
299 |
// tableDef.setFieldsDesc(getFieldsDescription());
|
|
300 |
// } catch (DriverException e) {
|
|
301 |
// throw new RuntimeException(e);//excepcion sin chequear
|
|
302 |
// }
|
|
303 |
// return tableDef;
|
|
304 |
// }
|
|
305 | 305 |
|
306 | 306 |
|
307 | 307 |
/*azabala |
branches/v10/libraries/libGDBMS/src/main/java/com/hardcode/gdbms/engine/data/driver/AlphanumericDBDriver.java | ||
---|---|---|
3 | 3 |
import java.sql.Connection; |
4 | 4 |
import java.sql.SQLException; |
5 | 5 |
|
6 |
import com.iver.cit.gvsig.fmap.drivers.ITableDefinition; |
|
7 |
|
|
8 | 6 |
/** |
9 | 7 |
* |
10 | 8 |
*/ |
... | ... | |
35 | 33 |
* el esquema de la tabla subyacente (nombre, p. ej) para poder construir |
36 | 34 |
* al vuelo la consulta SQL final. |
37 | 35 |
* */ |
38 |
public ITableDefinition getTableDefinition(); |
|
36 |
// public ITableDefinition getTableDefinition();
|
|
39 | 37 |
} |
branches/v10/libraries/libGDBMS/.classpath | ||
---|---|---|
3 | 3 |
<classpathentry kind="src" path="src/main/java"/> |
4 | 4 |
<classpathentry output="bin-test" kind="src" path="src/test/java"/> |
5 | 5 |
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/> |
6 |
<classpathentry combineaccessrules="false" kind="src" path="/libFMap"/> |
|
7 | 6 |
<classpathentry kind="lib" path="/libFMap/lib/gt2-main.jar"/> |
8 | 7 |
<classpathentry kind="lib" path="/libFMap/lib/jts-1.7.jar"/> |
9 | 8 |
<classpathentry kind="lib" path="/libFMap/lib/postgis-jdbc-driver.jar"/> |
... | ... | |
14 | 13 |
<classpathentry kind="lib" path="/_fwAndami/lib/iver-utiles.jar"/> |
15 | 14 |
<classpathentry kind="lib" path="/_fwAndami/lib/log4j-1.2.8.jar"/> |
16 | 15 |
<classpathentry kind="lib" path="/libFMap/lib/ojdbc14.jar"/> |
17 |
<classpathentry kind="lib" sourcepath="/libCq CMS for java" path="/libFMap/lib/cms.jar"/>
|
|
16 |
<classpathentry sourcepath="/libCq CMS for java" kind="lib" path="/libFMap/lib/cms.jar"/>
|
|
18 | 17 |
<classpathentry kind="lib" path="lib/kxml2.jar"/> |
18 |
<classpathentry combineaccessrules="false" kind="src" path="/libFMap"/> |
|
19 | 19 |
<classpathentry kind="output" path="bin"/> |
20 | 20 |
</classpath> |
Also available in: Unified diff