Package org.postgis
Class DriverWrapperLW
- java.lang.Object
-
- org.postgresql.Driver
-
- org.postgis.DriverWrapper
-
- org.postgis.DriverWrapperLW
-
- All Implemented Interfaces:
Driver
public class DriverWrapperLW extends DriverWrapper
DriverWrapperLW Wraps the PostGreSQL Driver to transparently add the PostGIS Object Classes. This avoids the need of explicit addDataType() calls from the driver users side. This DriverWrapper subclass always uses hex encoded EWKB as canonical text representation, and thus only works against PostGIS 1.x servers and newer. For usage notes, see DriverWrapper class, but use "jdbc:postgresql_lwgis:" as JDBC url prefix and org.postgis.DriverWrapperLW as driver class.- Author:
- Markus Schaber <[email protected]>
- See Also:
DriverWrapper
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.postgis.DriverWrapper
DriverWrapper.TypesAdder, DriverWrapper.TypesAdder72, DriverWrapper.TypesAdder74, DriverWrapper.TypesAdder80
-
-
Field Summary
Fields Modifier and Type Field Description static StringPOSTGIS_LWPROTOCOLstatic StringREVISIONLW-
Fields inherited from class org.postgis.DriverWrapper
logger, POSTGIS_PROTOCOL, POSTGRES_PROTOCOL, REVISION, ta72, ta74, ta80, typesAdder
-
-
Constructor Summary
Constructors Constructor Description DriverWrapperLW()Default constructor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected StringgetProtoString()static StringgetVersion()Returns our own CVS version plus postgres Versionprotected booleanuseLW(Connection result)Do we have HexWKB as well known text representation - to be overridden by subclasses.-
Methods inherited from class org.postgis.DriverWrapper
acceptsURL, addGISTypes, addGISTypes72, addGISTypes80, connect, getParentLogger, getTypesAdder, mangleURL
-
-
-
-
Field Detail
-
POSTGIS_LWPROTOCOL
public static final String POSTGIS_LWPROTOCOL
- See Also:
- Constant Field Values
-
REVISIONLW
public static final String REVISIONLW
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
DriverWrapperLW
public DriverWrapperLW() throws SQLExceptionDefault constructor.- Throws:
SQLException- when a SQLException occurs
-
-
Method Detail
-
getProtoString
protected String getProtoString()
- Overrides:
getProtoStringin classDriverWrapper
-
useLW
protected boolean useLW(Connection result)
Description copied from class:DriverWrapperDo we have HexWKB as well known text representation - to be overridden by subclasses.- Overrides:
useLWin classDriverWrapper- Parameters:
result- Connection to check- Returns:
- true if using EWKB, false otherwise
-
getVersion
public static String getVersion()
Returns our own CVS version plus postgres Version- Returns:
- String value reprenstation of the version
-
-