log日志记录

This commit is contained in:
2025-05-03 15:03:36 +08:00
parent bce338ee19
commit 110e73b993
3 changed files with 17 additions and 19 deletions

View File

@ -4,11 +4,11 @@ import java.lang.annotation.*;
/**
* 自定义注解记录系统操作日志
*/
//Target注解决定 MyLog 注解可以加在哪些成分上如加在类身上或者属性身上或者方法身上等成分
//Target注解决定 SysLog 注解可以加在哪些成分上如加在类身上或者属性身上或者方法身上等成分
@Target({ ElementType.PARAMETER, ElementType.METHOD })
//Retention注解括号中的"RetentionPolicy.RUNTIME"意思是让 MyLog 这个注解的生命周期一直程序运行时都存在
//Retention注解括号中的"RetentionPolicy.RUNTIME"意思是让 SysLog 这个注解的生命周期一直程序运行时都存在
@Retention(RetentionPolicy.RUNTIME)
public @interface MyLog {
public @interface SysLog {
/**
* 模块标题
*/