本文整理了Java中hudson.model.AbstractBuild.getEstimatedDuration()
方法的一些代码示例,展示了AbstractBuild.getEstimatedDuration()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。AbstractBuild.getEstimatedDuration()
方法的具体详情如下:
包路径:hudson.model.AbstractBuild
类名称:AbstractBuild
方法名:getEstimatedDuration
暂无
代码示例来源:origin: Diabol/delivery-pipeline-plugin
private static int calculateBuildProgress(AbstractBuild build) {
return calculateBuildProgress(
currentTimeMillis(), build.getTimestamp().getTimeInMillis(), build.getEstimatedDuration());
}
代码示例来源:origin: org.jenkins-ci.plugins/build-pipeline-plugin
/**
* Returns the estimated percentage complete of the current build.
*
* @return - Estimated percentage complete of the current build.
*/
public long getBuildProgress() {
if (this.currentBuild != null && this.currentBuild.isBuilding()) {
final long duration = new Date().getTime() - this.currentBuild.getTimestamp().getTimeInMillis();
return calculatePercentage(duration, this.currentBuild.getEstimatedDuration());
} else {
return 0;
}
}
代码示例来源:origin: openstack-infra/gearman-plugin
int estimatedDuration = (int) currBuild.getEstimatedDuration();
jobData = buildStatusData(currBuild);
内容来源于网络,如有侵权,请联系作者删除!