本文整理汇总了Java中com.atlassian.bamboo.plan.PlanKey类的典型用法代码示例。如果您正苦于以下问题:Java PlanKey类的具体用法?Java PlanKey怎么用?Java PlanKey使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
PlanKey类属于com.atlassian.bamboo.plan包,在下文中一共展示了PlanKey类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: shouldDisplay
import com.atlassian.bamboo.plan.PlanKey; //导入依赖的package包/类
public boolean shouldDisplay(Map<String, Object> context) {
PlanKey planKey = PlanKeys.getPlanKey((String) context.get("planKey"));
Chain planChain = (Chain) planManager.getPlanByKey(planKey);
for (ChainStage chainStage : planChain.getStages())
{
for (Job job: chainStage.getJobs())
{
Plan plan = planManager.getPlanByKey(job.getPlanKey());
List<TaskDefinition> tasks = plan.getBuildDefinition().getTaskDefinitions();
for(TaskDefinition task : tasks) {
if(
task.getPluginKey().equals(DeploymentTask.KEY) ||
task.getPluginKey().equals(StatisticsTask.KEY)
) {
return true;
}
}
}
}
return false;
}
示例2: updateStatus
import com.atlassian.bamboo.plan.PlanKey; //导入依赖的package包/类
void updateStatus(GHCommitState status, StageExecution stageExecution) {
ChainExecution chainExecution = stageExecution.getChainExecution();
PlanResultKey planResultKey = chainExecution.getPlanResultKey();
PlanKey planKey = planResultKey.getPlanKey();
ImmutableChain chain = (ImmutableChain) planManager.getPlanByKey(planKey);
for (RepositoryDefinition repo : Configuration.ghReposFrom(chain)) {
if (shouldUpdateRepo(chain, repo)) {
String sha = chainExecution.getBuildChanges().getVcsRevisionKey(repo.getId());
if (sha != null) {
GitHubRepository ghRepo = (GitHubRepository) repo.getRepository();
setStatus(ghRepo, status, sha, planResultKey.getKey(), stageExecution.getName());
}
}
}
}
示例3: doExecute
import com.atlassian.bamboo.plan.PlanKey; //导入依赖的package包/类
public String doExecute() throws Exception {
String result = super.doExecute();
PlanKey planKey = PlanKeys.getPlanKey(getBuildKey());
Chain planChain = (Chain) planManager.getPlanByKey(planKey);
for (ChainStage chainStage : planChain.getStages())
{
for (Job job: chainStage.getJobs())
{
Plan plan = planManager.getPlanByKey(job.getPlanKey());
List<TaskDefinition> tasks = plan.getBuildDefinition().getTaskDefinitions();
for(TaskDefinition task : tasks) {
if(task.getPluginKey().equals(DeploymentTask.KEY)) {
buildUrlZsJobDetails(job.getBuildName(), job.getBuildKey());
}
else if (task.getPluginKey().equals(StatisticsTask.KEY)) {
buildUrlZsStatistics(job.getBuildName(), job.getBuildKey());
}
buildUrlZsJobLog(job.getBuildKey());
}
}
}
return result;
}
示例4: shouldDisplay
import com.atlassian.bamboo.plan.PlanKey; //导入依赖的package包/类
public boolean shouldDisplay(Map<String, Object> context) {
PlanKey planKey = PlanKeys.getPlanKey((String) context.get("planKey"));
Plan plan = planManager.getPlanByKey(planKey);
List<TaskDefinition> tasks = plan.getBuildDefinition().getTaskDefinitions();
for(TaskDefinition task : tasks) {
if(task.getPluginKey().equals(DeploymentTask.KEY) ) {
return true;
}
}
return false;
}
开发者ID:zend-patterns,项目名称:ZendServerBamboo,代码行数:14,代码来源:ZendServerDeploymentDetailsViewCondition.java
示例5: shouldDisplay
import com.atlassian.bamboo.plan.PlanKey; //导入依赖的package包/类
public boolean shouldDisplay(Map<String, Object> context) {
PlanKey planKey = PlanKeys.getPlanKey((String) context.get("planKey"));
Plan plan = planManager.getPlanByKey(planKey);
List<TaskDefinition> tasks = plan.getBuildDefinition().getTaskDefinitions();
for(TaskDefinition task : tasks) {
if(task.getPluginKey().equals(StatisticsTask.KEY) ) {
return true;
}
}
return false;
}