Hi Pirent (or should I say Hi Lattikas?)
I see. That suggests we'll either need to pick a standard locale
for Elda or have a way of configuring a locale in the LDA config.
Perhaps a variable that names the required locale and maybe
a format string for SimpleFormat rather than the current one.
--
You received this message because you are subscribed to the Google Groups "linked-data-api-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to linked-data-api-d...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
-- Epimorphics Ltd www.epimorphics.com Court Lodge, 105 High Street, Portishead, Bristol BS20 6PT Tel: 01275 399069 Epimorphics Ltd. is a limited company registered in England (number 7016688) Registered address: Court Lodge, 105 High Street, Portishead, Bristol BS20 6PT, UK
hasDate: "Fri, 01 May 2015"
hasDate: { _value: "2015-05-01Z", _datatype: "date"}
hasDate: "2015-05-01"
Hello Stuart.
To maybe explain better, what I would like to achieve, I would bring an example.
For example for one endpoint we have a property named hasDate with a value of xsd:date. With the current elda version and without api:structured, the JSON response looks like this:
hasDate: "Fri, 01 May 2015"
When I change configuration file to include api:structured on property hasDate, the result with current elda version looks like this:
hasDate: {_value: "2015-05-01Z",_datatype: "date"}I would like to implement a variable or some other solution that would allow me to specify that the xsd:date value would be returned in a format "yyyy-MM-dd" and xsd:dateTime in format "yyyy-MM-dd'T'HH:mm:ss'Z'". So in my example the returned value for hasDate would be:
hasDate: "2015-05-01"
Ok... elda already does more in that respect than I'd
expected. I'm curious about your locale and time-offset setup. Is
the date in the data truely expressed as with a time offet of
'Z', and if so is that also how you want it expressed. Or would
you expect the date to be expressed with your local offset
(whatever that may be). Or is it in the data as an un-zoned local
date in which case I'd not expect the trailing 'Z' offset.
Also, are you getting the correct offsets that you want with
dateTimes (given appropriate setup of the JVM properties).
Hope this makes it more clear, what I would like to achieve. The api:structured actually already let's us return the value as it is returned from the database in JSON and that would be ok, but we wouldn't like to add extra fields of "_value" and "_datatype" to keep the response as short and clear as possible.
--
Sincerely.
Piret
I'm curious about your locale and time-offset setup. Is the date in the data truely expressed as with a time offet of 'Z', and if so is that also how you want it expressed. Or would you expect the date to be expressed with your local offset (whatever that may be). Or is it in the data as an un-zoned local date in which case I'd not expect the trailing 'Z' offset.
Also, are you getting the correct offsets that you want with dateTimes (given appropriate setup of the JVM properties).
created: "Tue, 23 Apr 2013 08:29:29 GMT+0000"
created: { _value: "2013-04-23T08:29:29Z", _datatype: "dateTime"}
Hello Stuart.
I'm curious about your locale and time-offset setup. Is the date in the data truely expressed as with a time offet of 'Z', and if so is that also how you want it expressed. Or would you expect the date to be expressed with your local offset (whatever that may be). Or is it in the data as an un-zoned local date in which case I'd not expect the trailing 'Z' offset.
Also, are you getting the correct offsets that you want with dateTimes (given appropriate setup of the JVM properties).
The locale of my machine is "et_EE", in the example I posted previously I used the JVM property user.language=en, as proposed by you previously, to get month name in english. Date is inserted to virtuoso actually without the timezone, so as a un-zoned date.
With dateTime I get the following result without api:structured:
created: "Tue, 23 Apr 2013 08:29:29 GMT+0000"
And with api:structured set to true on property created:
created: {_value: "2013-04-23T08:29:29Z",_datatype: "dateTime"}
In case of dateTime _value reflects exactly what we wish to achieve.
I'll stand aside on the question of how to configure an unstructured 8601 format date/dateTime within an Elda configuration.Sincerely.
Piret
If there is no-zone offset in the data, I'd expect the output to be unzoned.
I'll stand aside on the question of how to configure an unstructured 8601 format date/dateTime within an Elda configuration.