java.lang.Objectorg.objectweb.telosys.common.TelosysObject
org.objectweb.telosys.screen.core.StandardScreenCommon
org.objectweb.telosys.screen.core.StandardScreenManager
Standard implementation for the ScreenManager interface
Abstract class designed to be specialized for each screen
Field Summary | |
protected static int |
DEFAULT_DATABASE
|
protected static int |
NO_DATABASE
|
Constructor Summary | |
StandardScreenManager(java.lang.Class screenDataClass)
Constructor for default database |
|
StandardScreenManager(java.lang.Class screenDataClass,
int iDatabaseId)
Constructor for specific database |
Method Summary | |
abstract void |
delete(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Implementation of the "delete" action |
void |
doDelete(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Entry point for "delete" action |
void |
doInit(ScreenData screenData,
ScreenContext screenContext,
java.util.Map param,
DatabaseSession dbSession)
|
void |
doInsert(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Entry point for "insert" action |
void |
doLoad(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Entry point for "load" action |
void |
doSave(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Entry point for "save" action |
void |
doUpdate(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Entry point for "update" action |
void |
eventCreate(ScreenContext screenContext,
ScreenRequestParameters params,
ScreenSession screenSession,
DatabaseSession dbSession)
Entry point for a "create event", origin : ScreenContextManager ("open" or "use" and not found) |
void |
eventReuse(ScreenContext screenContext,
ScreenRequestParameters params,
ScreenSession screenSession,
DatabaseSession dbSession)
Entry point for a "reuse event", origin : ScreenContextManager ("use" and found) |
protected StandardDAO |
getDAO(java.lang.Class beanClass)
Returns the DAO for the given bean class and the default database |
protected StandardDAO |
getDAO(java.lang.Class beanClass,
DatabaseSession dbSession)
Returns the DAO for the given bean class and db session |
protected StandardDAO |
getDAO(java.lang.Class beanClass,
int iDatabaseId)
Returns the DAO for the given bean class and db id |
int |
getDatabaseId()
Returns the Database Id used by the ScreenManager . 0 to N : the Databse Id specified . |
DatabaseSession |
getDatabaseSession()
Returns a new DatabaseSession instance corresponding to the DatabaseId associated with the current screen context. |
protected ScreenApplication |
getScreenApplication()
Returns the ScreenApplication object |
protected javax.servlet.ServletContext |
getServletContext()
Returns the ServletContext object |
void |
init(ScreenData screenData,
ScreenContext context,
java.util.Map parameters,
DatabaseSession dbSession)
Deprecated. |
abstract void |
insert(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Implementation of the "insert" action |
abstract void |
load(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Implementation of the "load" action |
void |
onCreate(ScreenContext screenContext,
ScreenRequestParameters params,
ScreenSession screenSession,
DatabaseSession dbSession)
Implementation of the "onCreate" event, this method is designed to be overridden if necessary |
void |
onReuse(ScreenContext screenContext,
ScreenRequestParameters params,
ScreenSession screenSession,
DatabaseSession dbSession)
Implementation of the "onReuse" event, this method is designed to be overridden if necessary |
abstract void |
save(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Implementation of the "save" action |
abstract void |
update(ScreenData screenData,
ScreenContext screenContext,
ScreenRequest request,
ScreenResponse response,
DatabaseSession dbSession)
Implementation of the "update" action |
Methods inherited from class org.objectweb.telosys.common.TelosysObject |
error, error, error, getFlagTrace, info, setFlagTrace, trace, warn |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected static final int DEFAULT_DATABASE
protected static final int NO_DATABASE
Constructor Detail |
public StandardScreenManager(java.lang.Class screenDataClass)
screenDataClass
- the ScreenData classpublic StandardScreenManager(java.lang.Class screenDataClass, int iDatabaseId)
screenDataClass
- the ScreenData classiDatabaseId
- the id of the Database to use (to get a connection)Method Detail |
public abstract void load(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public abstract void save(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public abstract void insert(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public abstract void update(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public abstract void delete(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public void onCreate(ScreenContext screenContext, ScreenRequestParameters params, ScreenSession screenSession, DatabaseSession dbSession) throws TelosysException
screenContext
- params
- screenSession
- dbSession
-
TelosysException
public void onReuse(ScreenContext screenContext, ScreenRequestParameters params, ScreenSession screenSession, DatabaseSession dbSession) throws TelosysException
screenContext
- params
- screenSession
- dbSession
-
TelosysException
public void init(ScreenData screenData, ScreenContext context, java.util.Map parameters, DatabaseSession dbSession) throws TelosysException
screenData
- context
- parameters
- dbSession
-
TelosysException
public DatabaseSession getDatabaseSession() throws TelosysException
ScreenManager
getDatabaseSession
in interface ScreenManager
TelosysException
public int getDatabaseId()
ScreenManager
getDatabaseId
in interface ScreenManager
public void doInit(ScreenData screenData, ScreenContext screenContext, java.util.Map param, DatabaseSession dbSession) throws TelosysException
doInit
in interface ScreenManager
screenData
- screenContext
- param
- dbSession
-
TelosysException
public void doLoad(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
ScreenManager
doLoad
in interface ScreenManager
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public void doSave(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
ScreenManager
doSave
in interface ScreenManager
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public void doInsert(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
ScreenManager
doInsert
in interface ScreenManager
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public void doUpdate(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
ScreenManager
doUpdate
in interface ScreenManager
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public void doDelete(ScreenData screenData, ScreenContext screenContext, ScreenRequest request, ScreenResponse response, DatabaseSession dbSession) throws TelosysException
ScreenManager
doDelete
in interface ScreenManager
screenData
- screenContext
- request
- response
- dbSession
-
TelosysException
public final void eventCreate(ScreenContext screenContext, ScreenRequestParameters params, ScreenSession screenSession, DatabaseSession dbSession) throws TelosysException
ScreenManager
eventCreate
in interface ScreenManager
screenContext
- params
- screenSession
- dbSession
-
TelosysException
public final void eventReuse(ScreenContext screenContext, ScreenRequestParameters params, ScreenSession screenSession, DatabaseSession dbSession) throws TelosysException
ScreenManager
eventReuse
in interface ScreenManager
screenContext
- params
- screenSession
- dbSession
-
TelosysException
protected final ScreenApplication getScreenApplication()
protected final javax.servlet.ServletContext getServletContext()
protected final StandardDAO getDAO(java.lang.Class beanClass) throws TelosysException
beanClass
-
TelosysException
protected final StandardDAO getDAO(java.lang.Class beanClass, DatabaseSession dbSession) throws TelosysException
beanClass
- dbSession
-
TelosysException
protected final StandardDAO getDAO(java.lang.Class beanClass, int iDatabaseId) throws TelosysException
beanClass
- iDatabaseId
-
TelosysException