Package org.ldaptive.pool
Class AbstractPruneStrategy
- java.lang.Object
-
- org.ldaptive.pool.AbstractPruneStrategy
-
- All Implemented Interfaces:
Function<PooledConnectionProxy,Boolean>
,PruneStrategy
- Direct Known Subclasses:
IdlePruneStrategy
public abstract class AbstractPruneStrategy extends Object implements PruneStrategy
Base class for prune strategy implementations.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
AbstractPruneStrategy.AbstractBuilder<B,T extends AbstractPruneStrategy>
Base class for prune strategy builders.
-
Field Summary
Fields Modifier and Type Field Description protected static Duration
DEFAULT_PRUNE_PERIOD
Default prune period in seconds.protected Logger
logger
Logger for this class.private Duration
prunePeriod
Prune period.
-
Constructor Summary
Constructors Constructor Description AbstractPruneStrategy()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Duration
getPrunePeriod()
Returns the interval at which the prune task will be executed.void
setPrunePeriod(Duration period)
Sets the prune period.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.ldaptive.pool.PruneStrategy
getStatisticsSize
-
-
-
-
Method Detail
-
getPrunePeriod
public Duration getPrunePeriod()
Description copied from interface:PruneStrategy
Returns the interval at which the prune task will be executed.- Specified by:
getPrunePeriod
in interfacePruneStrategy
- Returns:
- prune period
-
setPrunePeriod
public void setPrunePeriod(Duration period)
Sets the prune period.- Parameters:
period
- to set
-
-