|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface RefreshStrategy
Implementations of this interface determine whether a session needs
to be refreshed before the next session operation is performed. This is
done by the session calling needsRefresh(long)
to determine
whether a refresh is needed.
RefreshStrategy.Composite
,
RefreshStrategy.Timed
,
RefreshStrategy.LogOnce
Nested Class Summary | |
---|---|
static class |
RefreshStrategy.Composite
Composite of zero or more RefreshStrategy instances,
each of which covers a certain strategy. |
static class |
RefreshStrategy.LogOnce
This refresh strategy never refreshed the session but logs a warning if a session has been idle for more than a given time. |
static class |
RefreshStrategy.Timed
This refresh strategy refreshes after a given timeout of inactivity. |
Method Summary | |
---|---|
boolean |
needsRefresh(long secondsSinceLastAccess)
Determine whether the given session needs to refresh before the next session operation is performed. |
Method Detail |
---|
boolean needsRefresh(long secondsSinceLastAccess)
This implementation returns true
if and only if any of the
individual refresh strategies passed to the constructor returns
true
.
secondsSinceLastAccess
- seconds since last access
true
if and only if the session needs to refresh.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |