com.jfw.database.mysql
Class GetLastSequenceIdDB

java.lang.Object
  extended by com.jfw.database.mysql.GetLastSequenceIdDB

public final class GetLastSequenceIdDB
extends java.lang.Object

Get the last autoincrement value from a given connection.


Constructor Summary
GetLastSequenceIdDB(java.sql.Connection connection)
          Set attribute connection.
GetLastSequenceIdDB(QueryGateway queryGateway)
          Set attribute queryGateway.
 
Method Summary
 java.lang.String getId()
          Get the last autoincrement value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GetLastSequenceIdDB

public GetLastSequenceIdDB(java.sql.Connection connection)
Set attribute connection.

Parameters:
connection - the Connection to use.

GetLastSequenceIdDB

public GetLastSequenceIdDB(QueryGateway queryGateway)
Set attribute queryGateway.

Parameters:
queryGateway - the QueryGateway to use.
Method Detail

getId

public java.lang.String getId()
                       throws java.lang.Exception
Get the last autoincrement value.

Returns:
the last autoincrement value
Throws:
java.lang.Exception