PHP Manual
Language Reference
Basic syntax
Types
Variables
Constants
Expressions
Operators
Control Structures
Functions
Classes and Objects
Namespaces
Enumerations
Errors
Exceptions
Fibers
Generators
Attributes
References Explained
Predefined Variables
Predefined Exceptions
Predefined Interfaces and Classes
Predefined Attributes
Context options and parameters
Supported Protocols and Wrappers
$argv
Exception
Language Reference
PHP Manual
Predefined Exceptions
Table of Contents
Exception
— Exception
Exception::__construct
— Construct the exception
Exception::getMessage
— Gets the Exception message
Exception::getPrevious
— Returns previous Throwable
Exception::getCode
— Gets the Exception code
Exception::getFile
— Gets the file in which the exception was created
Exception::getLine
— Gets the line in which the exception was created
Exception::getTrace
— Gets the stack trace
Exception::getTraceAsString
— Gets the stack trace as a string
Exception::__toString
— String representation of the exception
Exception::__clone
— Clone the exception
ErrorException
— ErrorException
ErrorException::__construct
— Constructs the exception
ErrorException::getSeverity
— Gets the exception severity
ClosedGeneratorException
— The ClosedGeneratorException class
Error
— Error
Error::__construct
— Construct the error object
Error::getMessage
— Gets the error message
Error::getPrevious
— Returns previous Throwable
Error::getCode
— Gets the error code
Error::getFile
— Gets the file in which the error occurred
Error::getLine
— Gets the line in which the error occurred
Error::getTrace
— Gets the stack trace
Error::getTraceAsString
— Gets the stack trace as a string
Error::__toString
— String representation of the error
Error::__clone
— Clone the error
ArgumentCountError
— ArgumentCountError
ArithmeticError
— ArithmeticError
AssertionError
— AssertionError
DivisionByZeroError
— DivisionByZeroError
CompileError
— CompileError
ParseError
— ParseError
TypeError
— TypeError
ValueError
— ValueError
UnhandledMatchError
— UnhandledMatchError
FiberError
— FiberError
FiberError::__construct
— Constructor to disallow direct instantiation
See also the
SPL Exceptions
.