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


Java StaplerResponse.forwardToPreviousPage方法代码示例

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


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

示例1: doClean

import org.kohsuke.stapler.StaplerResponse; //导入方法依赖的package包/类
@RequirePOST
public void doClean(StaplerRequest req, StaplerResponse res) throws IOException, ServletException {
    // TODO switch to Jenkins.getActiveInstance() once 1.590+ is the baseline
    Jenkins jenkins = Jenkins.getInstance();
    if (jenkins == null) {
        throw new IllegalStateException("Jenkins has not been started, or was already shut down");
    }
    final Job job = jenkins.getItemByFullName(req.getParameter("job"), Job.class);
    Timer.get().submit(new Runnable() {
        @Override
        public void run() {
            try {
                job.logRotate();
            } catch (Exception e) {
                logger.log(Level.WARNING, "logRotate failed", e);
            }
        }
    });
    res.forwardToPreviousPage(req);
}
 
开发者ID:jenkinsci,项目名称:cloudbees-disk-usage-simple-plugin,代码行数:21,代码来源:QuickDiskUsagePlugin.java

示例2: doRefresh

import org.kohsuke.stapler.StaplerResponse; //导入方法依赖的package包/类
@RequirePOST
public void doRefresh(StaplerRequest req, StaplerResponse res) throws IOException, ServletException {
    refreshData();
    res.forwardToPreviousPage(req);
}
 
开发者ID:jenkinsci,项目名称:cloudbees-disk-usage-simple-plugin,代码行数:6,代码来源:QuickDiskUsagePlugin.java

示例3: doRefreshHook

import org.kohsuke.stapler.StaplerResponse; //导入方法依赖的package包/类
public void doRefreshHook(StaplerRequest request, StaplerResponse response) throws IOException, ServletException {
    new GithubRepositoryService(getGithubRepository(request)).addHook(getAccessToken(request), getCurrentUserLogin(request));
    response.forwardToPreviousPage(request);
}
 
开发者ID:groupon,项目名称:DotCi,代码行数:5,代码来源:RefreshHookRepoAction.java

示例4: doToggleNewUI

import org.kohsuke.stapler.StaplerResponse; //导入方法依赖的package包/类
public void doToggleNewUI(final StaplerRequest req, final StaplerResponse rsp) throws IOException, ServletException, InterruptedException {
    toggleNewUI();
    rsp.forwardToPreviousPage(req);
}
 
开发者ID:groupon,项目名称:DotCi,代码行数:5,代码来源:DynamicProject.java

示例5: doBranchBuilds

import org.kohsuke.stapler.StaplerResponse; //导入方法依赖的package包/类
public void doBranchBuilds(final StaplerRequest req, final StaplerResponse rsp) throws IOException, ServletException, InterruptedException {
    final String tab = req.getRestOfPath().replace("/", "");
    handleBranchTabs(tab, req);
    rsp.forwardToPreviousPage(req);
}
 
开发者ID:groupon,项目名称:DotCi,代码行数:6,代码来源:DynamicProject.java


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