Help:Mandatory parent datatype inheritance
Mandatory parent datatype inheritance was introduced with Semantic MediaWiki 3.1.0Released on 23 September 2019 and compatible with MW 1.31.0 - 1.33.x. which added configuration parameter $smwgMandatorySubpropertyParentTypeInheritance
No description was provided.12 as an option to enforce that a subproperty requires the same datatype as the parent property.
When disabled by setting this configuration parameter to "false
" (done by default to ensure legacy behaviour), a warning will appear on the property page to inform the user about the type mismatch.
Yet, if enabled by setting this configuration parameter to "true
" and the user added a different datatype (in references to the parent property) then an error message will be shown and the annotated datatype is forcibly removed though the page content is not altered. This is why an error message is shown to ensure the user removes the erroneous datatype or modifies it to match the parent property datatype.
See also[edit]
- Help page on special property "Subproperty of"Lets you indicate that one property is a subproperty of another
- Help page on configuration parameter
$smwgMandatorySubpropertyParentTypeInheritance
No description was provided. - Help page on configuration parameter
$smwgPDefaultType
Sets the default datatype for a property if it was not defined manually
References
- ^ | Semantic MediaWiki: GitHub issue gh:smw:3528
- ^ | Semantic MediaWiki: GitHub pull request gh:smw:3733