| Modifier and Type | Method and Description |
|---|---|
| public void | addTimerTask(TimerTask
timer task to schedule timerTask, long delay in milliseconds milliSeconds)Schedule a TimerTask for later execution. |
| public boolean | Returns: True for binary transfer, false for text transfer.The oid to check. oid)Returns true if value for the given oid should be sent using binary transfer. |
| public void | cancelQuery()
Redeclares org. Cancel the current query executing on this connection. |
| public CachedQuery | |
| public @PolyNull byte[] | Returns: an encoded representation of the stringthe string to encode str)Encode a string using the database's client_encoding (usually UTF8, but can vary on older server versions). |
| public String | Returns: the escaped representation of the stringa string value str)Escapes a string for use as string-literal within an SQL command. |
| public ResultSet | Returns: the (non-null) returned resultsetthe query to execute s)Execute a SQL query that returns a single resultset. |
| public ResultSet | |
| public void | |
| public Encoding | |
| public LruCache | |
| public Logger | |
| public boolean | Returns: true if should be included and passed on to other exceptionsIndicates if error details from server used in included in logging and exceptions. |
| public Object | Returns: an appropriate object; never null.the backend typename type, @Nullable String the type-specific string representation of the value value, @Nullable byte[] the type-specific binary representation of the value byteValue)Construct and return an appropriate object for the given type and value. |
| public QueryExecutor | Returns: the (non-null) executorGet the QueryExecutor implementation for this connection. |
| public ReplicationProtocol | Returns: not null replication protocolInternal protocol for work with physical and logical replication. |
| public boolean | Returns: true if the server treats string literals according to the SQL standardReturns whether the server treats string-literals according to the SQL standard or if it uses traditional PostgreSQL escaping rules. |
| public boolean | |
| public TimestampUtils | |
| public TransactionState | Returns: current transaction state of this connectionGet the current transaction state of this connection. |
| public TypeInfo | |
| public PGXmlFactoryFactory | Returns: The factory to use to instantiate XML processing factoriesRetrieve the factory to instantiate XML processing factories. |
| public boolean | Returns: true if the server version is at least "ver".the server version to check, of the form xxyyzz eg 90401 ver)Check if we have at least a particular server version. |
| public boolean | Returns: true if the server version is at least "ver".the server version to check ver)Check if we have at least a particular server version. |
| public boolean | Returns: Indication if hints to backend (such as when transaction begins) should be read only.Indicates if statements to backend should be hinted as read only. |
| public boolean | Returns: true column sanitizer is disabledReturn whether to disable column name sanitation. |
| public void | purgeTimerTasks()
Invoke purge() on the underlying shared Timer so that internal resources will be released. |
| public void | setFlushCacheOnDeallocate(boolean
true if statement cache should be reset when "deallocate/discard" message observed flushCacheOnDeallocate)By default, the connection resets statement cache in case deallocate all/discard all message is observed. |
| addTimerTask | back to summary |
|---|---|
| public void addTimerTask(TimerTask timerTask, long milliSeconds) Schedule a TimerTask for later execution. The task will be scheduled with the shared Timer for this connection.
| |
| binaryTransferSend | back to summary |
|---|---|
| public boolean binaryTransferSend(int oid) Returns true if value for the given oid should be sent using binary transfer. False if value should be sent using text transfer.
| |
| cancelQuery | back to summary |
|---|---|
| public void cancelQuery() throws SQLException Redeclares org. Cancel the current query executing on this connection.
| |
| createQuery | back to summary |
|---|---|
| public CachedQuery createQuery(String sql, boolean escapeProcessing, boolean isParameterized, String... columnNames) throws SQLException | |
| encodeString | back to summary |
|---|---|
| public @PolyNull byte[] encodeString(@PolyNull String str) throws SQLException Encode a string using the database's client_encoding (usually UTF8, but can vary on older server versions). This is used when constructing synthetic resultsets (for example, in metadata methods).
| |
| escapeString | back to summary |
|---|---|
| public String escapeString(String str) throws SQLException Escapes a string for use as string-literal within an SQL command. The method chooses the
applicable escaping rules based on the value of
| |
| execSQLQuery | back to summary |
|---|---|
| public ResultSet execSQLQuery(String s) throws SQLException Execute a SQL query that returns a single resultset. Never causes a new transaction to be started regardless of the autocommit setting.
| |
| execSQLQuery | back to summary |
|---|---|
| public ResultSet execSQLQuery(String s, int resultSetType, int resultSetConcurrency) throws SQLException | |
| execSQLUpdate | back to summary |
|---|---|
| public void execSQLUpdate(String s) throws SQLException Execute a SQL query that does not return results. Never causes a new transaction to be started regardless of the autocommit setting.
| |
| getEncoding | back to summary |
|---|---|
public Encoding getEncoding() throws SQLException
| |
| getFieldMetadataCache | back to summary |
|---|---|
| public LruCache Return metadata cache for given connection.
| |
| getLogger | back to summary |
|---|---|
| public Logger getLogger() | |
| getLogServerErrorDetail | back to summary |
|---|---|
| public boolean getLogServerErrorDetail() Indicates if error details from server used in included in logging and exceptions.
| |
| getObject | back to summary |
|---|---|
| public Object getObject(String type, @Nullable String value, @Nullable byte[] byteValue) throws SQLException Construct and return an appropriate object for the given type and value. This only considers
the types registered via If no class is registered as handling the given type, then a generic
value or byteValue must be non-null | |
| getQueryExecutor | back to summary |
|---|---|
| public QueryExecutor getQueryExecutor() Get the QueryExecutor implementation for this connection.
| |
| getReplicationProtocol | back to summary |
|---|---|
| public ReplicationProtocol getReplicationProtocol() Internal protocol for work with physical and logical replication. Physical replication available only since PostgreSQL version 9.1. Logical replication available only since PostgreSQL version 9.4.
| |
| getStandardConformingStrings | back to summary |
|---|---|
| public boolean getStandardConformingStrings() Returns whether the server treats string-literals according to the SQL standard or if it uses
traditional PostgreSQL escaping rules. Versions up to 8.1 always treated backslashes as escape
characters in string-literals. Since 8.2, this depends on the value of the
| |
| getStringVarcharFlag | back to summary |
|---|---|
| public boolean getStringVarcharFlag() | |
| getTimestampUtils | back to summary |
|---|---|
| public TimestampUtils getTimestampUtils()
Deprecated
| |
| getTransactionState | back to summary |
|---|---|
| public TransactionState getTransactionState() Get the current transaction state of this connection.
| |
| getTypeInfo | back to summary |
|---|---|
| public TypeInfo getTypeInfo() | |
| getXmlFactoryFactory | back to summary |
|---|---|
| public PGXmlFactoryFactory getXmlFactoryFactory() throws SQLException Retrieve the factory to instantiate XML processing factories.
| |
| haveMinimumServerVersion | back to summary |
|---|---|
| public boolean haveMinimumServerVersion(int ver) Check if we have at least a particular server version. The input version is of the form xxyyzz, matching a PostgreSQL version like xx.yy.zz. So 9.0.12 is 90012.
| |
| haveMinimumServerVersion | back to summary |
|---|---|
| public boolean haveMinimumServerVersion(Version ver) Check if we have at least a particular server version. The input version is of the form xxyyzz, matching a PostgreSQL version like xx.yy.zz. So 9.0.12 is 90012.
| |
| hintReadOnly | back to summary |
|---|---|
| public boolean hintReadOnly() Indicates if statements to backend should be hinted as read only.
| |
| isColumnSanitiserDisabled | back to summary |
|---|---|
| public boolean isColumnSanitiserDisabled() Return whether to disable column name sanitation.
| |
| purgeTimerTasks | back to summary |
|---|---|
| public void purgeTimerTasks() Invoke purge() on the underlying shared Timer so that internal resources will be released. | |
| setFlushCacheOnDeallocate | back to summary |
|---|---|
| public void setFlushCacheOnDeallocate(boolean flushCacheOnDeallocate) By default, the connection resets statement cache in case deallocate all/discard all message is observed. This API allows to disable that feature for testing purposes.
| |