groovy.util.logging
public static class Log4j.Log4jLoggingStrategy extends Object implements LogASTTransformation.LoggingStrategy
Constructor and Description |
---|
Log4j.Log4jLoggingStrategy() |
Modifier and Type | Method and Description |
---|---|
FieldNode |
addLoggerFieldToClass(ClassNode classNode,
String logFieldName)
In this method, you are given a ClassNode and a field name, and you must add a new Field
onto the class.
|
boolean |
isLoggingMethod(String methodName) |
Expression |
wrapLoggingMethodCall(Expression logVariable,
String methodName,
Expression originalExpression) |
public FieldNode addLoggerFieldToClass(ClassNode classNode, String logFieldName)
LogASTTransformation.LoggingStrategy
addLoggerFieldToClass
in interface LogASTTransformation.LoggingStrategy
classNode
- the class that was originally annotated with the Log transformation.logFieldName
- the name of the logger fieldpublic boolean isLoggingMethod(String methodName)
isLoggingMethod
in interface LogASTTransformation.LoggingStrategy
public Expression wrapLoggingMethodCall(Expression logVariable, String methodName, Expression originalExpression)
wrapLoggingMethodCall
in interface LogASTTransformation.LoggingStrategy