public function FieldStorageConfig::setCardinality in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/field/src/Entity/FieldStorageConfig.php \Drupal\field\Entity\FieldStorageConfig::setCardinality()
Sets the maximum number of items allowed for the field.
Parameters
int $cardinality: The cardinality value.
Return value
$this
Overrides FieldStorageConfigInterface::setCardinality
File
- core/
modules/ field/ src/ Entity/ FieldStorageConfig.php, line 640 - Contains \Drupal\field\Entity\FieldStorageConfig.
Class
- FieldStorageConfig
- Defines the Field storage configuration entity.
Namespace
Drupal\field\EntityCode
public function setCardinality($cardinality) {
$this->cardinality = $cardinality;
return $this;
}