wiki.techinc.nl/includes/search/NullIndexField.php
Umherirrender 9b8b314992 Fix spacing for @param and indent of function comments
In phpcs.xml rename renamed sniffs and add the failing sniffs,
because now the whole sniff is no longer excluded.

Change-Id: If5b0bd16028761abc2c47ace9e97d37ad14bb36f
2017-08-15 14:33:29 +00:00

52 lines
1.1 KiB
PHP

<?php
/**
* Null index field - means search engine does not implement this field.
*/
class NullIndexField implements SearchIndexField {
/**
* Get mapping for specific search engine
* @param SearchEngine $engine
* @return array|null Null means this field does not map to anything
*/
public function getMapping( SearchEngine $engine ) {
return null;
}
/**
* Set global flag for this field.
*
* @param int $flag Bit flag to set/unset
* @param bool $unset True if flag should be unset, false by default
* @return $this
*/
public function setFlag( $flag, $unset = false ) {
}
/**
* Check if flag is set.
* @param int $flag
* @return int 0 if unset, !=0 if set
*/
public function checkFlag( $flag ) {
return 0;
}
/**
* Merge two field definitions if possible.
*
* @param SearchIndexField $that
* @return SearchIndexField|false New definition or false if not mergeable.
*/
public function merge( SearchIndexField $that ) {
return $that;
}
/**
* @inheritDoc
*/
public function getEngineHints( SearchEngine $engine ) {
return [];
}
}