hudson.plugins.promoted_builds.conditions
Class DownstreamPassCondition

java.lang.Object
  extended by hudson.plugins.promoted_builds.PromotionCondition
      extended by hudson.plugins.promoted_builds.conditions.DownstreamPassCondition
All Implemented Interfaces:
hudson.ExtensionPoint, hudson.model.Describable<PromotionCondition>

public class DownstreamPassCondition
extends PromotionCondition

PromotionCondition that tests if certain downstream projects have passed.

Author:
Kohsuke Kawaguchi

Nested Class Summary
static class DownstreamPassCondition.Badge
           
static class DownstreamPassCondition.DescriptorImpl
           
 
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
hudson.ExtensionPoint.LegacyInstancesAreScopedToHudson
 
Constructor Summary
DownstreamPassCondition(java.lang.String jobs)
           
 
Method Summary
 boolean contains(hudson.model.AbstractProject<?,?> job)
          Short-cut for getJobList().contains(job).
 PromotionConditionDescriptor getDescriptor()
           
 java.util.List<hudson.model.AbstractProject<?,?>> getJobList()
          List of downstream jobs that we need to monitor.
 java.lang.String getJobs()
           
 PromotionBadge isMet(hudson.model.AbstractBuild<?,?> build)
          Checks if the promotion criteria is met.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DownstreamPassCondition

public DownstreamPassCondition(java.lang.String jobs)
Method Detail

getJobs

public java.lang.String getJobs()

isMet

public PromotionBadge isMet(hudson.model.AbstractBuild<?,?> build)
Description copied from class: PromotionCondition
Checks if the promotion criteria is met.

Specified by:
isMet in class PromotionCondition
Parameters:
build - The build for which the promotion is considered.
Returns:
non-null if the promotion condition is met. This object is then recorded so that we know how a build was promoted. Null if otherwise, meaning it shouldn't be promoted.

getDescriptor

public PromotionConditionDescriptor getDescriptor()
Specified by:
getDescriptor in interface hudson.model.Describable<PromotionCondition>
Specified by:
getDescriptor in class PromotionCondition

getJobList

public java.util.List<hudson.model.AbstractProject<?,?>> getJobList()
List of downstream jobs that we need to monitor.

Returns:
never null.

contains

public boolean contains(hudson.model.AbstractProject<?,?> job)
Short-cut for getJobList().contains(job).



Copyright © 2009. All Rights Reserved.