|Found errors or typos? Just edit the page or leave a message on the talk page.|
The English language documentation is canonical and most up to date.
Configuration parameter "$smwgDVFeatures"
|Configuration parameter details:|
|Description||Sets the available features regarding property data values|
|Default setting||See below|
|Until version||still available|
|Keyword||output · display · datavalue|
$smwgDVFeatures is a configuration parameter that sets the available features regarding property data values. The configuration parameter was introduced in Semantic MediaWiki 2.4.0Released on 9 July 2016 and compatible with MW 1.19.0 - 1.27.x..1
$smwgDVFeatures = SMW_DV_PROV_REDI | SMW_DV_MLTV_LCODE | SMW_DV_PVAP | SMW_DV_WPV_DTITLE | SMW_DV_TIMEV_CM | SMW_DV_PPLB | SMW_DV_PROV_LHNT;
SMW_DV_NONE– Disables features to property data values
SMW_DV_PROV_REDI(PropertyValue) If a property is redirected to a different target (Foo -> Bar) then follow it by default in order to allow query results to be displayed equivalent for both queries without having to adjust (or change) query. This flag is mainly provided to restore backwards compatibility where behavior is not expected to be altered, nevertheless it is recommended that the setting is enabled to improve user friendliness in terms of query execution.
SMW_DV_MLTV_LCODE(MonolingualTextValue) is to require a language code in order for a DV to be completed otherwise a MLTV can operate without a language code.
SMW_DV_PVAP(Allows pattern) to allow regular expression pattern matching when special property "Allows pattern"Pattern to match a permissible value is assigned to user-defined property
SMW_DV_WPV_DTITLE(WikiPageValue) is to allow requesting a lookup for a display title and if present will be used as caption for the invoked subject
SMW_DV_PROV_DTITLE(PropertyValue) in combination with SMW_DV_WPV_DTITLE, If enabled it will attempt to resolve a property label by matching it against a possible assigned special property "Display title of"Holds a specific denote title for an entity value. For example, property "Foo" has "Display title of" "hasFoolishFoo" where "hasFoolishFoo" is being resolved as "Foo" when creating annotations. Currently, this uses an uncached lookup and therefore is disabled by default to avoid a possible performance impact (which has not been established or analyzed).
SMW_DV_PVUC(Uniqueness constraint) to specify that a property can only assign a value that is unique in its literal representation (the state of uniqueness for a value is established by the fact that it is assigned before any other value of the same representation to a property).
SMW_DV_TIMEV_CM(TimeValue) to indicate the CalendarModel if is not a CM_GREGORIAN
SMW_DV_NUMV_USPACE(Number/QuantityValue) to preserve spaces within unit labels
SMW_DV_PPLBto support the use of preferred property labels
SMW_DV_PROV_LHNT(PropertyValue) to output a p hint marker on properties that use a preferred label
Changing the default setting
To modify the setting to this configuration parameter, add one of the following lines to your "LocalSettings.php" file after the
- Removing the special property "Display title of"Holds a specific denote title for an entity feature from the default setting
$smwgDVFeatures = ( $smwgDVFeatures & ~SMW_DV_WPV_DTITLE );
- Enable support for the special property "Has uniqueness constraint"Allows to restrict value annotation to be unique property trait
$smwgDVFeatures = $smwgDVFeatures | SMW_DV_PVUC;
- Removing the special property "Display title of"Holds a specific denote title for an entity feature and at the same time enable support for the special property "Has uniqueness constraint"Allows to restrict value annotation to be unique property trait
$smwgDVFeatures = ( $smwgDVFeatures & ~SMW_DV_WPV_DTITLE ) | SMW_DV_PVUC;
- Help page on configuration parameter
$smwgQFeaturesDefines which query features should be available by default.