Log和DisableBaseResponse自定义注解撰写

master
wjy 8 months ago
parent 65cc72961f
commit 5ede697ed0

@ -0,0 +1,14 @@
package com.example.api.annotation;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
*
*/
@Target(ElementType.METHOD)
@Retention(RetentionPolicy.RUNTIME)
public @interface DisableBaseResponse {
}

@ -0,0 +1,20 @@
package com.example.api.annotation;
import com.example.api.model.enums.BusinessType;
import java.lang.annotation.*;
@Target(ElementType.METHOD) //目标类型
@Retention(RetentionPolicy.RUNTIME) //作用范围
@Documented
public @interface Log {
/*
*/
String module() default "";
/*
*/
BusinessType type();
}
Loading…
Cancel
Save