number of specified? attributes (of element-expression)?
number of attributes operator returns the number of attributes declared for an element; element-expression can be used to obtain the number of attributes declared for the element referred to by
specified is specified, the
operator is restricted to counting only those attributes that were specified in the instance; any implied
attributes are left out of the count.
The following example uses
number of attributes to determine the number of attributes declared for an
element and that element's parent: