All Downloads are FREE. Search and download functionalities are using the official Maven repository.

im.aop.loggers.advice.before.LogBefore Maven / Gradle / Ivy

Go to download

A handy and configurable sets of annotation-based loggers for Spring Boot that can log every execution of a method when entering or exiting normally or abnormally, without you writing a single line of code using aspect-oriented programming (AOP)

The newest version!
package im.aop.loggers.advice.before;

import im.aop.loggers.Level;
import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * Log before entering the target method.
 *
 * @author Andy Lian
 */
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.TYPE, ElementType.METHOD})
@Documented
public @interface LogBefore {

  /**
   * @return Class name used as Logger's category name
   */
  Class declaringClass() default void.class;

  /**
   * @return Log Level for entering message
   */
  Level level() default Level.DEFAULT;

  /**
   * @return Entering message template
   */
  String enteringMessage() default "";
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy