function InputCollectorInterface::collectValue

Collects a single input value for a recipe.

Parameters

string $name: The machine name of the input to collect, in the form RECIPE_NAME.INPUT_NAME.

\Drupal\Core\TypedData\DataDefinitionInterface $definition: The data definition that describes the expected type, constraints, and metadata for the input value.

mixed $default_value: The default value to return if no input is provided.

Return value

mixed The collected input value that satisfies the provided definition.

1 method overrides InputCollectorInterface::collectValue()
ConsoleInputCollector::collectValue in core/lib/Drupal/Core/Recipe/ConsoleInputCollector.php
Collects a single input value for a recipe.

File

core/lib/Drupal/Core/Recipe/InputCollectorInterface.php, line 37

Class

InputCollectorInterface
Collects user-provided input values for recipes.

Namespace

Drupal\Core\Recipe

Code

public function collectValue(string $name, DataDefinitionInterface $definition, mixed $default_value) : mixed;

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.