Go beyond crash reporting, error tracking, logging and error monitoring. Get instant and accurate alerts — plus a real-time feed — of all errors, including unhandled exceptions. Our automation-grade grouping uses machine learning to reduce noise and gives you error signals you can trust. A better way to discover errors Instantly see the impact of crashes and errors with metadata — like which custo
PHPカンファレンス福岡2017の登壇資料です。
定義済み例外とSPL例外 PHPにはPHP本体が持つ定義済み例外とPHPに標準でバンドルされるStandard PHP Library(SPL)の例外のSPL例外の2種類の例外があります。SPLは標準で組み込まれるのでPHPの機能として標準的に使うことも可能ですが、マニュアルでも個別のページを持っています。 定義済み例外 SPL例外 SPL例外 SPLの作者はPDOなど多数のパッケーのleadを務められているMarcus Börgerさんです。(PECLサイト参照 https://pecl.php.net/user/helly) MarcusさんがSPLのために作成したスライドStandard PHP Libraryから例外の部分を2つ抜粋します。 「守るべき3つのルール」 例外は例外の時に使用する (Exceptions are exceptions) 制御構造のために例外を用いない (
<?php $message = sprintf( "HTTP/%s %s %s", $response->getVersion(), $response->getCode(), $response->getMessage() ); throw new HttpException($message, $response->getCode()); <?php class HttpException extends \Exception { /** * 例外を作成して投げるメソッド * * @param $response HttpResponse * @throws HttpException */ public static function raise(HttpResponse $response) { $message = sprintf( "HTTP/%s %s %s", $resp
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く