Re: enhancement request - make "@" unreserved.
Trans <[email protected]>
| Newsgroups | gmane.text.yaml.general |
|---|---|
| Message-ID | <CAEu+kw3fxGFLEQHaWkUEVr3L_iTVk2_pcFFknWjuhUy4k5AZWA@mail.gmail.com> |
Taking the JSON-LD example:
{
"@context": {
"name": "http://xmlns.com/foaf/0.1/name",
"homepage": {
"@id": "http://xmlns.com/foaf/0.1/workplaceHomepage",
"@type": "@id"
},
"Person": "http://xmlns.com/foaf/0.1/Person"
},
"@id": "http://me.markus-lanthaler.com",
"@type": "Person",
"name": "Markus Lanthaler",
"homepage": "http://www.tugraz.at/"}
I imagine the YAML would be something like:
%TAG !foaf! http://xmlns.com/foaf/0.1/
--- !foaf!Personname: !foaf!name Markus Lanthalerhomepage:
!foaf!workplaceHomepage http://www.tugraz.at/
How much sexier is that!? Note, the only thing I'm not sure about is the
@id (me.markus-lanthaler.com). Maybe there is room for a new %ID directive?
In the future (though I have already long expected) we'd eventually be able
to do something like:
%SCHEMA !foaf! http://xmlns.com/foaf/0.1/foaf.yes
--- !foaf!Personname: Markus Lanthalerhomepage: http://www.tugraz.at/
The %SCHEMA directive would link to a schema document that defines how the
structure of the document can determines types, plus extra tags available
for use, validations and more.
trans
------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
_______________________________________________
Yaml-core mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/yaml-core