{"id":302419,"date":"2020-04-24T03:00:15","date_gmt":"2020-04-24T03:00:15","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=302419"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=302419","title":{"rendered":"PSR \u0421\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u044b"},"content":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/post\/458484\/\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/ka\/wv\/yg\/kawvygfnunfisi5stn1zjqg3v58.png\" alt=\"PHP-FIG\"><\/p>\n<p>  <b>PSR \u2014 \u0427\u0443\u0442\u044c \u0431\u043e\u043b\u044c\u0448\u0435, \u0447\u0435\u043c \u0441\u0442\u0438\u043b\u044c \u043e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u0434\u0430.<\/b><\/p>\n<p>  \u041a\u0430\u043a \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430, \u043c\u043d\u043e\u0433\u0438\u0435 PHP-\u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u0437\u043d\u0430\u043a\u043e\u043c\u044b \u0441 \u0430\u0431\u0431\u0440\u0435\u0432\u0438\u0430\u0442\u0443\u0440\u043e\u0439 PSR. \u041e\u0434\u043d\u0430\u043a\u043e \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u043e \u0432\u0441\u0435 \u0435\u0449\u0435 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u044b \u0437\u043d\u0430\u043d\u0438\u0435\u043c, \u0447\u0442\u043e PSR \u044d\u0442\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u043e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u0434\u0430. <\/p>\n<p>  \u0420\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 PHP-FIG (PHP Framework Interop Group), \u0433\u0440\u0443\u043f\u043f\u0430 \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0439 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u0438 PHP, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0437\u0430\u043d\u0438\u043c\u0430\u044e\u0442\u0441\u044f \u0440\u0430\u0437\u0432\u0438\u0442\u0438\u0435\u043c PSR (PHP Standards Recommendations) \u0448\u0430\u0433\u043d\u0443\u043b\u0438 \u0434\u0430\u043b\u0435\u043a\u043e \u0432\u043f\u0435\u0440\u0435\u0434. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0430\u0432\u0430\u0439\u0442\u0435 \u0440\u0430\u0437\u0431\u0435\u0440\u0435\u043c\u0441\u044f, \u0447\u0442\u043e \u0438\u0437 \u0441\u0435\u0431\u044f \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 PSR\u2026<\/p>\n<p>  <a name=\"habracut\"><\/a>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041d\u0435\u0431\u043e\u043b\u044c\u0448\u0430\u044f \u043f\u0440\u0435\u0434\u044b\u0441\u0442\u043e\u0440\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0432\u0434\u043e\u0445\u043d\u043e\u0432\u0438\u043b\u0430 \u043c\u0435\u043d\u044f \u043d\u0430 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438.<\/b>                         <\/p>\n<div class=\"spoiler_text\">\u0417\u0430 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0435 \u043f\u043e\u043b\u0433\u043e\u0434\u0430 \u043c\u043d\u0435 \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043f\u0440\u043e\u0432\u0435\u0441\u0442\u0438 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e \u0441\u043e\u0431\u0435\u0441\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u0439 \u043d\u0430 \u043f\u043e\u0437\u0438\u0446\u0438\u044e Middle PHP-Developer. <\/p>\n<p>  \u041e\u0434\u0438\u043d \u0438\u0437 \u0432\u043e\u043f\u0440\u043e\u0441\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u044f \u0437\u0430\u0434\u0430\u0432\u0430\u043b \u0432\u0441\u0435\u043c \u043a\u0430\u043d\u0434\u0438\u0434\u0430\u0442\u0430\u043c, \u0431\u044b\u043b:- <b>\u00ab\u0417\u043d\u0430\u0435\u0442\u0435 \u043b\u0438 \u0412\u044b, \u0447\u0442\u043e \u0442\u0430\u043a\u043e\u0435 PSR<\/b>?\u00bb<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/l0\/vr\/40\/l0vr40lwhegt9i4faeeulynrnpg.gif\" alt=\"code style\"><\/p>\n<p>  \u041a\u0430\u043a \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0432\u0441\u0435\u043c \u043a\u0430\u043d\u0434\u0438\u0434\u0430\u0442\u0430\u043c \u0431\u044b\u043b\u0430 \u0437\u043d\u0430\u043a\u043e\u043c\u0430 \u044d\u0442\u0430 \u0430\u0431\u0431\u0440\u0435\u0432\u0438\u0430\u0442\u0443\u0440\u0430. \u041e\u0434\u043d\u0430\u043a\u043e \u043f\u044b\u0442\u0430\u044f\u0441\u044c \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u0442\u044c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435, \u043f\u043e\u0447\u0442\u0438 \u0432\u0441\u0435 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u043b\u0438 \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u044d\u0442\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u043e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u0434\u0430 (code style). \u0422\u043e\u043b\u044c\u043a\u043e \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0443\u043f\u043e\u043c\u0438\u043d\u0430\u043b\u0438 \u043f\u0440\u043e PSR-4 \u0430\u0432\u0442\u043e\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0443 (\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 Composer) \u0438 PSR-3 Logger Interface (\u0432 \u0441\u0435\u0442\u0438 \u043e\u0447\u0435\u043d\u044c \u043c\u043d\u043e\u0433\u043e \u043e\u0434\u043d\u043e\u0440\u043e\u0434\u043d\u044b\u0445 \u0441\u0442\u0430\u0442\u0435\u0439 \u043f\u0440\u043e PSR-0-1-2-3-4).<\/p>\n<p>  \u041c\u043d\u0435 \u043a\u0430\u0436\u0435\u0442\u0441\u044f \u044d\u0442\u043e \u0432\u0435\u0441\u044c\u043c\u0430 \u0441\u0442\u0440\u0430\u043d\u043d\u044b\u043c, \u0442\u0430\u043a \u043a\u0430\u043a \u0442\u0435\u0440\u043c\u0438\u043d PSR \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0434\u0430\u0432\u043d\u043e (\u0443\u0436\u0435 \u0431\u043e\u043b\u0435\u0435 10 \u043b\u0435\u0442) \u0438 \u043a\u0430\u0436\u0434\u044b\u0439 \u0433\u043e\u0434 \u043d\u0430\u0431\u0438\u0440\u0430\u0435\u0442 \u0432\u0441\u0435 \u0431\u043e\u043b\u044c\u0448\u0443\u044e \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u043e\u0441\u0442\u044c. \u041f\u043e\u044d\u0442\u043e\u043c\u0443, \u0434\u0443\u043c\u0430\u044e, \u0431\u0443\u0434\u0435\u0442 \u043d\u0435\u043f\u043b\u043e\u0445\u043e \u0441\u043e\u0431\u0440\u0430\u0442\u044c \u0432\u0441\u0435 \u0432 \u043a\u0443\u0447\u0443 \u0438 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043e\u0431\u0437\u043e\u0440 PSR \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043e\u0432.  <\/div>\n<\/p><\/div>\n<h2>PHP-FIG \u0438 PSR<\/h2>\n<p>  <a href=\"https:\/\/www.php-fig.org\" rel=\"nofollow\">PHP-FIG<\/a> (PHP Framework Interop Group) \u2014 \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u0430\u044f \u0432 2009 \u0433\u043e\u0434\u0443 \u0433\u0440\u0443\u043f\u043f\u0430 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432, \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0438\u0434\u0435\u044f \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c \u0441\u043f\u043e\u0441\u043e\u0431\u044b \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e\u0439 \u0440\u0430\u0431\u043e\u0442\u044b, \u0432\u044b\u0434\u0435\u043b\u044f\u044f \u043e\u0431\u0449\u0438\u0435 \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0438 \u0432 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432 \u043d\u0430 PHP.<\/p>\n<p>  \u041f\u0440\u043e\u0449\u0435 \u0433\u043e\u0432\u043e\u0440\u044f, \u0440\u0435\u0431\u044f\u0442\u0430 \u0441\u0442\u0430\u0440\u0430\u044e\u0442\u0441\u044f \u0432\u044b\u0434\u0435\u043b\u0438\u0442\u044c \u0447\u0442\u043e-\u0442\u043e \u043e\u0431\u0449\u0435\u0435 \u043c\u0435\u0436\u0434\u0443 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u043c\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u043c\u0438 \u043d\u0430 \u0440\u0430\u0437\u043d\u044b\u0445 \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430\u0445 \u0438 \u0441\u0444\u043e\u0440\u043c\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0435\u043a\u0438\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u044b (\u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0430\u0446\u0438\u0438) \u0434\u043b\u044f \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u0433\u043e \u043f\u0435\u0440\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f. <\/p>\n<p>  <b>\u0423\u0447\u0430\u0441\u0442\u043d\u0438\u043a\u0438 PHP-FIG<\/b><br \/>  ReactPHP, Composer, Laminas Project (\u043f\u0435\u0440\u0435\u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0439 Zend Framework), Yii framework, CakePHP, Slim, Joomla, Magento, Drupal, phpBB, phpDocumentor \u0438 <a href=\"https:\/\/www.php-fig.org\/personnel\/\" rel=\"nofollow\">\u0434\u0440\u0443\u0433\u0438\u0435<\/a>.<\/p>\n<p>  PSR (PHP Standards Recommendations) \u2014 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u043e\u0431\u0449\u0438\u0435 \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0443\u0436\u0435 \u0431\u044b\u043b\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u044b \u0438 \u043e\u0442\u0440\u0430\u0431\u043e\u0442\u0430\u043d\u044b. \u0412\u0435\u0440\u043e\u044f\u0442\u043d\u043e \u043f\u0440\u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0438 PSR, \u0433\u0440\u0443\u043f\u043f\u0430 PHP-FIG \u0432\u0434\u043e\u0445\u043d\u043e\u0432\u043b\u044f\u043b\u0430\u0441\u044c <a href=\"https:\/\/ru.wikipedia.org\/wiki\/Java_Community_Process\" rel=\"nofollow\">Java Community Process<\/a>, \u0430 \u043f\u0435\u0440\u0432\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0431\u044b\u043b \u043f\u0440\u0438\u043d\u044f\u0442 \u0432 <a href=\"https:\/\/github.com\/php-fig\/fig-standards\/commit\/ab3b658ec9fae0ec6b1b93913c1c8789360b3755\" rel=\"nofollow\">2010 \u0433\u043e\u0434\u0443<\/a>.<\/p>\n<p>  <a href=\"https:\/\/www.php-fig.org\/psr\/\" rel=\"nofollow\">\u0421\u043f\u0438\u0441\u043e\u043a PSR \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043e\u0432<\/a> \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0435\u0442\u0441\u044f \u043d\u043e\u0432\u044b\u043c\u0438, \u0430 \u0441\u0430\u043c\u0438 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u044b \u0434\u0435\u043b\u044f\u0442\u0441\u044f \u043d\u0430 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438: <br \/>  <u>\u0410\u0432\u0442\u043e\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0430<\/u>, <u>\u0418\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b<\/u>, <u>HTTP<\/u> \u0438 <u>\u0421\u0442\u0438\u043b\u044c \u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f<\/u>,<br \/>  \u043a\u0430\u0436\u0434\u043e\u043c\u0443 \u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043f\u0440\u0438\u0441\u0432\u0430\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0439 \u0441\u0442\u0430\u0442\u0443\u0441: <br \/>  <u>\u041f\u0440\u0438\u043d\u044f\u0442<\/u>, <u>\u0423\u0441\u0442\u0430\u0440\u0435\u0432\u0448\u0438\u0439<\/u>, <u>\u0427\u0435\u0440\u043d\u043e\u0432\u0438\u043a<\/u> \u0438 <u>\u0417\u0430\u0431\u0440\u043e\u0448\u0435\u043d\u043d\u044b\u0439<\/u>.<\/p>\n<p>  \u0414\u0430\u043b\u0435\u0435 \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u0440\u0438\u043d\u044f\u0442\u044b\u0435 PSR \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u044b \u043f\u043e \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u044f\u043c:<\/p>\n<h2><font color=\"#9cc2ce\">\u0410\u0432\u0442\u043e\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0430<\/font><\/h2>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/cn\/1a\/gz\/cn1agzi0-y6tt7pteva6bzso1by.png\" alt=\"Composer\"><\/p>\n<p>  \u0420\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 &quot;<i>\u043d\u0435\u0434\u043e\u043b\u0433\u043e<\/i>&quot; \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442 \u0441 PHP, \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e \u043d\u0435 \u0437\u043d\u0430\u043a\u043e\u043c\u044b \u0441 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430\u043c\u0438 \u0438\u043c\u043f\u043e\u0440\u0442\u0430 \u043a\u043b\u0430\u0441\u0441\u043e\u0432, \u0432\u0435\u0434\u044c \u0435\u0441\u0442\u044c <a href=\"https:\/\/www.php.net\/manual\/ru\/language.namespaces.rationale.php\" rel=\"nofollow\">\u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430 \u0438\u043c\u0435\u043d<\/a>, \u0430 \u0441\u0435\u0439\u0447\u0430\u0441 \u0432\u043e\u043e\u0431\u0449\u0435 \u0442\u0440\u0443\u0434\u043d\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043f\u0440\u043e\u0435\u043a\u0442 \u0431\u0435\u0437 \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440\u0430 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 Composer, \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0440\u0435\u0448\u0430\u0435\u0442 \u0432\u0441\u0435 \u0432\u043e\u043f\u0440\u043e\u0441\u044b \u0441 \u0430\u0432\u0442\u043e\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u043e\u0439 \u043a\u043b\u0430\u0441\u0441\u043e\u0432.<\/p>\n<p>  \u041e\u0434\u043d\u0430\u043a\u043e \u0442\u0430\u043a \u0431\u044b\u043b\u043e \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430, \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430 \u0438\u043c\u0435\u043d \u043f\u043e\u044f\u0432\u0438\u043b\u0438\u0441\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0432 <a href=\"https:\/\/www.php.net\/ChangeLog-5.php#5.3.0\" rel=\"nofollow\">PHP 5.3<\/a> (\u044d\u0442\u043e \u0431\u044b\u043b 2009 \u0433\u043e\u0434), \u0430 \u043f\u0435\u0440\u0432\u044b\u0439 \u0440\u0435\u043b\u0438\u0437 Composer \u0441\u043e\u0441\u0442\u043e\u044f\u043b\u0441\u044f \u0432 \u043c\u0430\u0440\u0442\u0435 2012 \u0433\u043e\u0434\u0430. \u041d\u043e \u0432\u043e\u0442 \u0441\u0430\u043c PHP \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0433\u043e\u0440\u0430\u0437\u0434\u043e \u0434\u043e\u043b\u044c\u0448\u0435, \u043a\u0430\u043a Personal Home Page \u0441 1995 \u0433\u043e\u0434\u0430 \u0438 \u043a\u0430\u043a Hypertext Preprocessor \u0441 1998 \u0433\u043e\u0434\u0430, \u043e\u0434\u043d\u0430\u043a\u043e \u0442\u043e\u043b\u044c\u043a\u043e PHP 5 \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 &quot;<a href=\"https:\/\/www.php.net\/manual\/ru\/oop5.intro.php\" rel=\"nofollow\">\u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u0443\u044e \u043e\u0431\u044a\u0435\u043a\u0442\u043d\u0443\u044e \u043c\u043e\u0434\u0435\u043b\u044c<\/a>&quot;, \u0440\u0435\u043b\u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0431\u044b\u043b \u0432 \u0438\u044e\u043b\u0435 2004 \u0433\u043e\u0434\u0430. \u0411\u043e\u0440\u043e\u0434\u0430\u0442\u044b\u043c \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430\u043c \u0442\u043e\u0433\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u043b\u043e\u0441\u044c \u043a\u0430\u043a-\u0442\u043e \u0441\u0440\u0430\u0436\u0430\u0442\u044c\u0441\u044f \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u0432\u043e\u0437\u043d\u0438\u043a\u0448\u0438\u043c\u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430\u043c\u0438 \u043f\u0440\u0438 \u0438\u043c\u043f\u043e\u0440\u0442\u0435 \u043a\u043b\u0430\u0441\u0441\u043e\u0432. <\/p>\n<p>  \u041d\u0435 \u0441\u0430\u043c\u044b\u0439 \u043f\u043b\u043e\u0445\u043e\u0439 \u043f\u0440\u0438\u043c\u0435\u0440 \u0438\u043c\u043f\u043e\u0440\u0442\u0430 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u043d\u0430 PHP 14-\u0442\u0438 \u043b\u0435\u0442\u043d\u0435\u0439 \u0434\u0430\u0432\u043d\u043e\u0441\u0442\u0438:  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041f\u0440\u0438\u043c\u0435\u0440 \u043a\u043e\u0434\u0430<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"php\">class MyLib {     private $CI;     public function __construct()     {         $this-&gt;CI = &amp;get_instance();          $this-&gt;CI-&gt;load-&gt;library('encrypt');         $this-&gt;CI-&gt;load-&gt;library('session');         $this-&gt;CI-&gt;load-&gt;library('url');          $this-&gt;CI-&gt;load-&gt;helper('captcha');         $this-&gt;CI-&gt;load-&gt;helper('cookie');         $this-&gt;CI-&gt;load-&gt;helper('email');     }     ... }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p><i>(\u041d\u0430\u043f\u0438\u0448\u0438\u0442\u0435 \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445, \u0435\u0441\u043b\u0438 \u0443\u0437\u043d\u0430\u043b\u0438 \u0433\u0434\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0441\u044f \u0434\u0430\u043d\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434).<\/i><\/p>\n<ul>\n<li> <s><b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-0\/\" rel=\"nofollow\">PSR-0<\/a> \u2014 Autoloading Standard<\/b><\/s> <font color=\"#808080\">\u0423\u0441\u0442\u0430\u0440\u0435\u043b<\/font><br \/>  \u041f\u043e\u0441\u043b\u0435 \u0440\u0435\u043b\u0438\u0437\u0430 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430 \u0438\u043c\u0435\u043d \u0432 2009 \u0433\u043e\u0434\u0443, \u0432 2010 \u0433\u043e\u0434\u0443 \u0431\u044b\u043b \u043e\u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043d \u043f\u0435\u0440\u0432\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0441\u0442\u0430\u043b \u0440\u0435\u0432\u043e\u043b\u044e\u0446\u0438\u0435\u0439 \u0432 \u0440\u0435\u0448\u0435\u043d\u0438\u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u0430\u0432\u0442\u043e\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u0438 \u0441\u0442\u0430\u043b \u043f\u0435\u0440\u0432\u044b\u043c \u0448\u0430\u0433\u043e\u043c \u043d\u0430 \u043f\u0443\u0442\u0438 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u043e\u0432 \u2014 \u043d\u0430\u043b\u0438\u0447\u0438\u0435 \u043e\u0431\u0449\u0435\u0439 \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u044b \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0439.<br \/>  <a href=\"https:\/\/github.com\/php-fig\/fig-standards\/blob\/master\/accepted\/PSR-0.md#example-implementation\" rel=\"nofollow\">\u041f\u0440\u0438\u043c\u0435\u0440 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438<\/a>   <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-4\/\" rel=\"nofollow\">PSR-4<\/a> \u2014 Autoloading Standard<\/b><br \/>  \u041f\u0440\u043e\u0433\u0440\u0435\u0441\u0441 \u043d\u0435 \u0441\u0442\u043e\u0438\u0442 \u043d\u0430 \u043c\u0435\u0441\u0442\u0435 \u0438 \u0432 \u043a\u043e\u043d\u0446\u0435 2013 \u0433\u043e\u0434\u0430 PHP-FIG \u043f\u0443\u0431\u043b\u0438\u043a\u0443\u044e\u0442 \u043d\u043e\u0432\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0430\u0432\u0442\u043e\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u043a\u043b\u0430\u0441\u0441\u043e\u0432. \u041e\u043d \u043c\u043e\u0436\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0432 \u0434\u043e\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u043a PSR-0, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043b\u044e\u0431\u043e\u0439 \u0434\u0440\u0443\u0433\u043e\u0439 \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0430\u0432\u0442\u043e\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438. \u0421\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0442\u0430\u043a\u0436\u0435 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442, \u0433\u0434\u0435 \u0440\u0430\u0437\u043c\u0435\u0449\u0430\u0442\u044c \u0444\u0430\u0439\u043b\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0442\u044c\u0441\u044f \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441\u043e \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0435\u0439. \u0414\u0430\u043d\u043d\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0440\u0435\u0448\u0430\u0435\u0442 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b\/\u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f PSR-0 \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0432 Composer.<br \/>  <a href=\"https:\/\/github.com\/php-fig\/fig-standards\/blob\/master\/accepted\/PSR-4-autoloader-examples.md\" rel=\"nofollow\">\u041f\u0440\u0438\u043c\u0435\u0440 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438<\/a>   <\/li>\n<\/ul>\n<p>  \u0421\u0435\u0439\u0447\u0430\u0441, \u0441\u043b\u043e\u0436\u043d\u043e \u0432\u0441\u0442\u0440\u0435\u0442\u0438\u0442\u044c \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u044b \u0441\u043c\u043e\u0433 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u0442\u044c \u043e \u0442\u043e\u043d\u043a\u043e\u0441\u0442\u044f\u0445 \u0440\u0430\u0431\u043e\u0442\u044b \u0430\u0432\u0442\u043e\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0432 PHP, \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0432\u0441\u0435 \u0441\u0441\u044b\u043b\u0430\u044e\u0442\u0441\u044f \u043d\u0430 \u0440\u0430\u0431\u043e\u0442\u0443 \u0441 Composer, \u043d\u0435 \u0437\u0430\u0434\u0443\u043c\u044b\u0432\u0430\u044f\u0441\u044c \u043a\u0430\u043a \u0432\u0441\u0435 \u0443\u0441\u0442\u0440\u043e\u0435\u043d\u043e \u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c.<\/p>\n<p>  \u0412 \u0434\u043e\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435, \u043e\u0441\u0442\u0430\u0432\u043b\u044e \u0441\u0441\u044b\u043b\u043a\u0443 \u043d\u0430 <a href=\"https:\/\/github.com\/codedokode\/pasta\/blob\/master\/php\/autoload.md\" rel=\"nofollow\">\u0441\u0442\u0430\u0442\u044c\u044e<\/a>, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0443 \u0441 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u043e\u043c \u0438\u043c\u0435\u043d, \u0440\u0435\u0448\u0435\u043d\u043d\u044b\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u0438 PSR-4.<\/p>\n<h2><font color=\"#9cc2ce\">\u0418\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b<\/font><\/h2>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/in\/4t\/az\/in4tazdiwjw9gj8orpsupnxi9-o.png\" alt=\"PSR-Interfaces\"><\/p>\n<p>  PHP \u0440\u0430\u0437\u0432\u0438\u0432\u0430\u0435\u0442\u0441\u044f, \u043d\u0430\u0431\u0438\u0440\u0430\u0435\u0442 \u0432\u0441\u0435 \u0431\u043e\u043b\u044c\u0448\u0443\u044e \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u043e\u0441\u0442\u044c, \u0430 \u0435\u0433\u043e \u0438\u043d\u0444\u0440\u0430\u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0430 \u043f\u043e\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u043e\u0433\u0440\u043e\u043c\u043d\u044b\u043c \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e\u043c \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432.<\/p>\n<p>  \u041f\u043e\u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u0441 \u0438\u0437\u0443\u0447\u0435\u043d\u0438\u0435\u043c \u0438 \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u043e\u0434\u043d\u043e\u0442\u0438\u043f\u043d\u043e\u0433\u043e \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u0430, \u0430 \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u0442\u044f\u043d\u0443\u0442\u044c \u0446\u0435\u043b\u0443\u044e \u043a\u0443\u0447\u0443 \u043d\u0435\u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0445 \u043e\u0434\u043d\u043e\u0442\u0438\u043f\u043d\u044b\u0445 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439. <i>(\u0442\u0443\u0442 JavaScript \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a \u0443\u043b\u044b\u0431\u043d\u0435\u0442\u0441\u044f)<\/i>.<\/p>\n<p>  \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043f\u0440\u0438\u043d\u044f\u0442\u043e \u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0431\u0449\u0438\u0435 \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0438:<\/p>\n<ul>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-3\/\" rel=\"nofollow\">PSR-3<\/a>: Logger Interface<\/b><br \/>  \u041e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0446\u0435\u043b\u044c \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u2013 \u043f\u0440\u043e\u0441\u0442\u044b\u043c \u0438 \u0443\u043d\u0438\u0432\u0435\u0440\u0441\u0430\u043b\u044c\u043d\u044b\u043c \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u043c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u043b\u043e\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. \u041a \u0434\u0430\u043d\u043d\u043e\u043c\u0443 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0443 \u043f\u0440\u0438\u043b\u0430\u0433\u0430\u0435\u0442\u0441\u044f \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u0432 \u043a\u0430\u043a\u0438\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445 \u043a\u0430\u043a\u043e\u0439 \u0438\u0437 \u043c\u0435\u0442\u043e\u0434\u043e\u0432 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c.<br \/> \n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">LoggerInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"php\">interface LoggerInterface {     public function emergency($message, array $context = array());     public function alert($message, array $context = array());     public function critical($message, array $context = array());     public function error($message, array $context = array());     public function warning($message, array $context = array());     public function notice($message, array $context = array());     public function info($message, array $context = array());     public function debug($message, array $context = array());     public function log($level, $message, array $context = array()); }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u0415\u0441\u043b\u0438 \u0412\u0430\u0448 \u043f\u0440\u043e\u0435\u043a\u0442 \u043d\u0443\u0436\u0434\u0430\u0435\u0442\u0441\u044f \u0432 \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u043d\u043e\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u0435, \u041c\u041e\u0416\u041d\u041e \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441, \u043d\u043e \u0421\u041b\u0415\u0414\u0423\u0415\u0422 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0442\u044c \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u044c \u0441 \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u043c\u0438 \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u0430\u043c\u0438. \u042d\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u0442 \u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0438\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430\u043c, \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u043c\u044b\u0445 \u043f\u0440\u0438 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0446\u0435\u043d\u0442\u0440\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u0443\u044e \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u043b\u043e\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<p>  \u041d\u0430 \u0441\u0435\u0433\u043e\u0434\u043d\u044f\u0448\u043d\u0438\u0439 \u0434\u0435\u043d\u044c \u043d\u0435\u0442 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u0441\u0430\u043c\u043e\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 (\u0440\u0430\u0437\u0432\u0435 \u0447\u0442\u043e \u0432 \u0446\u0435\u043b\u044f\u0445 \u043e\u0431\u0443\u0447\u0435\u043d\u0438\u044f), \u0442\u0430\u043a-\u043a\u0430\u043a \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u043e\u0442\u043b\u0438\u0447\u043d\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435 <a href=\"https:\/\/github.com\/Seldaek\/monolog\" rel=\"nofollow\">Monolog<\/a> \u0434\u043b\u044f \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043b\u043e\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0432\u043e \u043c\u043d\u043e\u0433\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445.    <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-6\/\" rel=\"nofollow\">PSR-6<\/a>: Caching Interface<\/b><br \/>  \u041a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0448\u0438\u0440\u043e\u043a\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u043f\u043e\u0432\u044b\u0448\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u043b\u044e\u0431\u043e\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430.<br \/>  \u041a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0442\u0430\u043a-\u0436\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0440\u0430\u0441\u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u043d\u044b\u0445 \u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u043c\u043d\u043e\u0433\u0438\u0445 CMS, \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u043e\u0432 \u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a.\n<p>  \u042d\u0442\u043e \u043f\u0440\u0438\u0432\u0435\u043b\u043e \u043a \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u0438, \u043a\u043e\u0433\u0434\u0430 \u043c\u043d\u043e\u0433\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u044e\u0442 \u0441\u0432\u043e\u0438 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0441 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u043c\u0438 \u0443\u0440\u043e\u0432\u043d\u044f\u043c\u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u0438. \u042d\u0442\u0438 \u0440\u0430\u0437\u043b\u0438\u0447\u0438\u044f \u0437\u0430\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0442 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432 \u0438\u0437\u0443\u0447\u0430\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u0438\u0441\u0442\u0435\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0442\u044c \u0438\u043b\u0438 \u043d\u0435 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0442\u044c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u0443\u044e \u0438\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c. \u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e, \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u043a\u0435\u0448\u0438\u0440\u0443\u044e\u0449\u0438\u0445 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a \u0441\u0430\u043c\u0438 \u0441\u0442\u0430\u043b\u043a\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0441 \u0432\u044b\u0431\u043e\u0440\u043e\u043c \u043c\u0435\u0436\u0434\u0443 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u043e\u0439 \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u043d\u043e\u0433\u043e \u0447\u0438\u0441\u043b\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c \u0438\u043b\u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435\u043c \u0431\u043e\u043b\u044c\u0448\u043e\u0433\u043e \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u0430 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u0430\u0434\u0430\u043f\u0442\u0435\u0440\u043e\u0432.<\/p>\n<p>  \u0427\u0442\u043e\u0431\u044b \u0440\u0435\u0448\u0438\u0442\u044c \u044d\u0442\u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u0431\u044b\u043b \u043f\u0440\u0438\u043d\u044f\u0442 \u043e\u0431\u0449\u0438\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0434\u043b\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u044e\u0449\u0438\u0445 \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435, \u043e\u043d \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u0432 \u0441\u0435\u0431\u044f \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u0432:  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">CacheItemInterface \u0438 CacheItemPoolInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"php\">interface CacheItemInterface {     public function getKey();     public function get();     public function isHit();     public function set($value);     public function expiresAt($expiration);     public function expiresAfter($time); }<\/code><\/pre>\n<p>  <\/p>\n<pre><code class=\"php\">interface CacheItemPoolInterface {     public function getItem($key);     public function getItems(array $keys = array());     public function hasItem($key);     public function clear();     public function deleteItem($key);     public function deleteItems(array $keys);     public function save(CacheItemInterface $item);     public function saveDeferred(CacheItemInterface $item);     public function commit(); } <\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  <s>\u041d\u0430\u0432\u0435\u0440\u043d\u043e\u0435<\/s> \u0441\u0430\u043c\u0430\u044f \u0433\u043e\u0434\u043d\u0430\u044f \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f PSR-6 \u044d\u0442\u043e <a href=\"https:\/\/github.com\/symfony\/cache\" rel=\"nofollow\">Symfony Cache<\/a>. \u0410 \u0432\u043e\u0442 \u043e\u0434\u043d\u0430 \u0438\u0437 \u0441\u0430\u043c\u044b\u0445 \u0441\u0442\u0430\u0440\u044b\u0445 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0439 \u2014 \u044d\u0442\u043e <a href=\"https:\/\/github.com\/laminas\/laminas-cache\" rel=\"nofollow\">Laminas Cache<\/a> (\u0431\u044b\u0432\u0448\u0438\u0439 Zend).   <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-11\/\" rel=\"nofollow\">PSR-11<\/a>: Container Interface<\/b><br \/>  \u041e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0446\u0435\u043b\u044c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c, \u043a\u0430\u043a \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0438 \u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0431\u0443\u0434\u0443\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c (DIC) \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 \u0434\u043b\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c \u0438 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430\u043c. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0431\u044b\u043b \u043e\u043f\u0438\u0441\u0430\u043d ContainerInterface.<br \/> \n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">ContainerInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"php\">interface ContainerInterface {     public function get($id);     public function has($id); }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u0421\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f PSR-11 \u043d\u0435 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u0442\u043e, \u043a\u0430\u043a \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435, \u043e\u0434\u043d\u0430\u043a\u043e \u0434\u0430\u0435\u0442 \u0447\u0435\u0442\u043a\u0443\u044e \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0430\u0446\u0438\u044e \u043a\u0430\u043a \u0434\u0435\u043b\u0430\u0442\u044c \u043d\u0435 \u043d\u0443\u0436\u043d\u043e:  <\/p>\n<blockquote><p>\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0438 \u041d\u0415 \u0414\u041e\u041b\u0416\u041d\u042b \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 \u0432 \u043e\u0431\u044a\u0435\u043a\u0442, \u0447\u0442\u043e\u0431\u044b \u043e\u0431\u044a\u0435\u043a\u0442 \u043c\u043e\u0433 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u0432\u043e\u0438 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438. \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 Service Locator, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043e\u0431\u044b\u0447\u043d\u043e \u043d\u0435 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c.  <\/p><\/blockquote>\n<p>\u041e\u0442\u0441\u044e\u0434\u0430, \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u0435\u0442 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0432\u043e\u043f\u0440\u043e\u0441: <b>\u00ab\u041a\u0430\u043a \u044d\u0442\u043e \u0432\u043e\u043e\u0431\u0449\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442\u00bb?<\/b><\/p>\n<p>  \u041d\u0430 \u0441\u0430\u043c\u043e\u043c \u0434\u0435\u043b\u0435 \u0432\u0441\u0435 \u043f\u0440\u043e\u0441\u0442\u043e, \u043d\u0430 \u043f\u043e\u043c\u043e\u0449\u044c \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442 \u043f\u0430\u0442\u0442\u0435\u0440 Factory, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u043e\u0437\u044c\u043c\u0435\u0442 \u043d\u0430 \u0441\u0435\u0431\u044f \u0437\u0430\u0434\u0430\u0447\u0443 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043e\u0431\u044a\u0435\u043a\u0442\u0430. \u0410 \u0432\u043e\u0442 \u0441\u0430\u043c \u043a\u043b\u0430\u0441\u0441 \u0444\u0430\u0431\u0440\u0438\u043a\u0438 \u0443\u0436\u0435 \u043c\u043e\u0436\u0435\u0442 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0442\u044c ContainerInterface \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0432 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0435\u043c\u044b\u0439 \u043e\u0431\u044a\u0435\u043a\u0442 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438.   <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041f\u0440\u0438\u043c\u0435\u0440 \u043a\u043e\u0434\u0430<\/b>                         <\/p>\n<div class=\"spoiler_text\"><b>ConfigProvider<\/b>  <\/p>\n<pre><code class=\"php\">[     'invokables' =&gt; [           \/\/ \u043c\u043e\u0436\u043d\u043e \u043e\u0431\u043e\u0439\u0442\u0438\u0441\u044c \u0431\u0435\u0437 \u0444\u0430\u0431\u0440\u0438\u043a\u0438, \u0435\u0441\u043b\u0438 \u043a\u043b\u0430\u0441\u0441 \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439     ],     'factories'  =&gt; [         MyHandler::class =&gt; MyHandlerFactory::class,     ], ];<\/code><\/pre>\n<p>  <b>MyHandlerFactory<\/b>  <\/p>\n<pre><code class=\"php\">class MyHandlerFactory {     public function __invoke(ContainerInterface $container) : RequestHandlerInterface     {         $dep = $container-&gt;get(MyDepInterface::class);          return new MyHandler($dep);     } }<\/code><\/pre>\n<p>  <b>MyHandler<\/b>  <\/p>\n<pre><code class=\"php\">class MyHandler {     private $dep;     public function __construct(MyDepInterface $dep)      {         $this-&gt;dep = $dep;     }     public function __invoke(ServerRequestInterface $request): RequestHandlerInterface     {          \/\/     } }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u0414\u0430\u043d\u043d\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 middleware framework <a href=\"https:\/\/docs.mezzio.dev\" rel=\"nofollow\">Mezzio<\/a> (\u044d\u0442\u043e \u0431\u044b\u0432\u0448\u0438\u0439 Zend Expressive), \u0447\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043b\u044e\u0434\u0430\u0442\u044c \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u044b SOLID \u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u0443\u044e \u0433\u0438\u0431\u043a\u043e\u0441\u0442\u044c \u043f\u0440\u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0438 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432.   <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-13\/\" rel=\"nofollow\">PSR-13<\/a>: Hypermedia Links<\/b><br \/>  \u041d\u0435 \u0441\u0430\u043c\u044b\u0439 \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u0432, \u0447\u0442\u043e\u0431\u044b \u0443\u043d\u0438\u0444\u0438\u0446\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043e\u0431\u0449\u0438\u0439 \u0444\u043e\u0440\u043c\u0430\u0442 hypermedia \u0441\u0441\u044b\u043b\u043e\u043a. <br \/> \n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">LinkInterface, EvolvableLinkInterface \u0438 LinkProviderInterface EvolvableLinkProviderInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\"><b>LinkInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface LinkInterface {     public function getHref();     public function isTemplated();     public function getRels();     public function getAttributes(); }<\/code><\/pre>\n<p>  <b>EvolvableLinkInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface EvolvableLinkInterface extends LinkInterface {     public function withHref($href);     public function withRel($rel);     public function withoutRel($rel);     public function withAttribute($attribute, $value);     public function withoutAttribute($attribute); }<\/code><\/pre>\n<p>  <b>LinkProviderInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface LinkProviderInterface {     public function getLinks();     public function getLinksByRel($rel); }<\/code><\/pre>\n<p>  <b>EvolvableLinkProviderInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface EvolvableLinkProviderInterface extends LinkProviderInterface {     public function withLink(LinkInterface $link);     public function withoutLink(LinkInterface $link); }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u0430, \u043c\u043e\u0436\u043d\u043e \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 hypermedia \u0441\u0441\u044b\u043b\u043e\u043a \u0432 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0435 HTML \u0438 \u0432 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u0444\u043e\u0440\u043c\u0430\u0442\u0430\u0445 API. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c, \u0435\u0441\u043b\u0438 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u0441\u044b\u043b\u043e\u043a \u0432 HTML \u043f\u043e\u043d\u044f\u0442\u0435\u043d, \u0442\u043e \u0441 API \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u0442\u044c\u0441\u044f \u0441\u0442\u0430\u0442\u044c\u044f &quot;<a href=\"https:\/\/habr.com\/ru\/company\/aligntechnology\/blog\/281206\/\">Hypermedia \u2014 \u0442\u043e \u0431\u0435\u0437 \u0447\u0435\u0433\u043e \u0412\u0430\u0448\u0435 API \u043d\u0435 \u0441\u043e\u0432\u0441\u0435\u043c REST<\/a>&quot;.<br \/>  \u041f\u0440\u0438\u043c\u0435\u0440\u043e\u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430 \u043d\u0435 \u043c\u043d\u043e\u0433\u043e: <a href=\"https:\/\/github.com\/symfony\/web-link\" rel=\"nofollow\">Symfony Web Link<\/a> \u0438 <a href=\"https:\/\/github.com\/Crell\/HtmlModel\" rel=\"nofollow\">Html Model<\/a>.   <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-14\/\" rel=\"nofollow\">PSR-14<\/a>: Event Dispatcher<\/b><br \/>  \u0426\u0435\u043b\u044c\u044e \u044d\u0442\u043e\u0433\u043e PSR \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043e\u0431\u0449\u0435\u0433\u043e \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c\u0430 \u0434\u043b\u044f \u0434\u0438\u0441\u043f\u0435\u0442\u0447\u0435\u0440\u0438\u0437\u0430\u0446\u0438\u0438 \u0441\u043e\u0431\u044b\u0442\u0438\u0439, \u0447\u0442\u043e\u0431\u044b \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0438 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u044b \u043c\u043e\u0433\u043b\u0438 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0432 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u0445 \u0438 \u0441\u0440\u0435\u0434\u0430\u0445. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u0432:<br \/> \n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">EventDispatcherInterface, ListenerProviderInterface \u0438 StoppableEventInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\"><b>EventDispatcherInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface EventDispatcherInterface {     public function dispatch(object $event); }<\/code><\/pre>\n<p>  <b>ListenerProviderInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface ListenerProviderInterface {     public function getListenersForEvent(object $event) : iterable; }<\/code><\/pre>\n<p>  <b>StoppableEventInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface StoppableEventInterface {     public function isPropagationStopped() : bool; }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u0414\u0438\u0441\u043f\u0435\u0442\u0447\u0435\u0440\u0438\u0437\u0430\u0446\u0438\u044f \u0441\u043e\u0431\u044b\u0442\u0438\u0439 \u2014 \u044d\u0442\u043e \u0440\u0430\u0441\u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u043d\u044b\u0439 \u0438 \u0445\u043e\u0440\u043e\u0448\u043e \u043f\u0440\u043e\u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0438\u0439 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430\u043c \u043b\u0435\u0433\u043a\u043e \u0438 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0442\u044c \u043b\u043e\u0433\u0438\u043a\u0443 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f. \u0414\u0435\u0442\u0430\u043b\u044c\u043d\u043e \u0434\u0430\u043d\u043d\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0445\u043e\u0440\u043e\u0448\u043e \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u0441\u0442\u0430\u0442\u044c\u044f &quot;<a href=\"https:\/\/habr.com\/ru\/company\/oleg-bunin\/blog\/450812\/\">PSR-14 \u2014 \u0433\u043b\u0430\u0432\u043d\u043e\u0435 \u0441\u043e\u0431\u044b\u0442\u0438\u0435 \u0432 PHP<\/a>&quot;.<br \/>  \u0427\u0442\u043e\u0431\u044b \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u0432 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0438, \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u044e \u0432\u0437\u0433\u043b\u044f\u043d\u0443\u0442\u044c \u043d\u0430 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e <a href=\"https:\/\/github.com\/symfony\/event-dispatcher\" rel=\"nofollow\">Symfony Event Dispatcher<\/a>, <a href=\"https:\/\/github.com\/yiisoft\/event-dispatcher\" rel=\"nofollow\">YiiSoft Event Dispatcher<\/a> \u0438 <a href=\"https:\/\/github.com\/search?l=PHP&amp;o=desc&amp;q=psr-14&amp;s=stars&amp;type=Repositories\" rel=\"nofollow\">\u0434\u0440\u0443\u0433\u0438\u0435<\/a>.   <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-16\/\" rel=\"nofollow\">PSR-16<\/a>: Simple Cache<\/b><br \/>  \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 PSR-6, \u044d\u0442\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u00ab\u043c\u043e\u0449\u043d\u0430\u044f\u00bb \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u0434\u043b\u044f \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u043a\u0435\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u043e\u0434\u043d\u0430\u043a\u043e \u0432 \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432 \u0442\u0430\u043a\u0430\u044f \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043c\u043e\u0436\u0435\u0442 \u043e\u043a\u0430\u0437\u0430\u0442\u044c\u0441\u044f \u0438\u0437\u0431\u044b\u0442\u043e\u0447\u043d\u043e\u0439.\n<p>  \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0431\u044b\u043b \u043f\u0440\u0438\u043d\u044f\u0442 PSR-16. \u042d\u0442\u043e\u0442 \u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u043f\u043e\u0434\u0445\u043e\u0434 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d \u043d\u0430 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u0434\u043b\u044f \u043e\u0431\u0449\u0438\u0445 \u0441\u043b\u0443\u0447\u0430\u0435\u0432.   <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">CacheInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"php\">interface CacheInterface {     public function get($key, $default = null);     public function set($key, $value, $ttl = null);     public function delete($key);     public function clear();     public function getMultiple($keys, $default = null);     public function setMultiple($values, $ttl = null);     public function deleteMultiple($keys);     public function has($key); }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u0412 \u0441\u043f\u0438\u0441\u043a\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0439 \u0432\u0441\u0435 \u0442\u043e\u0442-\u0436\u0435 <a href=\"https:\/\/symfony.com\/doc\/current\/components\/cache\/psr6_psr16_adapters.html\" rel=\"nofollow\">Symfony Cache<\/a> \u0438 <a href=\"https:\/\/docs.laminas.dev\/laminas-cache\/psr16\/\" rel=\"nofollow\">Laminas Cache<\/a> (\u0431\u044b\u0432\u0448\u0438\u0439 Zend).   <\/li>\n<\/ul>\n<h2><font color=\"#9cc2ce\">HTTP<\/font><\/h2>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/8p\/cw\/6z\/8pcw6ziqph7ebga3mpsi0k9eudw.png\" alt=\"PSR-HTTP\"><\/p>\n<p>  \u0415\u0441\u043b\u0438 \u0440\u0435\u0447\u044c \u0438\u0434\u0435\u0442 \u043e WEB-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438, \u0442\u043e \u043d\u0435 \u0432\u0430\u0436\u043d\u043e \u043d\u0430 \u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u043b\u043e\u0436\u043d\u0430\u044f \u0432 \u043d\u0435\u043c \u0431\u0438\u0437\u043d\u0435\u0441-\u043b\u043e\u0433\u0438\u043a\u0430, \u043f\u043e \u0444\u0430\u043a\u0442\u0443 \u043e\u043d\u043e \u0434\u0435\u043b\u0430\u0435\u0442 \u0432\u0441\u0435\u0433\u043e 2 \u0432\u0435\u0449\u0438 \u2014 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 Request \u0438 \u043e\u0442\u0434\u0430\u0435\u0442 Response. \u042d\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442, \u0447\u0442\u043e \u0442\u0430\u043a \u0438\u043b\u0438 \u0438\u043d\u0430\u0447\u0435, \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u044d\u0442\u0438 \u043e\u0431\u044a\u0435\u043a\u0442\u044b \u0443 \u0441\u0435\u0431\u044f \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435. <\/p>\n<p>  \u041f\u043e\u0436\u0430\u043b\u0443\u0439, \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u0441\u0430\u043c\u044b\u0445 \u0441\u043b\u043e\u0436\u043d\u044b\u0445 \u0437\u0430\u0434\u0430\u0447, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043d\u0435\u0440\u0435\u0434\u043a\u043e \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u0435\u0442 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043a\u043e\u0434\u0430 \u043c\u0435\u0436\u0434\u0443 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u043c\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u043c\u0438. \u0415\u0441\u043b\u0438 \u0445\u043e\u0440\u043e\u0448\u043e \u0430\u0431\u0441\u0442\u0440\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0443\u0447\u0430\u0441\u0442\u043a\u0438 \u0431\u0438\u0437\u043d\u0435\u0441 \u043b\u043e\u0433\u0438\u043a\u0438, \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u044b \u0438 \u043c\u043e\u0434\u0443\u043b\u0438 \u043f\u0435\u0440\u0435\u043d\u0435\u0441\u0442\u0438 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e (\u0441 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u0437\u0430\u0442\u0440\u0430\u0442\u0430\u043c\u0438), \u0442\u043e \u0441 \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u043e\u043c \u0431\u043e\u043b\u0435\u0435 \u0432\u044b\u0441\u043e\u043a\u043e\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u043e\u0432 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u0432) \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u044e\u0442 \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u0438.<\/p>\n<p>  \u0413\u0440\u0443\u043f\u043f\u0430 PHP-FIG \u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u0443\u044e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443 \u0438 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u044b \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u0438 \u043d\u0430\u0434 HTTP.<\/p>\n<ul>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-7\/\" rel=\"nofollow\">PSR-7<\/a>: HTTP Message Interfaces<\/b><br \/>  \u0426\u0435\u043b\u044c \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430, \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043e\u0431\u0449\u0438\u0439 \u043d\u0430\u0431\u043e\u0440 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u0432 \u0434\u043b\u044f \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u043e\u0432, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0435 \u043c\u043e\u0433\u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0435 \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u0438 \u043d\u0430\u0434 Request \u0438 Response \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438. \u042d\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u0442 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430\u043c \u043f\u0438\u0441\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0439, \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u044b\u0439 \u043e\u0442 \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430 \u043a\u043e\u0434. \u0421\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043e\u0431\u044a\u0435\u043c\u043d\u0430: <br \/> \n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">MessageInterface, RequestInterface, ServerRequestInterface, ResponseInterface, StreamInterface, UriInterface \u0438 UploadedFileInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\"><b>MessageInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface MessageInterface {     public function getProtocolVersion();     public function withProtocolVersion($version);     public function getHeaders();     public function hasHeader($name);     public function getHeader($name);     public function getHeaderLine($name);     public function withHeader($name, $value);     public function withAddedHeader($name, $value);     public function withoutHeader($name);     public function getBody();     public function withBody(StreamInterface $body); }<\/code><\/pre>\n<p>  <b>RequestInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface RequestInterface extends MessageInterface {     public function getRequestTarget();     public function withRequestTarget($requestTarget);     public function getMethod();     public function withMethod($method);     public function getUri();     public function withUri(UriInterface $uri, $preserveHost = false); }<\/code><\/pre>\n<p>  <b>ServerRequestInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface ServerRequestInterface extends RequestInterface {     public function getServerParams();     public function getCookieParams();     public function withCookieParams(array $cookies);     public function getQueryParams();     public function withQueryParams(array $query);     public function getUploadedFiles();     public function withUploadedFiles(array $uploadedFiles);     public function getParsedBody();     public function withParsedBody($data);     public function getAttributes();     public function getAttribute($name, $default = null);     public function withAttribute($name, $value);     public function withoutAttribute($name); }<\/code><\/pre>\n<p>  <b>ResponseInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface ResponseInterface extends MessageInterface {     public function getStatusCode();     public function withStatus($code, $reasonPhrase = '');     public function getReasonPhrase(); }<\/code><\/pre>\n<p>  <b>StreamInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface StreamInterface {     public function __toString();     public function close();     public function detach();     public function getSize();     public function tell();     public function eof();     public function isSeekable();     public function seek($offset, $whence = SEEK_SET);     public function rewind();     public function isWritable();     public function write($string);     public function isReadable();     public function read($length);     public function getContents();     public function getMetadata($key = null); }<\/code><\/pre>\n<p>  <b>UriInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface UriInterface {     public function getScheme();     public function getAuthority();     public function getUserInfo();     public function getHost();     public function getPort();     public function getPath();     public function getQuery();     public function getFragment();     public function withScheme($scheme);     public function withUserInfo($user, $password = null);     public function withHost($host);     public function withPort($port);     public function withPath($path);     public function withQuery($query);     public function withFragment($fragment);     public function __toString(); }<\/code><\/pre>\n<p>  <b>UploadedFileInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface UploadedFileInterface {     public function getStream();     public function moveTo($targetPath);     public function getSize();     public function getError();     public function getClientFilename();     public function getClientMediaType(); }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u0410 \u0431\u043e\u043b\u0435\u0435 \u0434\u0435\u0442\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0441 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u043c\u0438 \u043c\u043e\u0436\u043d\u043e \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u0442\u044c \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 &quot;<a href=\"https:\/\/habr.com\/ru\/post\/250343\/\">PSR-7 \u0432 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u0445<\/a>&quot;.<\/p>\n<p>  <a href=\"https:\/\/github.com\/laminas\/laminas-diactoros\" rel=\"nofollow\">Laminas Diactoros<\/a> (\u0431\u044b\u0432\u0448\u0438\u0439 Zend Diactoros) \u2014 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0442\u043b\u0438\u0447\u043d\u043e\u0439 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0435\u0439 PSR-7. \u0418 \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432 \u044d\u043a\u043e\u0441\u0438\u0441\u0442\u0435\u043c\u0435 PHP \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u044b \u0441\u0438\u043c\u0444\u043e\u043d\u0438 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u044b, \u0441\u0440\u0435\u0434\u0438 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 <a href=\"https:\/\/github.com\/symfony\/http-foundation\" rel=\"nofollow\">Symfony HTTP-Foundation<\/a>. \u0414\u0430\u043d\u043d\u044b\u0439 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 \u043d\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043b \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0443 PSR-7, \u043d\u043e \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u043b <a href=\"https:\/\/github.com\/symfony\/psr-http-message-bridge\" rel=\"nofollow\">\u043c\u043e\u0441\u0442<\/a>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0440\u0430\u043d\u0435\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u043b \u0447\u0435\u0440\u0435\u0437 Zend Diactoros, \u043d\u043e \u0441\u0435\u0439\u0447\u0430\u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 <a href=\"https:\/\/github.com\/Nyholm\/psr7\" rel=\"nofollow\">\u0434\u0440\u0443\u0433\u0443\u044e \u0438\u043c\u043f\u043b\u0435\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044e psr-7<\/a>.   <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-15\/\" rel=\"nofollow\">PSR-15<\/a>: HTTP Handlers<\/b><br \/>  \u0421\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b \u0434\u043b\u044f \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432 HTTP-\u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 <br \/>  \u0438 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u043f\u0440\u043e\u043c\u0435\u0436\u0443\u0442\u043e\u0447\u043d\u043e\u0433\u043e \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e\u0433\u043e \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0435\u043d\u0438\u044f HTTP-\u0441\u0435\u0440\u0432\u0435\u0440\u0430.<br \/> \n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">RequestHandlerInterface \u0438 MiddlewareInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\"><b>RequestHandlerInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface RequestHandlerInterface {     public function handle(ServerRequestInterface $request): ResponseInterface; }<\/code><\/pre>\n<p>  <b>MiddlewareInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface MiddlewareInterface {     public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface; }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u0415\u0441\u043b\u0438 \u043d\u0435 \u0432\u0434\u0430\u0432\u0430\u0442\u044c\u0441\u044f \u0432\u043e \u0432\u0441\u0435 \u0442\u043e\u043d\u043a\u043e\u0441\u0442\u0438, \u0442\u043e \u043f\u043e \u0441\u0443\u0442\u0438 \u044d\u0442\u043e \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043f\u0438\u0441\u0430\u0442\u044c \u043d\u0435\u043a\u0438\u0435 \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0442\u043d\u044b\u0435 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u044b \u0434\u043b\u044f \u043f\u043e\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0433\u043e \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u043c\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u043c\u0438. <\/p>\n<p>  Middleware framework <a href=\"https:\/\/github.com\/mezzio\/mezzio\" rel=\"nofollow\">Mezzio<\/a> (\u0431\u044b\u0432\u0448\u0438\u0439 Zend Expressie) \u043e\u0442\u043b\u0438\u0447\u043d\u043e \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0438\u0440\u0443\u0435\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 PSR-15.   <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-17\/\" rel=\"nofollow\">PSR-17<\/a>: HTTP Factories<\/b><br \/>  PSR-17 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u043e\u0431\u0449\u0438\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0434\u043b\u044f \u0444\u0430\u0431\u0440\u0438\u043a, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u043e\u0437\u0434\u0430\u044e\u0442 HTTP-\u043e\u0431\u044a\u0435\u043a\u0442\u044b, \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0435 \u0441 PSR-7.\n<p>  PSR-7 \u043d\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0430\u0446\u0438\u0438 \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c HTTP-\u043e\u0431\u044a\u0435\u043a\u0442\u044b. \u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442\u044c \u043a \u0442\u0440\u0443\u0434\u043d\u043e\u0441\u0442\u044f\u043c \u043f\u0440\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u0438\u0445 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0432\u043d\u0443\u0442\u0440\u0438 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0435 \u043f\u0440\u0438\u0432\u044f\u0437\u0430\u043d\u044b \u043a \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0439 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 PSR-7.<\/p>\n<p>  \u0418\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b, \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0435 \u0432 \u044d\u0442\u043e\u0439 \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438, \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u044e\u0442 \u043c\u0435\u0442\u043e\u0434\u044b, \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043c\u043e\u0436\u043d\u043e \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c PSR-7 \u043e\u0431\u044a\u0435\u043a\u0442\u044b.  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">RequestFactoryInterface, ResponseFactoryInterface, ServerRequestFactoryInterface, StreamFactoryInterface, UploadedFileFactoryInterface \u0438 UriFactoryInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\"><b>RequestFactoryInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface RequestFactoryInterface {     public function createRequest(string $method, $uri): RequestInterface; }<\/code><\/pre>\n<p>  <b>ResponseFactoryInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface ResponseFactoryInterface {     public function createResponse(int $code = 200, string $reasonPhrase = ''): ResponseInterface; }<\/code><\/pre>\n<p>  <b>ServerRequestFactoryInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface ServerRequestFactoryInterface {     public function createServerRequest(string $method, $uri, array $serverParams = []): ServerRequestInterface; }<\/code><\/pre>\n<p>  <b>StreamFactoryInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface StreamFactoryInterface {     public function createStream(string $content = ''): StreamInterface;     public function createStreamFromFile(string $filename, string $mode = 'r'): StreamInterface;     public function createStreamFromResource($resource): StreamInterface; }<\/code><\/pre>\n<p>  <b>UploadedFileFactoryInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface UploadedFileFactoryInterface {     public function createUploadedFile(         StreamInterface $stream,         int $size = null,         int $error = \\UPLOAD_ERR_OK,         string $clientFilename = null,         string $clientMediaType = null     ): UploadedFileInterface; }<\/code><\/pre>\n<p>  <b>UriFactoryInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface UriFactoryInterface {     public function createUri(string $uri = '') : UriInterface; }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u043f\u0440\u0438\u043c\u0435\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f PSR-17 \u043c\u043e\u0436\u043d\u043e \u0432 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 <a href=\"https:\/\/github.com\/Nyholm\/psr7\" rel=\"nofollow\">\u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 PSR-7<\/a>.   <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-18\/\" rel=\"nofollow\">PSR-18<\/a>: HTTP Client<\/b><br \/>  PSR-18 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442 \u043e\u0431\u0449\u0438\u0435 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b \u0434\u043b\u044f \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0438 PSR-7 HTTP-\u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f HTTP-\u043e\u0442\u0432\u0435\u0442\u043e\u0432. <br \/> \n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">ClientInterface, RequestExceptionInterface \u0438 NetworkExceptionInterface<\/b>                         <\/p>\n<div class=\"spoiler_text\"><b>ClientInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface ClientInterface {     public function sendRequest(RequestInterface $request): ResponseInterface; }<\/code><\/pre>\n<p>  <b>RequestExceptionInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface RequestExceptionInterface extends ClientExceptionInterface {     public function getRequest(): RequestInterface; }<\/code><\/pre>\n<p>  <b>NetworkExceptionInterface<\/b>  <\/p>\n<pre><code class=\"php\">interface NetworkExceptionInterface extends ClientExceptionInterface {     public function getRequest(): RequestInterface; }<\/code><\/pre>\n<p>  <\/div>\n<\/p><\/div>\n<p>  \u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u0438\u0433\u043e\u0434\u043d\u044b\u043c\u0438 \u0434\u043b\u044f \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f, \u0442\u0430\u043a \u043a\u0430\u043a \u0443\u043c\u0435\u043d\u044c\u0448\u0430\u0435\u0442 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u0438 \u0441\u043d\u0438\u0436\u0430\u0435\u0442 \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e\u0441\u0442\u044c \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442\u043e\u0432 \u0432\u0435\u0440\u0441\u0438\u0439.<\/p>\n<p>  \u0422\u0430\u043a\u0436\u0435 \u0432 \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0443\u043a\u0430\u0437\u0430\u043d\u043e, \u0447\u0442\u043e HTTP-\u043a\u043b\u0438\u0435\u043d\u0442\u044b \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043c\u0435\u043d\u0435\u043d\u044b \u0441\u043e\u0433\u043b\u0430\u0441\u043d\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443 \u043f\u043e\u0434\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u041b\u0438\u0441\u043a\u043e\u0432\u0430. \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u0432\u0441\u0435 \u043a\u043b\u0438\u0435\u043d\u0442\u044b \u0414\u041e\u041b\u0416\u041d\u042b \u0432\u0435\u0441\u0442\u0438 \u0441\u0435\u0431\u044f \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u043e \u043f\u0440\u0438 \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u0430.<\/p>\n<p>  \u041f\u0440\u0438\u043c\u0435\u0440 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 PSR-18 \u043c\u043e\u0436\u043d\u043e \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0432 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 <a href=\"https:\/\/github.com\/symfony\/http-client\" rel=\"nofollow\">Symfony HTTP-client<\/a>.   <\/li>\n<\/ul>\n<p>  \u041f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u043d\u0430\u044f \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u044f \u043d\u0430\u0434 HTTP \u2014 \u044d\u0442\u043e \u0432\u0435\u0441\u044c\u043c\u0430 \u0441\u0435\u0440\u044c\u0435\u0437\u043d\u0430\u044f \u0437\u0430\u044f\u0432\u043a\u0430 \u043d\u0430 \u043f\u043e\u043f\u044b\u0442\u043a\u0443 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0435 \u0438 \u043d\u0435 \u0437\u0430\u0432\u0438\u0441\u044f\u0449\u0438\u0435 \u043e\u0442 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0445 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a \u0438 \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u043e\u0432 \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u044b\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u044f.<\/p>\n<p>  \u041d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435, \u043a\u043e\u043d\u0435\u0447\u043d\u043e \u0432\u0441\u0435 \u043d\u0430 \u043c\u043d\u043e\u0433\u043e \u0441\u043b\u043e\u0436\u043d\u0435\u0435 \u0438 \u0435\u0441\u0442\u044c \u0441\u0432\u043e\u0438 \u043d\u044e\u0430\u043d\u0441\u044b \u0438 \u043f\u043e\u0434\u0432\u043e\u0434\u043d\u044b\u0435 \u043a\u0430\u043c\u043d\u0438, \u043e\u0434\u043d\u0430\u043a\u043e PHP-FIG \u0434\u0435\u043b\u0430\u0435\u0442 \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0448\u0430\u0433 \u0432\u043f\u0435\u0440\u0435\u0434 \u0432 \u044d\u0442\u043e\u043c \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0438.<\/p>\n<h2><font color=\"#9cc2ce\">\u0421\u0442\u0438\u043b\u044c \u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f<\/font><\/h2>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/en\/vn\/ep\/envnepehe819scmjhhux-4cfd4q.png\" alt=\"code style\"><\/p>\n<p>  \u0414\u043e \u043f\u043e\u044f\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043e\u0432 \u0441\u0442\u0438\u043b\u044f \u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u043a\u0430\u0436\u0434\u044b\u0439 \u0438\u0437 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432 \u043e\u0444\u043e\u0440\u043c\u043b\u044f\u043b \u0441\u0432\u043e\u0439 \u043a\u043e\u0434 \u043f\u043e-\u0440\u0430\u0437\u043d\u043e\u043c\u0443: \u043e\u0434\u043d\u0438 \u043f\u0438\u0441\u0430\u043b\u0438 CLASSNAME, \u0434\u0440\u0443\u0433\u0438\u0435 ClassName, \u0430 \u0442\u0440\u0435\u0442\u044c\u0438 Class_Name, \u0432\u0435\u0447\u043d\u044b\u0439 \u0441\u043f\u043e\u0440 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0442\u0430\u0431\u043e\u0432 \u0438 \u043f\u0440\u043e\u0431\u0435\u043b\u043e\u0432, \u0430 \u0435\u0449\u0435 StudlyCaps vs \u0441amelCase vs snake_case \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435.<\/p>\n<p>  \u0426\u0435\u043b\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0445 PSR \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043e\u0432 \u0443\u043c\u0435\u043d\u044c\u0448\u0438\u0442\u044c <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%9A%D0%BE%D0%B3%D0%BD%D0%B8%D1%82%D0%B8%D0%B2%D0%BD%D0%BE%D0%B5_%D0%B8%D1%81%D0%BA%D0%B0%D0%B6%D0%B5%D0%BD%D0%B8%D0%B5\" rel=\"nofollow\">\u043a\u043e\u0433\u043d\u0438\u0442\u0438\u0432\u043d\u043e\u0435 \u0438\u0441\u043a\u0430\u0436\u0435\u043d\u0438\u0435<\/a> \u043f\u0440\u0438 \u0447\u0442\u0435\u043d\u0438\u0438 \u043a\u043e\u0434\u0430 \u043e\u0442 \u0440\u0430\u0437\u043d\u044b\u0445 \u0430\u0432\u0442\u043e\u0440\u043e\u0432.<\/p>\n<ul>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-1\/\" rel=\"nofollow\">PSR-1<\/a>: Basic Coding Standard<\/b>   <\/li>\n<li><s><b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-2\/\" rel=\"nofollow\">PSR-2<\/a> \u2014 Coding Style Guide<\/b><\/s> <font color=\"#808080\">\u0423\u0441\u0442\u0430\u0440\u0435\u043b<\/font>   <\/li>\n<li> <b><a href=\"https:\/\/www.php-fig.org\/psr\/psr-12\/\" rel=\"nofollow\">PSR-12<\/a>: Extended Coding Style Guide <\/b>   <\/li>\n<\/ul>\n<p>  \u041e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0435 \u0432\u044b\u0448\u0435 \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043e\u0431\u044a\u0435\u043c\u043d\u044b\u0435, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0442\u043e\u043b\u044c\u043a\u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u0438\u0437 PSR-1:<\/p>\n<ul>\n<li>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u0442\u044d\u0433\u043e\u0432 &lt;?php \u0438 &lt;?=<\/li>\n<li>\u0422\u043e\u043b\u044c\u043a\u043e UTF-8 \u0431\u0435\u0437 BOM \u0434\u043b\u044f php \u043a\u043e\u0434\u0430<\/li>\n<li>\u041d\u0435 \u0441\u0442\u043e\u0438\u0442 \u043c\u0435\u0448\u0430\u0442\u044c \u0440\u0430\u0437\u043d\u044b\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b \u0432 \u043e\u0434\u043d\u043e\u043c \u0444\u0430\u0439\u043b\u0435 (1 \u0444\u0430\u0439\u043b = 1 \u043a\u043b\u0430\u0441\u0441)<\/li>\n<li>\u041f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u043e \u0438\u043c\u0435\u043d \u0438 \u043a\u043b\u0430\u0441\u0441\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c [<s>PSR-0<\/s>, PSR-4]<\/li>\n<li>\u041a\u043b\u0430\u0441\u0441\u044b \u043e\u0431\u044a\u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u0432 `StudlyCase`<\/li>\n<li>\u041a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u044b \u043e\u0431\u044a\u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u0432 \u0422\u0410\u041a\u041e\u041c_\u0412\u0418\u0414\u0415<\/li>\n<li>\u041c\u0435\u0442\u043e\u0434\u044b \u043e\u0431\u044a\u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u0432 `camelCase`<\/li>\n<\/ul>\n<p>  \u041d\u0430 \u0441\u0430\u043c\u043e\u043c \u0434\u0435\u043b\u0435, \u043d\u0435\u0442 \u0441\u043c\u044b\u0441\u043b\u0430 \u043f\u043e\u043c\u043d\u0438\u0442\u044c \u043f\u0440\u043e \u043a\u0430\u0436\u043d\u044b\u0439 \u043f\u0443\u043d\u043a\u0442 \u043e \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0435 \u0441\u043a\u043e\u0431\u043a\u0438, \u043f\u0440\u043e\u0431\u0435\u043b\u0435, \u0442\u0430\u0431\u0435 \u0438 \u0442.\u043f., \u0442\u0430\u043a \u043a\u0430\u043a \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0438 \u043e\u0442\u0444\u043e\u0440\u043c\u0430\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u0434\u043e\u0432\u0443\u044e \u0431\u0430\u0437\u0443 \u043f\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0443 <s>PSR-2<\/s>\/PSR-12:<\/p>\n<ul>\n<li>\u0420\u0443\u0447\u043d\u043e\u0439 \u0440\u0435\u0436\u0438\u043c: \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c <a href=\"https:\/\/www.jetbrains.com\/help\/phpstorm\/reformat-and-rearrange-code.html#\" rel=\"nofollow\">reformat code \u0432 phpStorm<\/a>.<\/li>\n<li>\u0411\u043e\u043b\u0435\u0435 \u043f\u0440\u043e\u0434\u0432\u0438\u043d\u0443\u0442\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442: \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u0430\u043a\u043e\u0439-\u043d\u0438\u0431\u0443\u0442\u044c \u043a\u043e\u0434\u0441\u043d\u0438\u0444\u0435\u0440, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 <a href=\"https:\/\/github.com\/FriendsOfPHP\/PHP-CS-Fixer\" rel=\"nofollow\">PHP CS Fixer<\/a> (\u0447\u0430\u0441\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0432 CI, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0442\u044c \u043a\u043e\u043c\u043c\u0438\u0442\u044b \u0441 \u043d\u0435\u043e\u0442\u0444\u043e\u0440\u043c\u0430\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c \u043a\u043e\u0434\u043e\u043c).<\/li>\n<\/ul>\n<p>  <b>\u0410\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0444\u043e\u0440\u043c\u0430\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043e\u0431\u044b\u0447\u043d\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0442\u0430\u043a:<\/b><br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/30\/mi\/d8\/30mid8bebpbc0hxomtistnhz00c.gif\"><\/p>\n<p>  \u0410 \u0434\u043b\u044f \u0434\u043e\u0441\u0442\u0438\u0436\u0435\u043d\u0438\u044f \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043f\u0440\u043e\u0444\u0438\u0442\u0430 \u043c\u043e\u0436\u043d\u043e \u0440\u0430\u0441\u0448\u0438\u0440\u0438\u0442\u044c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u044b \u0441\u0442\u0438\u043b\u044f \u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u043e\u043c \u043f\u043e \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u044e <a href=\"https:\/\/github.com\/eshell192007\/clean-code-php\" rel=\"nofollow\">\u0447\u0438\u0441\u0442\u043e\u0433\u043e \u043a\u043e\u0434\u0430<\/a>.<\/p>\n<h2>\u041f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f PSR<\/h2>\n<p>  \u0421\u0430\u043c\u0430 \u0430\u0431\u0431\u0440\u0435\u0432\u0438\u0430\u0442\u0443\u0440\u0430 PSR \u0432\u044b\u0448\u043b\u0430 \u0437\u0430 \u0440\u0430\u043c\u043a\u0438 \u043f\u0440\u043e\u0441\u0442\u044b\u0445 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0430\u0446\u0438\u0439 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0441\u0442\u0438\u043b\u044f \u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. \u0410 \u0433\u0440\u0443\u043f\u043f\u0430 PHP-FIG \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u0435\u0442 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0442 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043c\u043e\u0449\u043d\u0443\u044e \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u044e \u0434\u043b\u044f \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u0431\u0430\u0437\u043e\u0432\u044b\u0445 \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u0441 \u043f\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0438 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043a\u043e\u0434 \u0431\u043e\u043b\u0435\u0435 \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u044b\u043c \u043e\u0442 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0445 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0439 \u0438 \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u043e\u0432 (\u043d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 \u0432\u0441\u0435 \u043a\u0443\u0434\u0430 \u0441\u043b\u043e\u0436\u043d\u0435\u0435, \u043d\u043e \u0444\u0443\u043d\u0434\u0430\u043c\u0435\u043d\u0442 \u0443\u0436\u0435 \u0437\u0430\u043b\u043e\u0436\u0435\u043d).<\/p>\n<p>  <b>\u0414\u043b\u044f \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u0438 \u0445\u043e\u0440\u043e\u0448\u0435\u0439 \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u0438 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443 middleware framework <a href=\"https:\/\/docs.mezzio.dev\/mezzio\/\" rel=\"nofollow\">Mezzio<\/a>:<\/b><br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/1e\/eh\/91\/1eeh91l-mftcpia0dfnfbprqrv4.png\" alt=\"install\"><\/p>\n<p>  \u0421\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0438\u0437\u0430\u0446\u0438\u044f \u0432 \u0432\u0438\u0434\u0435 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u0432 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u044b\u0431\u043e\u0440\u0430 \u043b\u044e\u0431\u043e\u0439 \u0438\u043c\u043f\u043b\u0435\u043c\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0439 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438. \u0422\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u043e\u0431\u043b\u0435\u0433\u0447\u0438\u0442\u044c \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u0441\u0441\u044b\u043b\u0430\u044f\u0441\u044c \u043d\u0430 \u0445\u043e\u0440\u043e\u0448\u043e \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0435 PSR \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0438.<\/p>\n<h2>\u0418 \u0432 \u0437\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/h2>\n<p>  PSR \u2014 \u044d\u0442\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0433\u043e\u0434\u043d\u044b\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u044b \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0440\u0435\u0448\u0430\u0442\u044c \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043a\u043e\u0434\u0430 \u0438 \u043e\u0431\u043b\u0435\u0433\u0447\u0438\u0442\u044c \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u0443\u044e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0443. \u041e\u0434\u043d\u0430\u043a\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 PSR \u043e\u0441\u0442\u0430\u0435\u0442\u0441\u044f \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0430\u0446\u0438\u0435\u0439, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u0430\u043a \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u044b, \u0442\u0430\u043a \u0438 \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0438\u0445 \u0432\u043e\u043e\u0431\u0449\u0435. <\/p>\n<p>  \u041b\u0438\u0447\u043d\u043e \u044f \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u044e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0438 \u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f \u0441\u0432\u043e\u0438\u043c \u043e\u043f\u044b\u0442\u043e\u043c \u0441 \u0441\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u043e\u043c PHP. <\/p>\n<p>  \u0421\u043f\u0430\u0441\u0438\u0431\u043e, \u0447\u0442\u043e \u0434\u043e\u0447\u0438\u0442\u0430\u043b\u0438 \u0434\u043e \u043a\u043e\u043d\u0446\u0430!<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/458484\/\"> https:\/\/habr.com\/ru\/post\/458484\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/post\/458484\/\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/ka\/wv\/yg\/kawvygfnunfisi5stn1zjqg3v58.png\" alt=\"PHP-FIG\"><\/p>\n<p>  <b>PSR \u2014 \u0427\u0443\u0442\u044c \u0431\u043e\u043b\u044c\u0448\u0435, \u0447\u0435\u043c \u0441\u0442\u0438\u043b\u044c \u043e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u0434\u0430.<\/b><\/p>\n<p>  \u041a\u0430\u043a \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430, \u043c\u043d\u043e\u0433\u0438\u0435 PHP-\u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u0437\u043d\u0430\u043a\u043e\u043c\u044b \u0441 \u0430\u0431\u0431\u0440\u0435\u0432\u0438\u0430\u0442\u0443\u0440\u043e\u0439 PSR. \u041e\u0434\u043d\u0430\u043a\u043e \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u043e \u0432\u0441\u0435 \u0435\u0449\u0435 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u044b \u0437\u043d\u0430\u043d\u0438\u0435\u043c, \u0447\u0442\u043e PSR \u044d\u0442\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u043e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u0434\u0430. <\/p>\n<p>  \u0420\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 PHP-FIG (PHP Framework Interop Group), \u0433\u0440\u0443\u043f\u043f\u0430 \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0439 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u0438 PHP, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0437\u0430\u043d\u0438\u043c\u0430\u044e\u0442\u0441\u044f \u0440\u0430\u0437\u0432\u0438\u0442\u0438\u0435\u043c PSR (PHP Standards Recommendations) \u0448\u0430\u0433\u043d\u0443\u043b\u0438 \u0434\u0430\u043b\u0435\u043a\u043e \u0432\u043f\u0435\u0440\u0435\u0434. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0430\u0432\u0430\u0439\u0442\u0435 \u0440\u0430\u0437\u0431\u0435\u0440\u0435\u043c\u0441\u044f, \u0447\u0442\u043e \u0438\u0437 \u0441\u0435\u0431\u044f \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 PSR\u2026<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-302419","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/302419","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=302419"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/302419\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=302419"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=302419"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=302419"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}