public abstract class AbstractDbManager
extends java.lang.Object
Offers an interface to generate instance capable of holding attitudes to manage a database connection.
Modifier and Type | Class and Description |
---|---|
static class |
AbstractDbManager.ExcCheckType |
Modifier and Type | Field and Description |
---|---|
ConfigFile |
m_configuration |
protected int |
m_derivedCode
m_derivedCode must receive a value in the descendant of this
class. |
ErrorCarrier |
m_errorCarrier |
Constructor and Description |
---|
AbstractDbManager() |
Modifier and Type | Method and Description |
---|---|
boolean |
dbExceptionCheck(java.sql.SQLException e,
AbstractDbManager.ExcCheckType exceptionCheckType) |
abstract boolean |
dbExceptionCheck(java.lang.String textToInspect,
java.lang.String code,
AbstractDbManager.ExcCheckType exceptionCheckType)
Must return true if the exception of the assigned type is detected.
|
int |
derivedCode() |
long |
getId(java.lang.String sql) |
java.lang.String |
getIdGeneratorSql(java.lang.String sequenceName) |
boolean |
validate(java.lang.String expr) |
public ErrorCarrier m_errorCarrier
public ConfigFile m_configuration
protected int m_derivedCode
m_derivedCode
must receive a value in the descendant of this
class. This member is thought to have some role at application semantic
level so that all the framework messenger methods can be customized
(overridden) in their behavior depending on the value of it. It is a
vehicle from the context in which an exception is analyzed to the context
in which the corresponding message to the user is built and chosen,
nothing else.public int derivedCode()
public boolean dbExceptionCheck(java.sql.SQLException e, AbstractDbManager.ExcCheckType exceptionCheckType)
public abstract boolean dbExceptionCheck(java.lang.String textToInspect, java.lang.String code, AbstractDbManager.ExcCheckType exceptionCheckType)
textToInspect
- the text target of the analysis dedicated to catch some significant pattern to make the decisioncode
- the error codeexceptionCheckType
- the type of exception which the check is made forpublic long getId(java.lang.String sql)
public java.lang.String getIdGeneratorSql(java.lang.String sequenceName)
public boolean validate(java.lang.String expr)