OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

xliff-omos message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Re: [xliff-omos] Modules and extensions


Hi Yves and Phil,

json-ld does not have the notion of namespaces, see the json-ld spec
http://www.w3.org/TR/json-ld/
the term namespace appears just one time. Rather, json-ld provides means to express URIs in a compact form, see
http://www.w3.org/TR/json-ld/#compact-iris

But the full form are still URIs. E.g. in example 20 in the json-ld spec, 
foaf:name
is a short form for http://xmlns.com/foaf/0.1/name

I do not understand the full requirements for separating XLIFF sub vocabularies (to use a neutral term). But no need to discuss this further here. I will look at the thread and see if I can come up with a json-ld example later.

Cheers,

Felix




2017-05-25 14:27 GMT+02:00 Yves Savourel <ysavourel@enlaso.com>:

Thanks for the reminder Felix.

Like Phil, I’m just wondering about the cost of JSON-LD when various namespaces are mixed in the same object.

Looking at examples such as those here: https://json-ld.org/spec/latest/json-ld-api-best-practices/#dfn-json-ld-context, the resolution of the namespaces seems relatively complicated and changes the object structure. But I’m probably missing a lot.

 

Cheers,

-yves

 

Yves Savourel
Localization Solutions Architect
| t: 303.951.4523 | f: 303.516.1701 | ENLASO®

 

From: Felix Sasaki [mailto:felix@sasakiatcf.com]
Sent: Thursday, May 25, 2017 12:55 AM


To: Yves Savourel <ysavourel@enlaso.com>
Cc: XLIFF OMOS TC <xliff-omos@lists.oasis-open.org>
Subject: Re: [xliff-omos] Modules and extensions

 

Hi Yves, all,

 

previously in this thread people said they are worried about ad hoc created namespace resolution systems. I understand the worry about json-ld complexity, but at least it is a standard solution, with many libraries available. Just my two cent ...

 

(I understand that it is likely that people won't go the json-ld path, this is just my last attempt to mention this approach)

 

- Felix 

 

 

2017-05-25 4:28 GMT+02:00 Yves Savourel <ysavourel@enlaso.com>:

Hi Robert, all,

 

Ø  I’m inclined to stick to _ to separate prefix from name, assuming _ are forbidden in prefixes and names by self-imposed JLIFF conventions. Underscore is at least widely supported in variable names.

 

A ‘_’ would be fine with me.

I was just under the impression ‘$’ was the preference for you (and maybe others).

I just wanted to be sure it would work with _javascript_.

 

Ø  Other programming languages may not accept $ in hard-coded property/variable names…

 

Quite right. But I wonder if it matters: Languages other than _javascript_ are likely to go through some kind of marshalling of the JSON data into their own data structures and have ways to address such issue. Actually _javascript_ is probably a special case: the more I work on JLIFF, the more I think it’d be quite hard for most languages to just rely on default automated mapping mechanism to get the proper input/output. But hopefully I’m wrong.

 

Cheers,

-yves

 

 

From: Robert van Engelen [mailto:engelen@genivia.com]
Sent: Tuesday, May 23, 2017 11:11 AM
To: Yves Savourel <ysavourel@enlaso.com>
Cc: XLIFF OMOS TC <xliff-omos@lists.oasis-open.org>
Subject: Re: [xliff-omos] Modules and extensions

 

 

I’m inclined to stick to _ to separate prefix from name, assuming _ are forbidden in prefixes and names by self-imposed JLIFF conventions. Underscore is at least widely supported in variable names.

 

Other programming languages may not accept $ in hard-coded property/variable names (i.e. console.log(x.name.b) is "hard-coded" and so is console.log(x[“name.b”]) also hard-coded, but with a period in the property name that requires quotes).

 

- Robert

 

 

  Dr. Robert van Engelen, CEO/CTO Genivia Inc.
  voice: (850) 270 6179 ext 104
  fax: (850) 270 6179
  mobile: (850) 264 2676
  engelen@genivia.com

 

On May 23, 2017, at 1:03 PM, Yves Savourel <ysavourel@enlaso.com> wrote:

 

Regarding separator, from quick tests:

 

Dollar-sign would work, but not period, IMO:

 

var x = {"name$b": "text"};

console.log(x.name$b); à ok

 

var x = {"name.b": "text"};

console.log(x.name.b); à error

 

More tests are probably needed.

 

cheers,

-yves

 

 




[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]