WebIDL ConstrainablePattern discussion

After consolidating WebIDL from the working draft, I processed it with the
W3 WebIDL checker. The checker had errors regarding the
ConstrainablePattern interface for undefined Capabilities and Settings
types.

Current:

[NoInterfaceObject]
interface ConstrainablePattern {
    *Capabilities*  getCapabilities ();
    Constraints   getConstraints ();
    *Settings*      getSettings ();
    Promise<void> applyConstraints (Constraints constraints);
                attribute EventHandler onoverconstrained;
};


Recommended:

[NoInterfaceObject]
interface ConstrainablePattern {
    *object*  getCapabilities ();
    Constraints   getConstraints ();
    *object*     getSettings ();
    Promise<void> applyConstraints (Constraints constraints);
                attribute EventHandler onoverconstrained;
};


The above changes will pass with the WebIDL Checker. Note, changing *object
*to *any *will work also (as well as other defined types).

----------------

I was confused after reading *11.1 Interface Definition *in regards to
"*limitations
of the interface definition language* used in this specification".

WebIDL states that the *[NoInterfaceObject]* extended attribute should be
solely used on *supplemental *interfaces. IMO, I recommend rephrasing the *11.1
Interface Definition *description. Consider rewording *limitations of the
interface definition language*, and consider adding *supplemental
interface* somewhere
in the description.

Received on Wednesday, 15 April 2015 18:50:53 UTC