Class MySQLFeatureWriter

All Implemented Interfaces:

public class MySQLFeatureWriter
extends JDBCTextFeatureWriter

Feature writer handling specific geometric function from MySQL 4.1 TODO This ought to handle MySQL 4.1's geometric datatypes, but it does not work. This is because 4.1 sends geometric data in a different packet format than other datatypes, and because of this the MySQL driver does not allow ResultSet objects with geometric data to be updatable. I have not found anything about this MySQL bug in the MySQL bug database, so I will add a new bug there. In the meantime, this package should work fine for writing non-geometric data.

Gary Sheppard, wolf, Gary Sheppard

Field Summary
Fields inherited from class
closed, current, fidAttributes, listenerManager, live, queryData, reader
Constructor Summary
MySQLFeatureWriter(FeatureReader fReader, QueryData queryData)
Method Summary
protected  java.lang.String getGeometryInsertText(com.vividsolutions.jts.geom.Geometry geom, int srid)
          Turns a geometry into the textual version needed for the sql statement
Methods inherited from class
addQuotes, doInsert, doUpdate, encodeColumnName, encodeName, makeDeleteSql, makeInsertSql, makeUpdateSql, remove, useQueryDataForInsert
Methods inherited from class
close, getFeatureType, hasNext, next, write
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public MySQLFeatureWriter(FeatureReader fReader,
                          QueryData queryData)
Method Detail


protected java.lang.String getGeometryInsertText(com.vividsolutions.jts.geom.Geometry geom,
                                                 int srid)
Description copied from class: JDBCTextFeatureWriter
Turns a geometry into the textual version needed for the sql statement

Specified by:
getGeometryInsertText in class JDBCTextFeatureWriter
geom -
srid -
See Also:
JDBCTextFeatureWriter.getGeometryInsertText(com.vividsolutions.jts.geom.Geometry, int)

Copyright © GeoTools. All Rights Reserved.