com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data
Class Branch

java.lang.Object
  extended by hudson.model.AbstractDescribableImpl<Branch>
      extended by com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.Branch
All Implemented Interfaces:
hudson.model.Describable<Branch>

public class Branch
extends hudson.model.AbstractDescribableImpl<Branch>

Represents a rule for triggering on a branch of a GerritProject.

Author:
Robert Sandell <robert.sandell@sonyericsson.com>

Nested Class Summary
static class Branch.DescriptorImpl
          The Descriptor for the Branch.
 
Constructor Summary
Branch()
          Default empty constructor.
Branch(CompareType compareType, java.lang.String pattern)
          Default DataBound constructor.
 
Method Summary
 CompareType getCompareType()
          The CompareType used.
 java.lang.String getPattern()
          The pattern to match on.
 boolean isInteresting(java.lang.String branch)
          Tells if the given branch is matched by this rule.
 void setCompareType(CompareType compareType)
          The CompareType used.
 void setPattern(java.lang.String pattern)
          The pattern to match on.
 
Methods inherited from class hudson.model.AbstractDescribableImpl
getDescriptor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Branch

public Branch()
Default empty constructor.


Branch

@DataBoundConstructor
public Branch(CompareType compareType,
                                   java.lang.String pattern)
Default DataBound constructor.

Parameters:
compareType - the CompareType to use when comparing with the pattern.
pattern - the pattern to match on.
Method Detail

getCompareType

public CompareType getCompareType()
The CompareType used.

Returns:
the CompareType

setCompareType

public void setCompareType(CompareType compareType)
The CompareType used.

Parameters:
compareType - the compareType.

getPattern

public java.lang.String getPattern()
The pattern to match on.

Returns:
the pattern

setPattern

public void setPattern(java.lang.String pattern)
The pattern to match on.

Parameters:
pattern - the pattern.

isInteresting

public boolean isInteresting(java.lang.String branch)
Tells if the given branch is matched by this rule.

Parameters:
branch - the branch
Returns:
true if the branch matches.


Copyright © 2004-2012. All Rights Reserved.