public function BaseFieldDefinition::setQueryable in Drupal 8
Sets whether the field is queryable.
Parameters
bool $queryable: Whether the field is queryable.
Return value
static The object itself for chaining.
Deprecated
in drupal:8.4.0 and is removed from drupal:9.0.0. Use \Drupal\Core\Field\BaseFieldDefinition::setCustomStorage() instead.
See also
https://www.drupal.org/node/2856563
File
- core/
lib/ Drupal/ Core/ Field/ BaseFieldDefinition.php, line 313
Class
- BaseFieldDefinition
- A class for defining entity fields.
Namespace
Drupal\Core\FieldCode
public function setQueryable($queryable) {
@trigger_error('BaseFieldDefinition::setQueryable() is deprecated in Drupal 8.4.0 and will be removed before Drupal 9.0.0. Instead, you should use \\Drupal\\Core\\Field\\BaseFieldDefinition::setCustomStorage(). See https://www.drupal.org/node/2856563.', E_USER_DEPRECATED);
$this->definition['queryable'] = $queryable;
return $this;
}