org.firebirdsql.jdbc
Class AbstractSavepoint
java.lang.Object
|
+--org.firebirdsql.jdbc.AbstractSavepoint
- All Implemented Interfaces:
- FirebirdSavepoint
- public abstract class AbstractSavepoint
- extends java.lang.Object
- implements FirebirdSavepoint
Implementation of the FirebirdSavepoint
interface. Subclasses might additionally implement java.sql.Savepoint
interface.
Constructor Summary |
AbstractSavepoint(int id)
Create instance of this class. |
AbstractSavepoint(java.lang.String name)
Create instance of this class for the specified name. |
Method Summary |
boolean |
equals(java.lang.Object obj)
Check if objects are equal. |
int |
getSavepointId()
Get ID of the savepoint. |
java.lang.String |
getSavepointName()
Get name of the savepoint. |
int |
hashCode()
Get hash code of this instance. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
SAVEPOINT_ID_PREFIX
public static final java.lang.String SAVEPOINT_ID_PREFIX
AbstractSavepoint
public AbstractSavepoint(int id)
- Create instance of this class.
- Parameters:
id
- ID of the savepoint.
AbstractSavepoint
public AbstractSavepoint(java.lang.String name)
- Create instance of this class for the specified name.
- Parameters:
name
- name of the savepoint.
getSavepointId
public int getSavepointId()
throws java.sql.SQLException
- Get ID of the savepoint.
- Specified by:
getSavepointId
in interface FirebirdSavepoint
- Following copied from interface:
org.firebirdsql.jdbc.FirebirdSavepoint
- Returns:
- the numeric ID of this savepoint
- Throws:
java.sql.SQLException
- if this is a named savepoint
getSavepointName
public java.lang.String getSavepointName()
throws java.sql.SQLException
- Get name of the savepoint.
- Specified by:
getSavepointName
in interface FirebirdSavepoint
- Following copied from interface:
org.firebirdsql.jdbc.FirebirdSavepoint
- Returns:
- the name of this savepoint
- Throws:
java.sql.SQLException
- if this is an un-named savepoint
equals
public boolean equals(java.lang.Object obj)
- Check if objects are equal. For unnamed savepoints their IDs are checked,
otherwise their names.
- Overrides:
equals
in class java.lang.Object
- Parameters:
obj
- object to test.- Returns:
true
if obj
is equal to this object.
hashCode
public int hashCode()
- Get hash code of this instance.
- Overrides:
hashCode
in class java.lang.Object
Copyright © 2001 David Jencks and other authors. All rights reserved.