org.eclipse.actf.validation.doc.rulebase
Class ValidationDocumentRuleMapping

java.lang.Object
  extended by org.eclipse.actf.validation.doc.rulebase.ValidationDocumentRuleMapping
All Implemented Interfaces:
IRuleMapping

public class ValidationDocumentRuleMapping
extends Object
implements IRuleMapping


Constructor Summary
protected ValidationDocumentRuleMapping()
           
  ValidationDocumentRuleMapping(Map ruleMap, Set polyRuleTypes, Set nonPolyRuleTypes)
           
 
Method Summary
 List getComponentCriteria(Object component)
           
 Set getNonPolymorphicRuleTypes()
           
 Set getPolymorphicRuleTypes()
           
 Map getRules()
          Returns the complete map of Rules.
 List getRulesForComponent(String id, Object component)
          Retrieve the list of Rules to be used to validate the component.
 void setNonPolymorphicRuleTypes(Set ruleTypes)
           
 void setPolymorphicRuleTypes(Set ruleTypes)
           
 void setRules(Map rules)
          Sets the complete map of Rules.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ValidationDocumentRuleMapping

public ValidationDocumentRuleMapping(Map ruleMap,
                                     Set polyRuleTypes,
                                     Set nonPolyRuleTypes)

ValidationDocumentRuleMapping

protected ValidationDocumentRuleMapping()
Method Detail

getNonPolymorphicRuleTypes

public Set getNonPolymorphicRuleTypes()

getPolymorphicRuleTypes

public Set getPolymorphicRuleTypes()

setNonPolymorphicRuleTypes

public void setNonPolymorphicRuleTypes(Set ruleTypes)

setPolymorphicRuleTypes

public void setPolymorphicRuleTypes(Set ruleTypes)

getRules

public Map getRules()
Description copied from interface: IRuleMapping
Returns the complete map of Rules. The rule names are the keys into the Map while the values are the corresponding IRule objects.

Specified by:
getRules in interface IRuleMapping
Returns:
the map of Rules for all components

getRulesForComponent

public List getRulesForComponent(String id,
                                 Object component)
Description copied from interface: IRuleMapping
Retrieve the list of Rules to be used to validate the component. The list contains a set of rules to be validated for components of a given type including their parents if the component was marked as polymorphic.

Specified by:
getRulesForComponent in interface IRuleMapping
Parameters:
id - - the id of the component (may be null)
component - - component being validated
Returns:
a list of lists of rules to be validated for the given component

setRules

public void setRules(Map rules)
Description copied from interface: IRuleMapping
Sets the complete map of Rules. The rule names are the keys into the Map while the values are the corresponding IRule objects.

Specified by:
setRules in interface IRuleMapping
Parameters:
rules - the map of Rules for all components

getComponentCriteria

public List getComponentCriteria(Object component)