0 follower

Final Class Yiisoft\Db\Profiler\Context\ConnectionContext

InheritanceYiisoft\Db\Profiler\Context\ConnectionContext » Yiisoft\Db\Profiler\Context\AbstractContext
ImplementsYiisoft\Db\Profiler\ContextInterface

Constants

Hide inherited constants

Constant Value Description Defined By
EXCEPTION 'exception' Yiisoft\Db\Profiler\Context\AbstractContext
METHOD 'method' Yiisoft\Db\Profiler\Context\AbstractContext

Method Details

Hide inherited methods

__construct() public method
public __construct( string $method ): mixed
$method string

                public function __construct(
    private readonly string $method,
) {}

            
asArray() public method
public asArray( ): array

                public function asArray(): array
{
    return [
        self::METHOD => $this->method,
        self::EXCEPTION => $this->exception,
    ];
}

            
getType() public method

public getType( ): string

                public function getType(): string
{
    return 'connection';
}

            
setException() public method
public setException( Throwable $e ): Yiisoft\Db\Profiler\Context\ConnectionContext
$e Throwable

                public function setException(Throwable $e): static
{
    $this->exception = $e;
    return $this;
}