Schema.org:如何扩展类或类型 [英] Schema.org: How to extend a Class or Type

查看:48
本文介绍了Schema.org:如何扩展类或类型的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须为一个产品建模,该产品具有未在 Schema.org Product 类型中列出的属性.找了很多地方,都没有找到适合我的.如何扩展 Schema.org Product 类型?

I have to model a product, which has properties that aren't listed in the Schema.org Product type. After seeking in many places, I didn't find anything that fits to my need. How can I extend the Schema.org Product type?

推荐答案

除了 Schema.org 之外,您始终可以使用其他词汇表(提供您需要的属性).但是,如果您只想使用词汇表 Schema.org,通常有两种选择:

You could always use other vocabularies (that offer the properties you need) in addition to Schema.org. But if you want to use only the vocabulary Schema.org, you have two options in general:

  • 提出新的属性(或类).

  • Propose new properties (or classes).

您可以在 Schema.org W3C 社区组邮件列表,或Schema.org 的 GitHub 问题跟踪器.

请参阅:我如何参与?我如何提出新的架构或其他改进?

如果被接受,它可能成为核心的一部分(如果它是最常见的 Web 应用程序需要"的东西),或者它可能 成为扩展.

If accepted, it might become part of the core (if it’s something "the most common web applications need"), or it might become an extension.

(已弃用!)扩展现有属性.

扩展现有属性记录在 http://schema.org/docs/old_extension.html,但请注意,此机制被认为已过时.

Extending existing properties is documented at http://schema.org/docs/old_extension.html, but note that this mechanism is considered outdated.

对于特定类型(包括 Product),您可以使用 Schema.org 的 additionalProperty 属性:

For specific types (including Product), you can use Schema.org’s additionalProperty property:

表示实体附加特征的属性-值对,例如schema.org 中没有匹配属性的产品特性或其他特性.

A property-value pair representing an additional characteristics of the entitity, e.g. a product feature or another characteristic for which there is no matching property in schema.org.

这篇关于Schema.org:如何扩展类或类型的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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