W3C home > Mailing lists > Public > public-rdfa-wg@w3.org > February 2012

Re: ISSUE-127 (Empty Lists?): What is the effect of @inlist when no triples are generated? [3rd LC Comments - RDFa 1.1 Core]

From: Niklas Lindström <lindstream@gmail.com>
Date: Thu, 23 Feb 2012 10:58:13 +0100
Message-ID: <CADjV5jfaESD5Oqj23JtpAXuoidPw9ik0bC5+cqhs5=Tj63RJDA@mail.gmail.com>
To: RDF Web Applications Working Group <public-rdfa-wg@w3.org>
This is an interesting question. I can think of arguments for both
sides of the issue.

One perspective is that @inlist "collects" members and then puts them
in a list if there were any collected.

Another perspective might consider @inlist to create the list
immediately. This way, it's also more natural to create an empty list
if one intends to, rather than using rdf:nil (which is reasonably too
technical for casual use). While this can be seen as a difference to
how hanging rels behave, I think the difference really lies in the
difference between a concrete list of items, and the (perhaps harder
to grasp) case of producing multiple statements with the hanging rel
"magic". (We had a similar discussion on the JSON-LD telecon

Compare this to RDF/XML:

  <owl:Class rdf:about="#c">
    <owl:unionOf rdf:parseType="Collection"/>

which produces:

  <#c> owl:unionOf () .

If one does not want an empty list, one should either leave out the
@inlist, or better leave out the entire "list wrapper". This is just
like how one have to use a condition for an <ul> depending on whether
there will be any <li>:s (since <ul> is not allowed to be empty in
HTML). Like in this pseudo-code template:

  {% if items %}
    <ul rel="owl:unionOf" inlist>
      {% for item in items %}
        <li resource="{{ item.iri }}">{{ item.label }}</li>
      {% endfor %}
  {% endif %}

Does anyone have more concrete usage examples we can consider, to
determine which way would be most confusing for authors?

Best regards,

On Thu, Feb 9, 2012 at 11:26 AM, RDF Web Applications Working Group
Issue Tracker <sysbot+tracker@w3.org> wrote:
> ISSUE-127 (Empty Lists?): What is the effect of @inlist when no triples are generated? [3rd LC Comments - RDFa 1.1 Core]
> http://www.w3.org/2010/02/rdfa/track/issues/127
> Raised by: Ivan Herman
> On product: 3rd LC Comments - RDFa 1.1 Core
> See http://www.w3.org/mid/CA894838-BFE8-48CC-984D-F304A6D32251@w3.org for further details, this is just to add this question to the issue list.
Received on Thursday, 23 February 2012 09:59:10 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 17:05:30 UTC