public abstract class AbstractLoggingAspect extends Object
Before) have
to be implemented in subclasses to specify joint-points to intercept and call logJoinPoint(...) in it. Subclasses
have to have Aspect annotation to be able to act as Spring Aspect.| Modifier and Type | Field and Description |
|---|---|
static String |
DEBUG |
static String |
DEFAULT_LOG_LEVEL |
static String |
INFO |
static String |
TRACE |
static String |
WARN |
| Constructor and Description |
|---|
AbstractLoggingAspect() |
| Modifier and Type | Method and Description |
|---|---|
protected Logger |
getLogger() |
protected String |
getLogInfoFromArgs(List<?> args)
Returns String representation of argument set of intercepted method.
|
protected String |
getLogLevel() |
protected abstract boolean |
isEligibleForJoinPoint(JoinPoint joinPoint)
Checks if the
joinPoint is eligible to process. |
protected boolean |
isLoggingEligibleForJoinPoint(JoinPoint joinPoint)
Checks if the
joinPoint is eligible for logging. |
protected void |
logJoinPoint(JoinPoint joinPoint)
Does logging for the intercepted
joinPoint. |
void |
setLogLevel(String logLevel) |
public static final String DEBUG
public static final String WARN
public static final String TRACE
public static final String INFO
public static final String DEFAULT_LOG_LEVEL
protected Logger getLogger()
protected void logJoinPoint(JoinPoint joinPoint)
joinPoint.protected boolean isLoggingEligibleForJoinPoint(JoinPoint joinPoint)
joinPoint is eligible for logging.protected abstract boolean isEligibleForJoinPoint(JoinPoint joinPoint)
joinPoint is eligible to process.protected String getLogInfoFromArgs(List<?> args)
protected String getLogLevel()
public void setLogLevel(String logLevel)
Copyright © 2017 SAP SE. All Rights Reserved.