Change namespace to top.fatweb.oxygen.api

This commit is contained in:
2023-12-28 13:39:42 +08:00
parent 605f3f4152
commit 47baa06125
231 changed files with 698 additions and 682 deletions

View File

@@ -0,0 +1,21 @@
package top.fatweb.oxygen.api.config
import org.springframework.boot.autoconfigure.web.servlet.WebMvcRegistrations
import org.springframework.context.annotation.Configuration
import org.springframework.web.servlet.config.annotation.PathMatchConfigurer
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer
import top.fatweb.oxygen.api.annotation.ApiController
/**
* Web MVC configurer configuration
*
* @author FatttSnake, fatttsnake@gmail.com
* @since 1.0.0
* @see WebMvcRegistrations
*/
@Configuration
class WebMvcConfigurerConfig : WebMvcConfigurer {
override fun configurePathMatch(configurer: PathMatchConfigurer) {
configurer.addPathPrefix("/api/{API_VERSION}") { it.isAnnotationPresent(ApiController::class.java) }
}
}