Class DefaultSessionValidator
- java.lang.Object
-
- org.apache.turbine.modules.actions.sessionvalidator.SessionValidator
-
- org.apache.turbine.modules.actions.sessionvalidator.DefaultSessionValidator
-
public class DefaultSessionValidator extends SessionValidator
The SessionValidator attempts to retrieve the User object from the Servlet API session that is associated with the request. If the data cannot be retrieved, it is handled here. If the user has not been marked as being logged into the system, the user is rejected and the screen is set to the screen.homepage value in TurbineResources.properties.Other systems generally have a database table which stores this information, but we take advantage of the Servlet API here to save a hit to the database for each and every connection that a user makes.
This action is special in that it should only be executed by the Turbine servlet.
- Version:
- $Id$
- Author:
- Dave Bryson, Henning P. Schmiedehausen, Peter Courcoux
-
-
Field Summary
-
Fields inherited from class org.apache.turbine.modules.actions.sessionvalidator.SessionValidator
screenHomepage, screenInvalidState, security, templateHomepage, templateInvalidState
-
Fields inherited from interface org.apache.turbine.modules.Action
CACHE_SIZE_DEFAULT, CACHE_SIZE_KEY, NAME, PREFIX
-
-
Constructor Summary
Constructors Constructor Description DefaultSessionValidator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
doPerform(PipelineData pipelineData)
Execute the action.-
Methods inherited from class org.apache.turbine.modules.actions.sessionvalidator.SessionValidator
handleFormCounterToken
-
-
-
-
Constructor Detail
-
DefaultSessionValidator
public DefaultSessionValidator()
-
-
Method Detail
-
doPerform
public void doPerform(PipelineData pipelineData) throws Exception
Execute the action. The default behavior is to populate the PipelineData object, and if the user is unknown, to then force a redirect to the login screen (as set in the tr.props).- Parameters:
pipelineData
- Turbine PipelineData context information.- Throws:
Exception
- The anonymous user could not be obtained from the security service- See Also:
InvalidState
-
-