FieldStorageConfig::setCardinality

public FieldStorageConfig::setCardinality($cardinality)

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 636

Class

FieldStorageConfig
Defines the Field storage configuration entity.

Namespace

Drupal\field\Entity

Code

public function setCardinality($cardinality) {
  $this->cardinality = $cardinality;
  return $this;
}
doc_Drupal
2016-10-29 09:12:24
Comments
Leave a Comment

Please login to continue.