Re: [web-annotation] Using xsd:date, too, in the model?

> On 25 Jan 2016, at 17:44, Stian Soiland-Reyes 
<notifications@github.com> wrote:
> 
> The RDFS definition of dcterms:W3CDTF shows it as a rdfs:Datatype - 
so it would indeed be valid to use it @type on a literal (and wrong to
 use it as a property as COMBINE did)
> 
> dcterms:W3CDTF
>     dcterms:hasVersion 
<http://dublincore.org/usage/terms/history/#W3CDTF-003> ;
>     dcterms:issued 
"2000-07-11"^^<http://www.w3.org/2001/XMLSchema#date> ;
>     dcterms:modified 
"2008-01-14"^^<http://www.w3.org/2001/XMLSchema#date> ;
>     a rdfs:Datatype ;
>     rdfs:comment "The set of dates and times constructed according 
to the W3C Date and Time Formats Specification."@en ;
>     rdfs:isDefinedBy <http://purl.org/dc/terms/> ;
>     rdfs:label "W3C-DTF"@en ;
>     rdfs:seeAlso <http://www.w3.org/TR/NOTE-datetime> .
> aka it could be any of these:
> 
>    Year:
>       YYYY (eg 1997)
>    Year and month:
>       YYYY-MM (eg 1997-07)
>    Complete date:
>       YYYY-MM-DD (eg 1997-07-16)
>    Complete date plus hours and minutes:
>       YYYY-MM-DDThh:mmTZD (eg 1997-07-16T19:20+01:00)
>    Complete date plus hours, minutes and seconds:
>       YYYY-MM-DDThh:mm:ssTZD (eg 1997-07-16T19:20:30+01:00)
>    Complete date plus hours, minutes, seconds and a decimal fraction
 of a second
>       YYYY-MM-DDThh:mm:ss.sTZD (eg 1997-07-16T19:20:30.45+01:00)
> It would still be confusing without specifying deeper how to use 
dcterms:W3CDTF as the DC Terms page is not very helpful.
> 


As a very very practical point: all usual time libraries ("moment" 
library for Javascript, built in datetime facilities for python, etc) 
have functions/methods to handle all those various date formats, both 
for parsing and for generating. It looks a little bit silly if we 
force the user to use only one of those if there is a way to handle 
the union of those properly.

If we want to be on the very formal side in RDF land, we could look at
 the OWL2 datatype creation facilities whether that can be used, ie, 
to define a new datatype properly. But, at least at first glance, this
 W3CDTF does work for me...





-- 
GitHub Notification of comment by iherman
Please view or discuss this issue at 
https://github.com/w3c/web-annotation/issues/141#issuecomment-174588649
 using your GitHub account

Received on Monday, 25 January 2016 17:10:18 UTC