orisai/exceptions

专为静态分析和易于使用设计的异常处理

1.1.4 2024-06-20 20:47 UTC

This package is auto-updated.

Last update: 2024-09-21 08:35:09 UTC


README

Orisai
异常

专为静态分析和易于使用设计的异常处理

📄 查看我们的 文档

💸 如果您喜欢 Orisai,请 捐赠。谢谢您!

use Orisai\Exceptions\Logic\InvalidState;
use Orisai\Exceptions\Message;

$message = Message::create()
    ->withContext('Trying to commit an import.')
    ->withProblem('There is nothing to commit.')
    ->withSolution('Check that the import files are not empty, and that filters are not too restrictive.');

throw InvalidState::create()
    ->withMessage($message);

... 以及 更多