public class TaskanaEngineImpl extends Object implements TaskanaEngine
TaskanaEngine.ConnectionManagementMode| Modifier and Type | Field and Description |
|---|---|
protected Connection |
connection |
protected TaskanaEngine.ConnectionManagementMode |
mode |
protected org.apache.ibatis.session.SqlSessionManager |
sessionManager |
protected TaskanaEngineConfiguration |
taskanaEngineConfiguration |
protected org.apache.ibatis.transaction.TransactionFactory |
transactionFactory |
| Modifier | Constructor and Description |
|---|---|
protected |
TaskanaEngineImpl(TaskanaEngineConfiguration taskanaEngineConfiguration) |
| Modifier and Type | Method and Description |
|---|---|
void |
checkRoleMembership(TaskanaRole... roles)
Checks whether current user is member of any of the specified roles.
|
void |
closeConnection()
Closes the client's connection, sets it to null and switches to mode PARTICIPATE.
|
protected org.apache.ibatis.session.SqlSessionManager |
createSqlSessionManager()
This method creates the sqlSessionManager of myBatis.
|
static TaskanaEngine |
createTaskanaEngine(TaskanaEngineConfiguration taskanaEngineConfiguration) |
ClassificationService |
getClassificationService()
The ClassificationService can be used for operations on all Categories.
|
TaskanaEngineConfiguration |
getConfiguration()
The Taskana configuration.
|
JobService |
getJobService()
The JobService can be user for all job operations.
|
MonitorService |
getMonitorService()
The MonitorService can be used for monitoring Tasks.
|
TaskService |
getTaskService()
The TaskService can be used for operations on all Tasks.
|
WorkbasketService |
getWorkbasketService()
The WorkbasketService can be used for operations on all Workbaskets.
|
WorkingDaysToDaysConverter |
getWorkingDaysToDaysConverter()
The WorkingDaysToDaysConverter used to compute holidays.
|
boolean |
isHistoryEnabled()
Checks if the history plugin is enabled.
|
boolean |
isUserInRole(TaskanaRole... roles)
check whether the current user is member of one of the roles specified.
|
void |
setConnection(Connection connection)
Set the connection to be used by taskana in mode CONNECTION_MANAGED_EXTERNALLY.
|
void |
setConnectionManagementMode(TaskanaEngine.ConnectionManagementMode mode)
sets the connection management mode.
|
protected TaskanaEngineConfiguration taskanaEngineConfiguration
protected org.apache.ibatis.transaction.TransactionFactory transactionFactory
protected org.apache.ibatis.session.SqlSessionManager sessionManager
protected TaskanaEngine.ConnectionManagementMode mode
protected Connection connection
protected TaskanaEngineImpl(TaskanaEngineConfiguration taskanaEngineConfiguration)
public static TaskanaEngine createTaskanaEngine(TaskanaEngineConfiguration taskanaEngineConfiguration)
public TaskService getTaskService()
TaskanaEnginegetTaskService in interface TaskanaEnginepublic MonitorService getMonitorService()
TaskanaEnginegetMonitorService in interface TaskanaEnginepublic WorkbasketService getWorkbasketService()
TaskanaEnginegetWorkbasketService in interface TaskanaEnginepublic ClassificationService getClassificationService()
TaskanaEnginegetClassificationService in interface TaskanaEnginepublic JobService getJobService()
TaskanaEnginegetJobService in interface TaskanaEnginepublic TaskanaEngineConfiguration getConfiguration()
TaskanaEnginegetConfiguration in interface TaskanaEnginepublic WorkingDaysToDaysConverter getWorkingDaysToDaysConverter()
TaskanaEnginegetWorkingDaysToDaysConverter in interface TaskanaEnginepublic boolean isHistoryEnabled()
TaskanaEngineisHistoryEnabled in interface TaskanaEnginepublic void setConnectionManagementMode(TaskanaEngine.ConnectionManagementMode mode)
TaskanaEnginesetConnectionManagementMode in interface TaskanaEnginemode - the connection management mode Valid values are:
public void setConnection(Connection connection) throws SQLException
TaskanaEnginesetConnection in interface TaskanaEngineconnection - - The java.sql.Connection that is controlled by the clientSQLException - if a database access error occurspublic void closeConnection()
TaskanaEnginecloseConnection in interface TaskanaEnginepublic boolean isUserInRole(TaskanaRole... roles)
TaskanaEngineisUserInRole in interface TaskanaEngineroles - The roles that are checked for membership of the current userpublic void checkRoleMembership(TaskanaRole... roles) throws NotAuthorizedException
TaskanaEnginecheckRoleMembership in interface TaskanaEngineroles - The roles that are checked for membership of the current userNotAuthorizedException - If the current user is not member of any specified roleprotected org.apache.ibatis.session.SqlSessionManager createSqlSessionManager()
SqlSessionFactoryCopyright © 2020. All rights reserved.