I was just browsing through the OracleDialect.java (gs 2.3.5, gt 9.5),
debugging a problem, when i came across this function:
> @Override
> public Class<?> getMapping(ResultSet columnMetaData, Connection cx)
> throws SQLException {
> final int TABLE_NAME = 3;
> final int COLUMN_NAME = 4;
> final int TYPE_NAME = 6;
> String typeName = columnMetaData.getString(TYPE_NAME);
> if (typeName.equals("SDO_GEOMETRY")) {
> String tableName = columnMetaData.getString(TABLE_NAME);
> String columnName = columnMetaData.getString(COLUMN_NAME);
> String schema = dataStore.getDatabaseSchema();
>
> Class geometryClass = lookupGeometryOnMetadataTable(cx,
> tableName, columnName, schema);
> if (geometryClass == null) {
> lookupGeometryClassOnUserIndex(cx, tableName, columnName,
> schema);
> }
> if (geometryClass == null) {
> geometryClass = lookupGeometryClassOnAllIndex(cx,
> tableName, columnName, schema);
> }
> if (geometryClass == null) {
> geometryClass = Geometry.class;
> }
>
> return geometryClass;
> } else {
> // if we know, return non null value, otherwise
> returning
> // null will force the datatore to figure it out using
> // jdbc metadata
> return TYPES_TO_CLASSES.get(typeName);
> }
> }
Is is just me, or should this line:
if (geometryClass == null) {
lookupGeometryClassOnUserIndex(cx, tableName, columnName,
schema);
}
actually say:
if (geometryClass == null) {
geometryClass = lookupGeometryClassOnUserIndex(cx,
tableName, columnName, schema);
}
?
--
View this message in context:
http://osgeo-org.1560.x6.nabble.com/OracleDialect-tp5073930.html
Sent from the GeoServer - Dev mailing list archive at Nabble.com.
------------------------------------------------------------------------------
Introducing Performance Central, a new site from SourceForge and
AppDynamics. Performance Central is your source for news, insights,
analysis and resources for efficient Application Performance Management.
Visit us today!
http://pubads.g.doubleclick.net/gampad/clk?id=48897511&iu=/4140/ostg.clktrk
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel