Explicitly define properties which are arrays / collections. #3371
Replies: 2 comments 1 reply
-
|
If such a distinction were specified, I expect it would be a property of each Property, but schema.org itself does not define such a property. OWL 2 defines owl:FunctionalProperty and owl:maxCardinality but those are not referenced in https://github.com/schemaorg/schemaorg/blob/main/data/releases/22.0/schemaorg.owl. |
Beta Was this translation helpful? Give feedback.
-
|
IMO, the cleanest and most state-of-the-art way of adding this feature (aka "cardinality constraints") to schema.org would be providing a SHACL shape definition that either specifies the entire schema.org vocabulary in an alternative formalism, or an isolated "schema.org data quality" SHACL shape. For examples, see e.g. here. @danbri - maybe you could comment on plans re adding SHACL shapes for data quality rules in schema.org. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Is there anyway to determine if a property can be an array / collection of children or a single value?
Example: https://schema.org/ItemList
The itemListElement property example is an array, but the numberOfItems property is an
Integer.{ "@context": "https://schema.org", "@type": "ItemList", "url": "http://multivarki.ru?filters%5Bprice%5D%5BLTE%5D=39600", "numberOfItems": "315", "itemListElement": [ { "@type": "Product", "image": "http://img01.multivarki.ru.ru/c9/f1/a5fe6642-18d0-47ad-b038-6fca20f1c923.jpeg", "url": "http://multivarki.ru/brand_502/", "name": "Brand 502", "offers": { "@type": "Offer", "priceCurrency": "RUB", "price": "4399.00" } }, { "@type": "Product", "name": "..." } ] }Beta Was this translation helpful? Give feedback.
All reactions