2.17.2: 2011-06-17

net.sf.basedb.core.log
Class TransactionDetails

java.lang.Object
  extended by net.sf.basedb.core.log.TransactionDetails

public class TransactionDetails
extends Object

Holds information about the curren transaction, such as the logged in user, the active project, the plug-in that is executing, etc.

Version:
2.13
Author:
Nicklas
Last modified
$Date: 2009-08-07 12:50:01 +0200 (Fri, 07 Aug 2009) $

Field Summary
private  int clientId
           
private  int jobId
           
private  int pluginId
           
private  int projectId
           
private  int sessionId
           
private  int userId
           
 
Constructor Summary
TransactionDetails(SessionControl sc)
          Creates a new transaction details object with information from given session control
 
Method Summary
 int getClientId()
          Get the ID of the client appliction that is used, or 0 if not known.
 int getJobId()
          Get the ID of the currently running job or 0 if no job is running.
 int getPluginId()
          Get the ID of the currently running plug-in or 0 if no plug-in is running.
 int getProjectId()
          Get the ID of the currently active project, or 0 if no project is active.
 int getSessionId()
          Get the ID of the session or 0 if no user is logged in.
 int getUserId()
          Get the ID of the currently logged in user, or 0 if no user is logged in.
 ChangeHistoryData toChangeHistoryData()
          Convert the information about the transaction to a ChangeHistoryData object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

userId

private final int userId

sessionId

private final int sessionId

clientId

private final int clientId

projectId

private final int projectId

pluginId

private final int pluginId

jobId

private final int jobId
Constructor Detail

TransactionDetails

public TransactionDetails(SessionControl sc)
Creates a new transaction details object with information from given session control

Method Detail

getUserId

public int getUserId()
Get the ID of the currently logged in user, or 0 if no user is logged in.


getSessionId

public int getSessionId()
Get the ID of the session or 0 if no user is logged in.


getClientId

public int getClientId()
Get the ID of the client appliction that is used, or 0 if not known.


getProjectId

public int getProjectId()
Get the ID of the currently active project, or 0 if no project is active.


getPluginId

public int getPluginId()
Get the ID of the currently running plug-in or 0 if no plug-in is running.


getJobId

public int getJobId()
Get the ID of the currently running job or 0 if no job is running.


toChangeHistoryData

public ChangeHistoryData toChangeHistoryData()
Convert the information about the transaction to a ChangeHistoryData object.

Returns:
A ChangeHistoryData object

2.17.2: 2011-06-17