Package org.pac4j.core.util
Class InitializableObject
java.lang.Object
org.pac4j.core.util.InitializableObject
- Direct Known Subclasses:
AbstractStore,BaseClient,BaseClientConfiguration,Clients,LocalCachingAuthenticator,LocalCachingProfileCreator,ProfileDefinitionAware
Object that can be (re-)initialized.
- Since:
- 1.4.0
- Author:
- Jerome Leleu
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidafterInternalInit(boolean forceReinit) protected voidbeforeInternalInit(boolean forceReinit) final Longfinal intfinal longfinal intvoidinit()Initialize the object.voidinit(boolean forceReinit) (Re)-initialize the object.protected abstract voidinternalInit(boolean forceReinit) Internal initialization of the object.final booleanvoidreinit()Re-initialize the object.final voidsetMaxAttempts(int maxAttempts) final voidsetMinTimeIntervalBetweenAttemptsInMilliseconds(long minTimeIntervalBetweenAttemptsInMilliseconds) protected booleanshouldInitialize(boolean forceReinit)
-
Constructor Details
-
InitializableObject
public InitializableObject()
-
-
Method Details
-
init
public void init()Initialize the object. -
reinit
public void reinit()Re-initialize the object. -
init
public void init(boolean forceReinit) (Re)-initialize the object.- Parameters:
forceReinit- whether the object should be re-initialized
-
isInitialized
public final boolean isInitialized() -
shouldInitialize
protected boolean shouldInitialize(boolean forceReinit) -
internalInit
protected abstract void internalInit(boolean forceReinit) Internal initialization of the object. -
beforeInternalInit
protected void beforeInternalInit(boolean forceReinit) -
afterInternalInit
protected void afterInternalInit(boolean forceReinit) -
getMaxAttempts
public final int getMaxAttempts() -
setMaxAttempts
public final void setMaxAttempts(int maxAttempts) -
getNbAttempts
public final int getNbAttempts() -
getLastAttempt
-
getMinTimeIntervalBetweenAttemptsInMilliseconds
public final long getMinTimeIntervalBetweenAttemptsInMilliseconds() -
setMinTimeIntervalBetweenAttemptsInMilliseconds
public final void setMinTimeIntervalBetweenAttemptsInMilliseconds(long minTimeIntervalBetweenAttemptsInMilliseconds)
-