19declare(strict_types=1);
38 if (!is_array(
$data)) {
39 return fn() => yield
"Expected an array.";
45 foreach (
$data as $v) {
46 $value = $this->value_type->getPrimitiveRepresentation($v);
48 if ($value instanceof \Closure) {
56 return $this->mergeErrors($errors);
64 return $this->value_type;
getPrimitiveRepresentation(mixed $data)
Each of the types that can be described has a canonical representation created from primitive PHP typ...
__construct(Text\SimpleDocumentMarkdown $description, protected Description $value_type)
This describes some datastructure in terms of standard data structures such as primitives,...
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc