ILIAS  trunk Revision v11.0_alpha-1843-g9e1fad99175
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
CardinalDimension.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
22 
27 {
28  public function __construct(array $value_labels = [])
29  {
30  $this->value_labels = $value_labels;
31  }
32 
33  public function checkValue($value): void
34  {
35  if (!is_null($value) && !is_numeric($value)) {
36  throw new \InvalidArgumentException(
37  "Expected parameter to be numeric or null. '$value' is given."
38  );
39  }
40  }
41 }