Hi there,
I'm reviewing some of the Linux Open Printing GSoC contributions, and one of them is a test suite for PWG 5100.7. In reviewing that, I came across how to test for the support of "document-charset". It seems awkward to me, and I wonder if there is an attribute design lesson here to be learned.
PWG 5100.7-2019 includes this:
5.5.1 document-charset-default (charset)
This CONDITIONALLY REQUIRED attribute specifies the default charset that the Printer will assume for charset-ambiguous Document formats when the Client omits the “document- charset” operation attribute [PWG5100.5]. Printers that support the "document-charset" operation attribute MUST support this attribute.
5.5.2 document-charset-supported (1setOf charset)
This CONDITIONALLY REQUIRED attribute lists the charsets that the Printer supports for charset-ambiguous Document formats. Printers that support the "document-charset" operation attribute [PWG5100.5] MUST support this attribute.
And PWG 5100.5 has this:
6.4.1 document-charset (charset)
This RECOMMENDED operation attribute specifies the character set used by the Document data.
This is kind of a chicken-and-egg problem from a normative language / testability point of view. If the former two are CONDITIONALLY REQUIRED depending on whether the Printer supports the latter, how does one determine whether the Printer supports it? (Of course it is kind of a bummer that these are spread across two specs...). It seems to me that the document-charset-default and document-charset-supported should be RECOMMENDED and the document-charset should be CONDITIONALLY REQUIRED depending on whether the document-charset-default and document-charset-supported attributes are supported.
The more general design pattern or principle would be to mandate that the definitions of the Printer Description attribute(s) indicating attribute feature support to be the "primary" normative indicators.
(All that said, I am not sure we want to twiddle the normative language in 5100.5 / 5100.7 to resolve this. But now might be an opportune time to do so.)
Smith
/**
Smith Kennedy
HP Inc.
*/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.pwg.org/pipermail/ipp/attachments/20190822/6a3fe3fa/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: Message signed with OpenPGP
URL: <http://www.pwg.org/pipermail/ipp/attachments/20190822/6a3fe3fa/attachment.sig>