当前位置: 首页>>代码示例>>Java>>正文


Java ViewControllerRegistry.addRedirectViewController方法代码示例

本文整理汇总了Java中org.springframework.web.servlet.config.annotation.ViewControllerRegistry.addRedirectViewController方法的典型用法代码示例。如果您正苦于以下问题:Java ViewControllerRegistry.addRedirectViewController方法的具体用法?Java ViewControllerRegistry.addRedirectViewController怎么用?Java ViewControllerRegistry.addRedirectViewController使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.springframework.web.servlet.config.annotation.ViewControllerRegistry的用法示例。


在下文中一共展示了ViewControllerRegistry.addRedirectViewController方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(ViewControllerRegistry registry) {
    LOGGER.info("Configure additional ViewControllers");
    registry.addRedirectViewController("/", "/swagger-ui.html");
}
 
开发者ID:bartprokop,项目名称:nice-api,代码行数:6,代码来源:WebMvcConfiguration.java

示例2: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(ViewControllerRegistry registry) {
	super.addViewControllers(registry);

    registry.addRedirectViewController("/", "/ui");

    registry.addViewController("/ui/**").setViewName("forward:/index.html");
}
 
开发者ID:gilles-stragier,项目名称:quickmon,代码行数:9,代码来源:WebMvcConfig.java

示例3: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(ViewControllerRegistry registry) {
    String contextPath = zuulakoProperties.getContextPath();
    if (StringUtils.hasText(contextPath)) {
        registry.addRedirectViewController(contextPath, server.getPath(contextPath) + "/");
    }
    registry.addViewController(contextPath + "/").setViewName("forward:index.html");
}
 
开发者ID:nabilblk,项目名称:zuulako,代码行数:9,代码来源:WebConfig.java

示例4: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
/**
 * 将无需后端处理的 url 重定向
 */
@Override
public void addViewControllers(ViewControllerRegistry registry) {
    registry.addRedirectViewController("/", "/base-code/list");
}
 
开发者ID:drtrang,项目名称:dynamic-data-source-demo,代码行数:8,代码来源:SpringMvcConfig.java

示例5: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(final ViewControllerRegistry registry) {
    registry.addRedirectViewController("/", "/send");
}
 
开发者ID:osiegmar,项目名称:setra,代码行数:5,代码来源:WebConfig.java

示例6: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(ViewControllerRegistry registry) {
	registry.addRedirectViewController("/", "user");
}
 
开发者ID:lf23617358,项目名称:training-sample,代码行数:5,代码来源:WebAppConfig.java

示例7: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(ViewControllerRegistry registry) {
    registry.addRedirectViewController("/", "/swagger-ui.html");
}
 
开发者ID:helloworldtang,项目名称:spring-boot-jwt-jpa,代码行数:5,代码来源:WebMvcConfig.java

示例8: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(final ViewControllerRegistry registry) {
  registry.addRedirectViewController("/", "/swagger-ui.html");
  super.addViewControllers(registry);
}
 
开发者ID:holisticon,项目名称:holunda,代码行数:6,代码来源:SwaggerConfiguration.java

示例9: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(final ViewControllerRegistry registry) {
    registry.addRedirectViewController("/", "/main.html");
}
 
开发者ID:backpaper0,项目名称:urgmstack,代码行数:5,代码来源:WebMvcConfig.java

示例10: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
/**
 * 设置欢迎页
 * 相当于web.xml中的 welcome-file-list > welcome-file
 */
@Override
public void addViewControllers(ViewControllerRegistry registry) {
    registry.addRedirectViewController("/", "/index.html");
}
 
开发者ID:liangzai-cool,项目名称:springsecuritystudy,代码行数:9,代码来源:WebAppConfig.java

示例11: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(ViewControllerRegistry registry) {
	registry.addRedirectViewController("/", "/login");
}
 
开发者ID:edylle,项目名称:pathological-reports,代码行数:5,代码来源:PathologicalReportsApplication.java

示例12: addViewControllers

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry; //导入方法依赖的package包/类
@Override
public void addViewControllers(ViewControllerRegistry registry) {
	registry.addRedirectViewController("/", "/home");
}
 
开发者ID:edylle,项目名称:hockey-game,代码行数:5,代码来源:HockeyGameApplication.java


注:本文中的org.springframework.web.servlet.config.annotation.ViewControllerRegistry.addRedirectViewController方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。