spring-framework / org.springframework.web.bind.support / DefaultSessionAttributeStore

DefaultSessionAttributeStore

open class DefaultSessionAttributeStore : SessionAttributeStore

Default implementation of the SessionAttributeStore interface, storing the attributes in the WebRequest session (i.e. HttpSession or PortletSession).

Author
Juergen Hoeller

Since
2.5

See Also
#setAttributeNamePrefixorg.springframework.web.context.request.WebRequest#setAttributeorg.springframework.web.context.request.WebRequest#getAttributeorg.springframework.web.context.request.WebRequest#removeAttribute

Constructors

<init>

DefaultSessionAttributeStore()

Default implementation of the SessionAttributeStore interface, storing the attributes in the WebRequest session (i.e. HttpSession or PortletSession).

Functions

cleanupAttribute

open fun cleanupAttribute(request: WebRequest, attributeName: String): Unit

retrieveAttribute

open fun retrieveAttribute(request: WebRequest, attributeName: String): Any

setAttributeNamePrefix

open fun setAttributeNamePrefix(attributeNamePrefix: String): Unit

Specify a prefix to use for the attribute names in the backend session.

Default is to use no prefix, storing the session attributes with the same name as in the model.

storeAttribute

open fun storeAttribute(request: WebRequest, attributeName: String, attributeValue: Any): Unit