diff --git a/src/main/kotlin/top/fatweb/oxygen/api/annotation/Trim.kt b/src/main/kotlin/top/fatweb/oxygen/api/annotation/Trim.kt index de8c054..f3bdc81 100644 --- a/src/main/kotlin/top/fatweb/oxygen/api/annotation/Trim.kt +++ b/src/main/kotlin/top/fatweb/oxygen/api/annotation/Trim.kt @@ -2,6 +2,13 @@ package top.fatweb.oxygen.api.annotation import java.lang.annotation.Inherited + +/** + * Trim string annotation + * + * @author FatttSnake, fatttsnake@gmail.com + * @since 1.0.0 + */ @Target(AnnotationTarget.FUNCTION, AnnotationTarget.CLASS, AnnotationTarget.PROPERTY) @Retention(AnnotationRetention.RUNTIME) @Inherited diff --git a/src/main/kotlin/top/fatweb/oxygen/api/aop/EventLogInterceptor.kt b/src/main/kotlin/top/fatweb/oxygen/api/aop/EventLogInterceptor.kt index 2843710..5a61beb 100644 --- a/src/main/kotlin/top/fatweb/oxygen/api/aop/EventLogInterceptor.kt +++ b/src/main/kotlin/top/fatweb/oxygen/api/aop/EventLogInterceptor.kt @@ -13,7 +13,7 @@ import top.fatweb.oxygen.api.vo.permission.LoginVo import top.fatweb.oxygen.api.vo.permission.RegisterVo /** - * Event log record aspect + * Event log record interceptor * * @author FatttSnake, fatttsnake@gmail.com * @since 1.0.0 diff --git a/src/main/kotlin/top/fatweb/oxygen/api/aop/SysLogInterceptor.kt b/src/main/kotlin/top/fatweb/oxygen/api/aop/SysLogInterceptor.kt index c691a9a..c6f41e9 100644 --- a/src/main/kotlin/top/fatweb/oxygen/api/aop/SysLogInterceptor.kt +++ b/src/main/kotlin/top/fatweb/oxygen/api/aop/SysLogInterceptor.kt @@ -31,6 +31,8 @@ import java.util.concurrent.Executor * @since 1.0.0 * @see Executor * @see ISysLogService + * @see HandlerInterceptor + * @see ResponseBodyAdvice */ @ControllerAdvice class SysLogInterceptor( diff --git a/src/main/kotlin/top/fatweb/oxygen/api/aop/TrimInterceptor.kt b/src/main/kotlin/top/fatweb/oxygen/api/aop/TrimInterceptor.kt index fbfe2eb..fae937f 100644 --- a/src/main/kotlin/top/fatweb/oxygen/api/aop/TrimInterceptor.kt +++ b/src/main/kotlin/top/fatweb/oxygen/api/aop/TrimInterceptor.kt @@ -11,13 +11,35 @@ import kotlin.reflect.KMutableProperty import kotlin.reflect.full.* import kotlin.reflect.jvm.isAccessible +/** + * Trim string interceptor + * + * @author FatttSnake, fatttsnake@gmail.com + * @since 1.0.0 + * @see HandlerInterceptor + */ @Component @Aspect class TrimInterceptor : HandlerInterceptor { + /** + * Trim pointcut + * + * @author FatttSnake, fatttsnake@gmail.com + * @since 1.0.0 + */ @Pointcut("@annotation(top.fatweb.oxygen.api.annotation.Trim)") fun trimPointcut() { } + /** + * Do before trim pointcut + * + * @param joinPoint Join point + * @return Arguments + * @author FatttSnake, fatttsnake@gmail.com + * @since 1.0.0 + * @see JoinPoint + */ @Before("trimPointcut()") fun doBefore(joinPoint: JoinPoint): Any { val args = joinPoint.args