hudson.model.AbstractProject.poll()方法的使用及代码示例

x33g5p2x  于2022-01-15 转载在 其他  
字(3.2k)|赞(0)|评价(0)|浏览(99)

本文整理了Java中hudson.model.AbstractProject.poll()方法的一些代码示例,展示了AbstractProject.poll()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。AbstractProject.poll()方法的具体详情如下:
包路径:hudson.model.AbstractProject
类名称:AbstractProject
方法名:poll

AbstractProject.poll介绍

[英]Checks if there's any update in SCM, and returns true if any is found.

The implementation is responsible for ensuring mutual exclusion between polling and builds if necessary.
[中]检查SCM中是否有任何更新,如果发现任何更新,则返回true。
如有必要,实现负责确保轮询和构建之间的互斥。

代码示例

代码示例来源:origin: jenkinsci/jenkins

/**
 * Checks if there's any update in SCM, and returns true if any is found.
 *
 * @deprecated as of 1.346
 *      Use {@link #poll(TaskListener)} instead.
 */
@Deprecated
public boolean pollSCMChanges( TaskListener listener ) {
  return poll(listener).hasChanges();
}

代码示例来源:origin: org.eclipse.hudson.main/hudson-core

/**
 * Checks if there's any update in SCM, and returns true if any is found.
 *
 * @deprecated as of 1.346 Use {@link #poll(TaskListener)} instead.
 */
public boolean pollSCMChanges(TaskListener listener) {
  return poll(listener).hasChanges();
}

代码示例来源:origin: org.jenkins-ci.main/jenkins-core

/**
 * Checks if there's any update in SCM, and returns true if any is found.
 *
 * @deprecated as of 1.346
 *      Use {@link #poll(TaskListener)} instead.
 */
@Deprecated
public boolean pollSCMChanges( TaskListener listener ) {
  return poll(listener).hasChanges();
}

代码示例来源:origin: org.jvnet.hudson.main/hudson-core

/**
 * Checks if there's any update in SCM, and returns true if any is found.
 *
 * @deprecated as of 1.346
 *      Use {@link #poll(TaskListener)} instead.
 */
public boolean pollSCMChanges( TaskListener listener ) {
  return poll(listener).hasChanges();
}

代码示例来源:origin: org.eclipse.hudson/hudson-core

/**
 * Checks if there's any update in SCM, and returns true if any is found.
 *
 * @deprecated as of 1.346 Use {@link #poll(TaskListener)} instead.
 */
public boolean pollSCMChanges(TaskListener listener) {
  return poll(listener).hasChanges();
}

代码示例来源:origin: hudson/hudson-2.x

/**
 * Checks if there's any update in SCM, and returns true if any is found.
 *
 * @deprecated as of 1.346
 *      Use {@link #poll(TaskListener)} instead.
 */
public boolean pollSCMChanges( TaskListener listener ) {
  return poll(listener).hasChanges();
}

代码示例来源:origin: org.hudsonci.plugins/downstream-ext

public void run() {
    LOGGER.info("Polling for SCM changes in " + this.project.getName());
    PollingResult pollingResult = this.project.poll(this.taskListener);
    if(pollingResult.hasChanges()) {
      LOGGER.info("SCM changes found for " + this.project.getName() + ". Triggering build.");
      if (this.project.scheduleBuild(this.project.getQuietPeriod(), this.cause,
          buildActions.toArray(new Action[buildActions.size()]))) {
        LOGGER.info("Build of " + this.project.getName() + " scheduled successfully.");
      } else {
        LOGGER.info("No build of " + this.project.getName() + " scheduled - this usually means that another build is already in the queue.");
      }
    } else {
      LOGGER.info(Messages.DownstreamTrigger_NoSCMChanges(this.project.getName()));
    }
  }
}

代码示例来源:origin: org.eclipse.hudson/hudson-core

long start = System.currentTimeMillis();
logger.println("Started on " + DateFormat.getDateTimeInstance().format(new Date()));
boolean result = job.poll(listener).hasChanges();
logger.println("Done. Took " + Util.getTimeSpanString(System.currentTimeMillis() - start));
if (result) {

代码示例来源:origin: org.hudsonci.plugins/downstream-ext

if (p.poll(listener).hasChanges()) {
  return true;
} else {

相关文章

微信公众号

最新文章

更多

AbstractProject类方法