PHP 8.0.24 Released!


(PHP 8)


A ValueError is thrown when the type of an argument is correct but the value of it is incorrect. For example, passing a negative integer when the function expects a positive one, or passing an empty string/array when the function expects it to not be empty.

Sinopse da classe

class ValueError extends Error {
/* Propriedades herdadas */
protected string $message;
protected int $code;
protected string $file;
protected int $line;
/* Métodos herdados */
final public Error::getMessage(): string
final public Error::getCode(): mixed
final public Error::getFile(): string
final public Error::getLine(): int
final public Error::getTrace(): array
final public Error::getTraceAsString(): string
public Error::__toString(): string
final private Error::__clone(): void
add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top