使用WebMvcConfigurerAdapter的addResourceHandlers方法,映射外部资源失败:
@SpringBootConfiguration
public class MySpringMVCConfig extends WebMvcConfigurerAdapter{
public void addResourceHandlers(ResourceHandlerRegistry registry) {
registry
.addResourceHandler("/GMap/**")
.addResourceLocations("file:E://GMap/");
super.addResourceHandlers(registry);
}
}怎么回事呢?
qq_遁去的一_1
慕容3067478
白板的微信
芜湖不芜
随时随地看视频慕课网APP
相关分类