org.eclipse.actf.validation.rules
Interface IRuleSet

All Known Implementing Classes:
ValidationDocumentRuleSet

public interface IRuleSet

captures a set of rules in ACTF. A ruleset is a collection of rules in a rulebase. Each ruleset can be enabled or disabled and, if enabled, each rule within the ruleset can be enabled or disabled. Rulesets are also associated with execution points so that collections of rules can be applied at different points throughout a process.

Author:
John Buslawski
See Also:
ExecutionPoint, IRuleBase

Method Summary
 void addRule(IRule rule)
          add a rule to this ruleset
 String getExecutionPointName()
          get the name of the execution point descriptor that triggers rules in this ruleset
 String getName()
          get the name of this ruleset
 IRule getRule(String name)
          get the rule with the given name
 IRuleBase getRuleBase()
          get the rulebase to which this ruleset belongs
 IRuleFactory getRuleFactory()
          get the rule factory responsible for creating rules in this ruleset
 IRule[] getRules()
          return all of the rules within this ruleset
 boolean isEnabled()
          return whether or not this ruleset is enabled
 void removeRule(String name)
          remove the rule with the given name
 void setEnabled(boolean enabled)
          set whether or not this ruleset is enabled.
 void setExecutionPoint(String name)
          set the name of the execution point that triggered this ruleset \
 void setName(String name)
          set the name of this ruleset
 void setRuleBase(IRuleBase iRuleBase)
          set the rulebase to which this ruleset belongs
 void setRuleFactory(IRuleFactory factory)
          set the rule factory for this ruleset.
 

Method Detail

getName

String getName()
get the name of this ruleset

Returns:
name of ruleset

setName

void setName(String name)
set the name of this ruleset

Parameters:
name -

isEnabled

boolean isEnabled()
return whether or not this ruleset is enabled

Returns:
true if this ruleset is enabled, false otherwise
See Also:
setEnabled(boolean)

setEnabled

void setEnabled(boolean enabled)
set whether or not this ruleset is enabled. If a ruleset is enabled, each of the validation rules within the set can be enabled or disabled. Disabling this ruleset disables all validation rules within the set.

Parameters:
enabled -

addRule

void addRule(IRule rule)
add a rule to this ruleset

Parameters:
rule -

removeRule

void removeRule(String name)
remove the rule with the given name

Parameters:
name - name of rule to be removed

getRules

IRule[] getRules()
return all of the rules within this ruleset

Returns:
all rules within this ruleset

getRule

IRule getRule(String name)
get the rule with the given name

Parameters:
name - name of desired rule
Returns:
rule with the given name or null if no such rule exists in this ruleset

getRuleFactory

IRuleFactory getRuleFactory()
get the rule factory responsible for creating rules in this ruleset

Returns:
rule factory

setRuleFactory

void setRuleFactory(IRuleFactory factory)
set the rule factory for this ruleset. The rule factory set should generate all rules in this ruleset.

Parameters:
factory -

getExecutionPointName

String getExecutionPointName()
get the name of the execution point descriptor that triggers rules in this ruleset

Returns:
name of execution point that triggered this ruleset

setExecutionPoint

void setExecutionPoint(String name)
set the name of the execution point that triggered this ruleset \

Parameters:
name - name of executionPoint

getRuleBase

IRuleBase getRuleBase()
get the rulebase to which this ruleset belongs

Returns:
rulebase to which this ruleset belongs

setRuleBase

void setRuleBase(IRuleBase iRuleBase)
set the rulebase to which this ruleset belongs

Parameters:
iRuleBase -