本文整理了Java中hudson.model.Messages._Queue_BlockedBy()
方法的一些代码示例,展示了Messages._Queue_BlockedBy()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Messages._Queue_BlockedBy()
方法的具体详情如下:
包路径:hudson.model.Messages
类名称:Messages
方法名:_Queue_BlockedBy
[英]Blocked by {0}
[中]被{0}阻止
代码示例来源:origin: jenkinsci/jenkins
/**
*
* Checks if the given task knows the reasons to be blocked or it needs some unavailable resources
*
* @param task the task.
* @return the reason of blockage if it exists null otherwise.
*/
@CheckForNull
private CauseOfBlockage getCauseOfBlockageForTask(Task task) {
CauseOfBlockage causeOfBlockage = task.getCauseOfBlockage();
if (causeOfBlockage != null) {
return task.getCauseOfBlockage();
}
if (!canRun(task.getResourceList())) {
ResourceActivity r = getBlockingActivity(task);
if (r != null) {
if (r == task) // blocked by itself, meaning another build is in progress
return CauseOfBlockage.fromMessage(Messages._Queue_InProgress());
return CauseOfBlockage.fromMessage(Messages._Queue_BlockedBy(r.getDisplayName()));
}
}
return null;
}
代码示例来源:origin: org.jvnet.hudson.main/hudson-core
public CauseOfBlockage getCauseOfBlockage() {
ResourceActivity r = getBlockingActivity(task);
if (r != null) {
if (r == task) // blocked by itself, meaning another build is in progress
return CauseOfBlockage.fromMessage(Messages._Queue_InProgress());
return CauseOfBlockage.fromMessage(Messages._Queue_BlockedBy(r.getDisplayName()));
}
return task.getCauseOfBlockage();
}
}
代码示例来源:origin: org.eclipse.hudson.main/hudson-core
public CauseOfBlockage getCauseOfBlockage() {
ResourceActivity r = getBlockingActivity(task);
if (r != null) {
if (r == task) // blocked by itself, meaning another build is in progress
return CauseOfBlockage.fromMessage(Messages._Queue_InProgress());
return CauseOfBlockage.fromMessage(Messages._Queue_BlockedBy(r.getDisplayName()));
}
return task.getCauseOfBlockage();
}
}
代码示例来源:origin: hudson/hudson-2.x
public CauseOfBlockage getCauseOfBlockage() {
ResourceActivity r = getBlockingActivity(task);
if (r != null) {
if (r == task) // blocked by itself, meaning another build is in progress
return CauseOfBlockage.fromMessage(Messages._Queue_InProgress());
return CauseOfBlockage.fromMessage(Messages._Queue_BlockedBy(r.getDisplayName()));
}
return task.getCauseOfBlockage();
}
}
代码示例来源:origin: org.eclipse.hudson/hudson-core
@Override
public CauseOfBlockage getCauseOfBlockage() {
ResourceActivity r = getBlockingActivity(task);
if (r != null) {
if (r == task) // blocked by itself, meaning another build is in progress
{
return CauseOfBlockage.fromMessage(Messages._Queue_InProgress());
}
return CauseOfBlockage.fromMessage(Messages._Queue_BlockedBy(r.getDisplayName()));
}
return task.getCauseOfBlockage();
}
}
代码示例来源:origin: org.jenkins-ci.main/jenkins-core
/**
*
* Checks if the given task knows the reasons to be blocked or it needs some unavailable resources
*
* @param task the task.
* @return the reason of blockage if it exists null otherwise.
*/
@CheckForNull
private CauseOfBlockage getCauseOfBlockageForTask(Task task) {
CauseOfBlockage causeOfBlockage = task.getCauseOfBlockage();
if (causeOfBlockage != null) {
return task.getCauseOfBlockage();
}
if (!canRun(task.getResourceList())) {
ResourceActivity r = getBlockingActivity(task);
if (r != null) {
if (r == task) // blocked by itself, meaning another build is in progress
return CauseOfBlockage.fromMessage(Messages._Queue_InProgress());
return CauseOfBlockage.fromMessage(Messages._Queue_BlockedBy(r.getDisplayName()));
}
}
return null;
}
内容来源于网络,如有侵权,请联系作者删除!