The OptionalRule allows you to have a field where a rule is applied *only* when the value actually exists.
Located in /harmoni/core/utilities/FieldSetValidator/rules/OptionalRule.class.php (line 16)
ValidatorRuleInterface | --OptionalRule
the rule to be used for the values set
the constructur
checks a given value to see if it's set (returns true if not), and then runs the rule on it.
This is a static method to return an already-created instance of a validator rule. There are at most about a hundred unique rule objects in use durring any given execution cycle, but rule objects are instantiated hundreds of thousands of times.
This method follows a modified Singleton pattern.
Return a key that can be used to identify this Rule for caching purposes.
If this rule takes no arguments, the class name should be sufficient. otherwise, append the arguments.
This method should only be called by ValidatorRules.
Inherited From ValidatorRuleInterface
ValidatorRuleInterface::check()
ValidatorRuleInterface::getRule()
ValidatorRuleInterface::getRuleKey()
Documentation generated on Wed, 19 Sep 2007 10:25:17 -0400 by phpDocumentor 1.3.0RC3