isUndef(); else return $value === false; } /** * vérifier si $value est assimilée nulle, c'est à dire si elle vaut null * ou si c'est une instance de {@link IValueState} dont la méthode isNull() * retourne true */ static final function is_null($value): bool { if ($value instanceof IValueState) return $value->isNull(); else return $value === null; } /** * vérifier si $value est assimilée valuée, c'est à dire si elle ne vaut ni * false ni null, ou si c'est une instance de {@link IValueState} dont aucune * des méthodes isUndef() et isNull() ne retournent true */ static final function is_value($value): bool { if ($value instanceof IValueState) { return !$value->isUndef() && !$value->isNull(); } else { return $value !== false && $value !== null; } } static final function check_bool($value): ?bool { return SV::check_bool($value); } static final function check_int($value): ?int { return SV::check_int($value); } static final function check_string($value): ?string { return SV::check_string($value); } static final function check_array($value): ?array { return SV::check_array($value); } static final function check_key($value, ?string $prefix=null, bool $throw_exception=true): array { return SV::check_key($value, $prefix, $throw_exception); } static final function check_bsa($value, ?string $prefix=null, bool $throw_exception=true): array { return SV::check_bsa($value, $prefix, $throw_exception); } }