hudson.plugins.cigame.model
Class RuleSet

java.lang.Object
  extended by hudson.plugins.cigame.model.RuleSet
Direct Known Subclasses:
BuildRuleSet, PluginRuleSet, UnitTestingRuleSet

public class RuleSet
extends java.lang.Object

Class containing one or more rules

Author:
Erik Ramfelt

Constructor Summary
RuleSet(java.lang.String name)
           
RuleSet(java.lang.String name, java.util.Collection<Rule> rules)
           
 
Method Summary
 void add(Rule rule)
          Add rule to the rule set
 java.lang.String getName()
          Returns the name of the rule set.
 java.util.Collection<Rule> getRules()
          Returns the rules for this rule set.
 boolean isAvailable()
          Returns if the rule set is available or not.
 void removeRule(Rule rule)
          Remove rule from the rule set.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RuleSet

public RuleSet(java.lang.String name,
               java.util.Collection<Rule> rules)

RuleSet

public RuleSet(java.lang.String name)
Method Detail

isAvailable

public boolean isAvailable()
Returns if the rule set is available or not. If a rule set is not available then it will not be used for determining the score for a build Default implementation returns true.

Returns:
true

getName

public java.lang.String getName()
Returns the name of the rule set.

Returns:
the name of the rule set.

getRules

public java.util.Collection<Rule> getRules()
Returns the rules for this rule set.

Returns:
the rules for this rule set.

add

public void add(Rule rule)
Add rule to the rule set

Parameters:
rule - rule to add to the set.

removeRule

public void removeRule(Rule rule)
Remove rule from the rule set.

Parameters:
rule - the rule to remove.


Copyright © 2008. All Rights Reserved.