19declare(strict_types=1);
31 if (!is_callable($set_probe)) {
32 throw new \InvalidArgumentException(
33 "Expected \$probe to be callable."
37 if (!is_callable($get_probe)) {
38 throw new \InvalidArgumentException(
39 "Expected \$probe to be callable."
51 $probe = $this->get_probe;
52 return $probe($offset);
57 $probe = $this->set_probe;
58 $probe($offset, $value);
__construct(protected $set_probe, protected $get_probe)
offsetSet($offset, $value)