} else if ( particleMapping instanceof GeometryMapping ) { GeometryMapping gm = (GeometryMapping) particleMapping; ParticleConverter<?> converter = getGeometryConverter( gm ); particleMappingToConverter.put( particleMapping, converter ); } else if ( particleMapping instanceof FeatureMapping ) {
@Override public PropertyNameMapping getMapping( ValueReference propName, TableAliasManager aliasManager ) throws FilterEvaluationException, UnmappableException { GeometryStorageParams geometryParams = new GeometryStorageParams( blobMapping.getCRS(), undefinedSrid, CoordinateDimension.DIM_2 ); GeometryMapping bboxMapping = new GeometryMapping( null, false, new DBField( blobMapping.getBBoxColumn() ), GeometryType.GEOMETRY, geometryParams, null ); return new PropertyNameMapping( getGeometryConverter( bboxMapping ), null, blobMapping.getBBoxColumn(), aliasManager.getRootTableAlias() ); }
/** * Creates a new {@link SQLFeatureStoreTransaction} instance. * * @param store * corresponding feature store instance, must not be <code>null</code> * @param conn * JDBC connection associated with the transaction, must not be <code>null</code> and have * <code>autocommit</code> set to <code>false</code> * @param schema * application schema with mapping information, must not be <code>null</code> * @param inspectors * feature inspectors, must not be <code>null</code> */ SQLFeatureStoreTransaction( SQLFeatureStore store, Connection conn, MappedAppSchema schema, List<FeatureInspector> inspectors ) { this.fs = store; this.conn = conn; this.schema = schema; this.inspectors = inspectors; blobMapping = schema.getBlobMapping(); if ( blobMapping != null ) { DBField bboxColumn = new DBField( blobMapping.getBBoxColumn() ); GeometryStorageParams geometryParams = new GeometryStorageParams( blobMapping.getCRS(), null, DIM_2 ); GeometryMapping blobGeomMapping = new GeometryMapping( null, true, bboxColumn, GeometryType.GEOMETRY, geometryParams, null ); blobGeomConverter = fs.getGeometryConverter( blobGeomMapping ); } this.bboxTracker = new BBoxTracker(); }