Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The issue there is the complexity is necessary for some cases which are not met in trivial cases. E.g. When including element names from two sources. That is not a common use in json but with schemas you will come across it


And that could not be handled by making an optional namespace which can be used when it is actually needed?

Even without namespaces, it's trivial to handle { "NamespaceA": {....}, "NamespaceB": {....}, }

There is seldom need to mix it in the same object, and if you need that, you should think long and hard if you are on the right track.


Isn't that what XML did - you only put the namespace in if it was needed.

As for multiple ones in the same object it makes sense if you want to reuse a definition used elsewhere e.g. to add an address using a predefined address type. It is like using structures/records in programming languages but with no pointers for composition.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: