public static class RefreshStrategy.Timed extends Object implements RefreshStrategy
RefreshStrategy.Composite, RefreshStrategy.LogOnce, RefreshStrategy.Timed
Modifier and Type | Field and Description |
---|---|
protected long |
interval |
Constructor and Description |
---|
RefreshStrategy.Timed(long interval) |
Modifier and Type | Method and Description |
---|---|
boolean |
needsRefresh(long secondsSinceLastAccess)
Determine whether the given session needs to refresh before the next
session operation is performed.
|
void |
refreshed() |
String |
toString() |
public RefreshStrategy.Timed(long interval)
interval
- Interval in seconds after which a session should refresh if there was no
activity.public boolean needsRefresh(long secondsSinceLastAccess)
RefreshStrategy
This implementation returns true
if and only if any of the
individual refresh strategies passed to the constructor returns
true
.
needsRefresh
in interface RefreshStrategy
secondsSinceLastAccess
- seconds since last accesstrue
if and only if the session needs to refresh.public void refreshed()
refreshed
in interface RefreshStrategy
Copyright © 2012-2015 The Apache Software Foundation. All Rights Reserved.