@ParametersAreNonnullByDefault public class LoggingStoreListener extends Object implements StoreListener
StoreListener
that logs every calls in the Log
.Modifier and Type | Field and Description |
---|---|
static Level |
DEFAULT_LEVEL
The default logging level.
|
Constructor and Description |
---|
LoggingStoreListener()
Constructs a new
LoggingStoreListener . |
LoggingStoreListener(Level level)
Constructs a new
LoggingStoreListener with the given logging level . |
Modifier and Type | Method and Description |
---|---|
void |
onClose()
Handles the closure of the back-end.
|
<K,V> void |
onFailure(FailureCallReport<K,V> callReport)
Handles a failed call on the back-end.
|
void |
onInitialize()
Handles the initialization of the back-end.
|
<K,V,R> void |
onSuccess(SuccessCallReport<K,V,R> callReport)
Handles a succeeded call on the back-end.
|
public LoggingStoreListener()
LoggingStoreListener
.public LoggingStoreListener(Level level)
LoggingStoreListener
with the given logging level
.level
- the logging levelpublic void onInitialize()
StoreListener
This method is called after the initialization of the back-end.
onInitialize
in interface StoreListener
public <K,V,R> void onSuccess(SuccessCallReport<K,V,R> callReport)
StoreListener
onSuccess
in interface StoreListener
K
- the type of the key used during the call; nullableV
- the type of the value used during the call; nullableR
- the type of the result of the call; nullablecallReport
- information about the callpublic <K,V> void onFailure(FailureCallReport<K,V> callReport)
StoreListener
onFailure
in interface StoreListener
K
- the type of the key used during the call; nullableV
- the type of the value used during the call; nullablecallReport
- information about the callpublic void onClose()
StoreListener
This method is called after closing the back-end.
onClose
in interface StoreListener
Copyright © 2013–2019 Atlanmod. All rights reserved.