mirror of
https://github.com/postgres/postgres.git
synced 2025-08-28 18:48:04 +03:00
Cleanup and reorganization.
- Added a private api layer (org.postgresql.core.Base*) - Cleaned up public api (org.postgresql.PG*) - Added consistent headers and copywrite info - Removed deprecated Serialize functionality - Cleaned up imports - Moved some files to more appropriate locations Modified Files: jdbc/org/postgresql/Driver.java.in jdbc/org/postgresql/PGConnection.java jdbc/org/postgresql/PGNotification.java jdbc/org/postgresql/PGStatement.java jdbc/org/postgresql/core/Encoding.java jdbc/org/postgresql/core/Notification.java jdbc/org/postgresql/core/QueryExecutor.java jdbc/org/postgresql/core/StartupPacket.java jdbc/org/postgresql/fastpath/Fastpath.java jdbc/org/postgresql/fastpath/FastpathArg.java jdbc/org/postgresql/geometric/PGbox.java jdbc/org/postgresql/geometric/PGcircle.java jdbc/org/postgresql/geometric/PGline.java jdbc/org/postgresql/geometric/PGlseg.java jdbc/org/postgresql/geometric/PGpath.java jdbc/org/postgresql/geometric/PGpoint.java jdbc/org/postgresql/geometric/PGpolygon.java jdbc/org/postgresql/jdbc1/AbstractJdbc1Connection.java jdbc/org/postgresql/jdbc1/AbstractJdbc1DatabaseMetaData.java jdbc/org/postgresql/jdbc1/AbstractJdbc1ResultSet.java jdbc/org/postgresql/jdbc1/AbstractJdbc1ResultSetMetaData.java jdbc/org/postgresql/jdbc1/AbstractJdbc1Statement.java jdbc/org/postgresql/jdbc1/Jdbc1CallableStatement.java jdbc/org/postgresql/jdbc1/Jdbc1Connection.java jdbc/org/postgresql/jdbc1/Jdbc1DatabaseMetaData.java jdbc/org/postgresql/jdbc1/Jdbc1PreparedStatement.java jdbc/org/postgresql/jdbc1/Jdbc1ResultSet.java jdbc/org/postgresql/jdbc1/Jdbc1ResultSetMetaData.java jdbc/org/postgresql/jdbc1/Jdbc1Statement.java jdbc/org/postgresql/jdbc2/AbstractJdbc2Blob.java jdbc/org/postgresql/jdbc2/AbstractJdbc2Clob.java jdbc/org/postgresql/jdbc2/AbstractJdbc2Connection.java jdbc/org/postgresql/jdbc2/AbstractJdbc2DatabaseMetaData.java jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSetMetaData.java jdbc/org/postgresql/jdbc2/AbstractJdbc2Statement.java jdbc/org/postgresql/jdbc2/Array.java jdbc/org/postgresql/jdbc2/Jdbc2CallableStatement.java jdbc/org/postgresql/jdbc2/Jdbc2Connection.java jdbc/org/postgresql/jdbc2/Jdbc2PreparedStatement.java jdbc/org/postgresql/jdbc2/Jdbc2ResultSet.java jdbc/org/postgresql/jdbc2/Jdbc2ResultSetMetaData.java jdbc/org/postgresql/jdbc2/Jdbc2Statement.java jdbc/org/postgresql/jdbc3/AbstractJdbc3ResultSet.java jdbc/org/postgresql/jdbc3/Jdbc3CallableStatement.java jdbc/org/postgresql/jdbc3/Jdbc3Connection.java jdbc/org/postgresql/jdbc3/Jdbc3PreparedStatement.java jdbc/org/postgresql/jdbc3/Jdbc3ResultSet.java jdbc/org/postgresql/jdbc3/Jdbc3ResultSetMetaData.java jdbc/org/postgresql/jdbc3/Jdbc3Statement.java jdbc/org/postgresql/largeobject/BlobInputStream.java jdbc/org/postgresql/largeobject/BlobOutputStream.java jdbc/org/postgresql/largeobject/LargeObject.java jdbc/org/postgresql/largeobject/LargeObjectManager.java jdbc/org/postgresql/test/jdbc2/Jdbc2TestSuite.java jdbc/org/postgresql/test/jdbc2/optional/BaseDataSourceTest.java jdbc/org/postgresql/util/MD5Digest.java jdbc/org/postgresql/util/MessageTranslator.java jdbc/org/postgresql/util/PGbytea.java jdbc/org/postgresql/util/PGmoney.java jdbc/org/postgresql/util/PGobject.java jdbc/org/postgresql/util/PGtokenizer.java jdbc/org/postgresql/util/PSQLException.java jdbc/org/postgresql/util/UnixCrypt.java Added Files: jdbc/org/postgresql/core/BaseConnection.java jdbc/org/postgresql/core/BaseResultSet.java jdbc/org/postgresql/core/BaseStatement.java jdbc/org/postgresql/core/Field.java jdbc/org/postgresql/core/PGStream.java Removed Files: jdbc/org/postgresql/Field.java jdbc/org/postgresql/PG_Stream.java jdbc/org/postgresql/test/jdbc2/SerializeObject.java jdbc/org/postgresql/test/jdbc2/SerializeTest.java jdbc/org/postgresql/util/Serialize.java
This commit is contained in:
@@ -1,3 +1,18 @@
|
||||
/*-------------------------------------------------------------------------
|
||||
*
|
||||
* PGConnection.java
|
||||
* The public interface definition for a Postgresql Connection
|
||||
* This interface defines PostgreSQL extentions to the java.sql.Connection
|
||||
* interface. Any java.sql.Connection object returned by the driver will
|
||||
* also implement this interface
|
||||
*
|
||||
* Copyright (c) 2003, PostgreSQL Global Development Group
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/interfaces/jdbc/org/postgresql/Attic/PGConnection.java,v 1.4 2003/03/07 18:39:41 barry Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
package org.postgresql;
|
||||
|
||||
import java.sql.*;
|
||||
@@ -7,75 +22,46 @@ import org.postgresql.core.Encoding;
|
||||
import org.postgresql.fastpath.Fastpath;
|
||||
import org.postgresql.largeobject.LargeObjectManager;
|
||||
|
||||
/* $Header: /cvsroot/pgsql/src/interfaces/jdbc/org/postgresql/Attic/PGConnection.java,v 1.3 2002/09/06 21:23:05 momjian Exp $
|
||||
* This interface defines PostgreSQL extentions to the java.sql.Connection interface.
|
||||
* Any java.sql.Connection object returned by the driver will also implement this
|
||||
* interface
|
||||
*/
|
||||
public interface PGConnection
|
||||
{
|
||||
/*
|
||||
* Get the character encoding to use for this connection.
|
||||
*/
|
||||
public Encoding getEncoding() throws SQLException;
|
||||
|
||||
/*
|
||||
* This method returns the java.sql.Types type for a postgres datatype name
|
||||
*/
|
||||
public int getSQLType(String pgTypeName) throws SQLException;
|
||||
|
||||
/*
|
||||
* This returns the java.sql.Types type for a postgres datatype OID
|
||||
*/
|
||||
public int getSQLType(int oid) throws SQLException;
|
||||
|
||||
/*
|
||||
* This returns the postgres datatype name from the
|
||||
* postgres datatype OID
|
||||
*/
|
||||
public String getPGType(int oid) throws SQLException;
|
||||
|
||||
/*
|
||||
* This returns the postgres datatype OID from the
|
||||
* postgres datatype name
|
||||
*/
|
||||
public int getPGType(String typeName) throws SQLException;
|
||||
|
||||
/*
|
||||
* This returns the LargeObject API for the current connection.
|
||||
*/
|
||||
public LargeObjectManager getLargeObjectAPI() throws SQLException;
|
||||
|
||||
/*
|
||||
* This returns the Fastpath API for the current connection.
|
||||
*/
|
||||
public Fastpath getFastpathAPI() throws SQLException;
|
||||
|
||||
/*
|
||||
* This method is used internally to return an object based around
|
||||
* org.postgresql's more unique data types.
|
||||
*
|
||||
* <p>It uses an internal Hashtable to get the handling class. If the
|
||||
* type is not supported, then an instance of org.postgresql.util.PGobject
|
||||
* is returned.
|
||||
*
|
||||
* You can use the getValue() or setValue() methods to handle the returned
|
||||
* object. Custom objects can have their own methods.
|
||||
*
|
||||
* @return PGobject for this type, and set to value
|
||||
* @exception SQLException if value is not correct for this type
|
||||
* @see org.postgresql.util.Serialize
|
||||
*/
|
||||
public Object getObject(String type, String value) throws SQLException;
|
||||
|
||||
|
||||
/*
|
||||
/**
|
||||
* This method returns any notifications that have been received
|
||||
* since the last call to this method.
|
||||
* Returns null if there have been no notifications.
|
||||
* @since 7.3
|
||||
*/
|
||||
public PGNotification[] getNotifications();
|
||||
|
||||
/**
|
||||
* This returns the LargeObject API for the current connection.
|
||||
* @since 7.3
|
||||
*/
|
||||
public LargeObjectManager getLargeObjectAPI() throws SQLException;
|
||||
|
||||
/**
|
||||
* This returns the Fastpath API for the current connection.
|
||||
* @since 7.3
|
||||
*/
|
||||
public Fastpath getFastpathAPI() throws SQLException;
|
||||
|
||||
|
||||
/** @deprecated */
|
||||
public Encoding getEncoding() throws SQLException;
|
||||
|
||||
/** @deprecated */
|
||||
public int getSQLType(String pgTypeName) throws SQLException;
|
||||
|
||||
/** @deprecated */
|
||||
public int getSQLType(int oid) throws SQLException;
|
||||
|
||||
/** @deprecated */
|
||||
public String getPGType(int oid) throws SQLException;
|
||||
|
||||
/** @deprecated */
|
||||
public int getPGType(String typeName) throws SQLException;
|
||||
|
||||
/** @deprecated */
|
||||
public Object getObject(String type, String value) throws SQLException;
|
||||
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user