JSON-LD和JSON Schema有什么区别? [英] What are the differences between JSON-LD and JSON Schema?

查看:514
本文介绍了JSON-LD和JSON Schema有什么区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我和JSON一样新.我了解JSON-LD和JSON Schema均用于验证JSON数据.但是,我找不到比较和对比这两者的大量信息.

I'm as new as can be to JSON. I understand that both JSON-LD and JSON Schema are used to validate JSON data. I, however, cannot find much information comparing and contrasting the two.

哪个更好?
为什么要在另一个上使用?
优势与劣势?
可以比较这两个吗?
我是否误解了什么是JSON-LD和JSON模式?

Which one is better?
Why use one over the other?
Advantages vs disadvantages?
Can these two even be compared?
Am I misunderstanding what JSON-LD and JSON Schema are?

推荐答案

JSON-LD的目标是通过将JSON文档链接到定义良好的词汇表,使机器可以理解JSON文档.它不用于验证JSON数据. JSON Schema用于此目的.因此,您无法真正比​​较两者.

JSON-LD's goal is to make JSON documents understandable by machines by linking it to well-defined vocabularies. It is not used to validate JSON data. JSON Schema is used for that purpose though. So you can't really compare the two.

这篇关于JSON-LD和JSON Schema有什么区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆