org.sapia.validator
Class RuleSet

java.lang.Object
  extended by org.sapia.validator.RuleSet
All Implemented Interfaces:
org.sapia.util.xml.confix.ObjectHandlerIF, Validatable

public class RuleSet
extends Object
implements Validatable, org.sapia.util.xml.confix.ObjectHandlerIF

This class models a set of rules

Author:
Yanick Duchesne
Copyright:
Copyright © 2002-2003 Sapia Open Source Software. All Rights Reserved.
License:
Read the license.txt file of the jar or visit the license page at the Sapia OSS web site

Constructor Summary
RuleSet()
          Constructor for RuleSet.
 
Method Summary
 void addValidatable(Validatable v)
          Adds a Validatable to this instance.
 RuleSet createRuleSet()
          Adds a rule set to this instance and returns it.
 String getId()
          Returns this instance's unique identifier.
 void handleObject(String name, Object validatable)
           
 void setId(String id)
          Sets this instance's identifier.
 void setStop(boolean stop)
           
 void validate(ValidationContext ctx)
          Validates this instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RuleSet

public RuleSet()
Constructor for RuleSet.

Method Detail

setId

public void setId(String id)
Sets this instance's identifier.

Parameters:
an - identifier, as a string.

getId

public String getId()
Description copied from interface: Validatable
Returns this instance's unique identifier.

Specified by:
getId in interface Validatable
Returns:
a unique identifier.
See Also:
Validatable.getId()

addValidatable

public void addValidatable(Validatable v)
Adds a Validatable to this instance.

Parameters:
v - a Validatable instance.

createRuleSet

public RuleSet createRuleSet()
Adds a rule set to this instance and returns it.

Returns:
a RuleSet instance.

setStop

public void setStop(boolean stop)
See Also:
CompositeRule.setStop(boolean)

validate

public final void validate(ValidationContext ctx)
Description copied from interface: Validatable
Validates this instance.

Specified by:
validate in interface Validatable
See Also:
Validatable.validate(ValidationContext)

handleObject

public void handleObject(String name,
                         Object validatable)
                  throws org.sapia.util.xml.confix.ConfigurationException
Specified by:
handleObject in interface org.sapia.util.xml.confix.ObjectHandlerIF
Throws:
org.sapia.util.xml.confix.ConfigurationException
See Also:
ObjectHandlerIF.handleObject(String, Object)


Copyright © 2002 Sapia Open Community, Inc. All Rights Reserved.