public static class RefreshStrategy.Composite extends Object implements RefreshStrategy
RefreshStrategy
instances,
each of which covers a certain strategy.RefreshStrategy.Composite, RefreshStrategy.ConditionalRefreshStrategy, RefreshStrategy.LogOnce, RefreshStrategy.Timed
Modifier and Type | Method and Description |
---|---|
static RefreshStrategy |
create(RefreshStrategy... refreshStrategies) |
boolean |
needsRefresh(long secondsSinceLastAccess)
Determine whether the given session needs to refresh before the next
session operation is performed.
|
void |
refreshed() |
String |
toString() |
public static RefreshStrategy create(RefreshStrategy... refreshStrategies)
public boolean needsRefresh(long secondsSinceLastAccess)
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–2019 The Apache Software Foundation. All rights reserved.