@MustUndestand: When are errors reported?

MURATA Makoto eb2m-mrt at asahi-net.or.jp
Fri Feb 1 07:15:27 CET 2013


Dear colleagues,

I now have 3 questions.

Q1.

Suppose that the root element has a MustUnderstand attribute and the
specified namespace is not understood.  If a SAX-based MCE processor
forwards all start tag events and end tag events to application
programs and then raises a mismatch error, is this MCE processor
conformant?

Q2.

Suppose that the root element has 1000 empty elements as children, the
last empty element has a MustUnderstand attribute, and the specified
namespace is not understood.  If a SAX-based MCE processor scans
an entire document and raises a mismatch error even before forwarding
the start tag event for the root element, is this MCE processor conformant?

Q3.

Consider a DOM-based MCE processor.  It constructs a DOM tree,
and then raises mismatch errors, if any, before returning the tree
to an application program.  Is this MCE processor conformant?

Regards,
Makoto

2013/1/20 MURATA Makoto <eb2m-mrt at asahi-net.or.jp>:
> Dear colleagues,
>
> While preparing examples as part of the MCE semantics wiki,
> I am again wondering when @Mustunderstand is examined
> and why this attribute is needed.
>
> https://www.assembla.com/spaces/IS29500/wiki/Semantics_of_MCE
>
> Even if @Mustunderstand is not used at all, the MCE processor
> is required to report non-understood-and-non-ignorable elements
> and attributes.  (See Step 3 in the semantics wiki.)
>
> Then, why do we need @Mustunderstand?  The only possible
> reason is to raise an error as soon as possible.  Suppose that
> @Mustunderstand  of a root element specifies a non-understood
> namespace.  We would expect that the MCE processor report an
> error without forwarding anything to the application program.
> We would expect that not using @Mustunderstand will delay
> errors: a lot more info will be forwarded to application programs.
>
> But our current definition of the MCE semantics in the wiki is
> different from this expectation.  It is Step 3 that checks
> non-understood-and-non-ignorable elems/atts
> as well as @Mustunderstand.  Step 3 is followed by
> Step 4.  So, the use of @Mustunderstand does not make
> any real differences.  Errors will be raised before forwarding
> something to the application program.
>
> I guess that we have to revise the current definition.  But
> we also have to make sure that @MustUnderstand and foreign
> attributes of AlternateContent, Choice, and Fallback elements
> as well as foreign children of AlternateContent elements
> are examined.  Since all of them are discarded by Step 4,
> we have to checking before Step 4. I don't know how we
> can overcome this dilemma.
>
>
> Regards,
> Makoto



-- 

Praying for the victims of the Japan Tohoku earthquake

Makoto


More information about the sc34wg4 mailing list