<create-rule> is used to specify the criteria for creating a new object as a result of an <add> event.
When a <create-rule> is evaluated, it first checks whether or not this is a suitable rule for the <add> event in question. It does this by checking if a class-name is specified by the rule. If so then the rule is only suitable if the class-name matches the class-name on the event. It then checks if any <match-attr> criteria is specified by the rule. If so, the the rule is only suitable if the <add> contains all the attribute values required by the <match-attr>. If a rule is determined to not be suitable it is skipped.
Once a suitable rule is found, the <add> is evaluated to see if it has a value for all of the <required-attr> that do not contain a default value. If not, the <add> is vetoed, otherwise it is allowed. Then any required attributes with default values that were missing from the <add> are filled in and the template-dn attribute is filled in if a <template> is specified.
Example
See <create-rules>
- match-attr
- Match an attribute.
- required-attr
- Required attribute.
- template
- Required attribute.
Attribute Value(s) Default Value class-name CDATA
The name of the base class of the objects this rule applies to in the NDS namespace. If empty or not present, then this rule applies to all base classes.#IMPLIED description CDATA
Description of this rule, primarily for use in ConsoleOne.#IMPLIED
( match-attr * , required-attr * , template ? )
- create-rules
- Top level element for object creation rules.
Top Elements || All Elements || Tree