{"action":"created","comment":{"url":"https://api.github.com/repos/seegno/coding-standards/pulls/comments/26377185","id":26377185,"diff_hunk":"@@ -0,0 +1,108 @@\n+# PHP Coding Standards\n+\n+This documentation describes the **PHP** coding standards for all Seegno projects.\n+\n+Our main focus will be the use of [Symfony2](http://symfony.com/) framework.\n+\n+## Table of contents\n+\n+1. [DocBlocks](#docblocks)\n+1. [Visibility](#visibility)\n+\n+## DocBlocks\n+\n+Classes and methods should have a multi-line `DocComment` with a brief description of the class/method.\n+\n+Examples:\n+\n+```php\n+/**\n+ * This handles some foobar stuff.\n+ */\n+class Foobar\n+{\n+    /**\n+     * Constructor.\n+     */\n+    public function __construct()\n+    {\n+        // ...\n+    }\n+\n+    /**\n+     * Process action.\n+     *\n+     * @Template()\n+     */\n+    public function processAction()\n+    {\n+        // ...\n+    }\n+\n+    /**\n+     * Do something cool and nice.\n+     */\n+    protected function doSomething()\n+    {\n+        // ...\n+    }\n+}\n+```\n+\n+## Visibility\n+\n+Visibility *must* be declared on all properties and methods. abstract and final be declared before the visibility and static must be declared after the visibility.\n+\n+Declare public methods first, then protected ones and finally private ones. The exceptions to this rule are the class `constructor` and the `setUp` and `tearDown` methods of PHPUnit tests, which should always be the first methods to increase readability.\n+\n+Examples:\n+\n+```php\n+/**\n+ * This handles some foobar stuff.\n+ */\n+class Foobar\n+{\n+    public $foo;\n+    protected $bar;\n+    private $zim;\n+\n+    /**\n+     * Foobar.\n+     */\n+    public function foobar()\n+    {\n+        // ...\n+    }\n+\n+    /**\n+     * Foobiz.\n+     */\n+    protected function foobiz()\n+    {\n+        // ...\n+    }\n+\n+    /**\n+     * Foobaz.\n+     */\n+    protected function foobaz()\n+    {\n+        // ...\n+    }\n+}\n+```\n+\n+```php\n+abstract class ClassName\n+{\n+    protected static $foobiz;\n+\n+    abstract protected function zim();","path":"php/README.md","position":101,"original_position":101,"commit_id":"be226ed364340ebbd2ca62d5c149472ed7c8cddb","original_commit_id":"be226ed364340ebbd2ca62d5c149472ed7c8cddb","user":{"login":"fixe","id":484559,"avatar_url":"https://avatars.githubusercontent.com/u/484559?v=3","gravatar_id":"","url":"https://api.github.com/users/fixe","html_url":"https://github.com/fixe","followers_url":"https://api.github.com/users/fixe/followers","following_url":"https://api.github.com/users/fixe/following{/other_user}","gists_url":"https://api.github.com/users/fixe/gists{/gist_id}","starred_url":"https://api.github.com/users/fixe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fixe/subscriptions","organizations_url":"https://api.github.com/users/fixe/orgs","repos_url":"https://api.github.com/users/fixe/repos","events_url":"https://api.github.com/users/fixe/events{/privacy}","received_events_url":"https://api.github.com/users/fixe/received_events","type":"User","site_admin":false},"body":"foo","created_at":"2015-03-13T10:53:57Z","updated_at":"2015-03-13T10:53:57Z","html_url":"https://github.com/seegno/coding-standards/pull/1#discussion_r26377185","pull_request_url":"https://api.github.com/repos/seegno/coding-standards/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/seegno/coding-standards/pulls/comments/26377185"},"html":{"href":"https://github.com/seegno/coding-standards/pull/1#discussion_r26377185"},"pull_request":{"href":"https://api.github.com/repos/seegno/coding-standards/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/seegno/coding-standards/pulls/1","id":31021269,"html_url":"https://github.com/seegno/coding-standards/pull/1","diff_url":"https://github.com/seegno/coding-standards/pull/1.diff","patch_url":"https://github.com/seegno/coding-standards/pull/1.patch","issue_url":"https://api.github.com/repos/seegno/coding-standards/issues/1","number":1,"state":"open","locked":false,"title":"Add PHP documentation","user":{"login":"nunorafaelrocha","id":1175149,"avatar_url":"https://avatars.githubusercontent.com/u/1175149?v=3","gravatar_id":"","url":"https://api.github.com/users/nunorafaelrocha","html_url":"https://github.com/nunorafaelrocha","followers_url":"https://api.github.com/users/nunorafaelrocha/followers","following_url":"https://api.github.com/users/nunorafaelrocha/following{/other_user}","gists_url":"https://api.github.com/users/nunorafaelrocha/gists{/gist_id}","starred_url":"https://api.github.com/users/nunorafaelrocha/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nunorafaelrocha/subscriptions","organizations_url":"https://api.github.com/users/nunorafaelrocha/orgs","repos_url":"https://api.github.com/users/nunorafaelrocha/repos","events_url":"https://api.github.com/users/nunorafaelrocha/events{/privacy}","received_events_url":"https://api.github.com/users/nunorafaelrocha/received_events","type":"User","site_admin":false},"body":"R= @fixe,@ruimarinho,@nunofgs,@franciscocardoso ","created_at":"2015-03-12T10:00:09Z","updated_at":"2015-03-13T10:53:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3f1de8de8abcce0fd3711cffc69b4e7be3d1693e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/seegno/coding-standards/pulls/1/commits","review_comments_url":"https://api.github.com/repos/seegno/coding-standards/pulls/1/comments","review_comment_url":"https://api.github.com/repos/seegno/coding-standards/pulls/comments{/number}","comments_url":"https://api.github.com/repos/seegno/coding-standards/issues/1/comments","statuses_url":"https://api.github.com/repos/seegno/coding-standards/statuses/be226ed364340ebbd2ca62d5c149472ed7c8cddb","head":{"label":"seegno:feature/php-documentation","ref":"feature/php-documentation","sha":"be226ed364340ebbd2ca62d5c149472ed7c8cddb","user":{"login":"seegno","id":1326469,"avatar_url":"https://avatars.githubusercontent.com/u/1326469?v=3","gravatar_id":"","url":"https://api.github.com/users/seegno","html_url":"https://github.com/seegno","followers_url":"https://api.github.com/users/seegno/followers","following_url":"https://api.github.com/users/seegno/following{/other_user}","gists_url":"https://api.github.com/users/seegno/gists{/gist_id}","starred_url":"https://api.github.com/users/seegno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seegno/subscriptions","organizations_url":"https://api.github.com/users/seegno/orgs","repos_url":"https://api.github.com/users/seegno/repos","events_url":"https://api.github.com/users/seegno/events{/privacy}","received_events_url":"https://api.github.com/users/seegno/received_events","type":"Organization","site_admin":false},"repo":{"id":31965071,"name":"coding-standards","full_name":"seegno/coding-standards","owner":{"login":"seegno","id":1326469,"avatar_url":"https://avatars.githubusercontent.com/u/1326469?v=3","gravatar_id":"","url":"https://api.github.com/users/seegno","html_url":"https://github.com/seegno","followers_url":"https://api.github.com/users/seegno/followers","following_url":"https://api.github.com/users/seegno/following{/other_user}","gists_url":"https://api.github.com/users/seegno/gists{/gist_id}","starred_url":"https://api.github.com/users/seegno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seegno/subscriptions","organizations_url":"https://api.github.com/users/seegno/orgs","repos_url":"https://api.github.com/users/seegno/repos","events_url":"https://api.github.com/users/seegno/events{/privacy}","received_events_url":"https://api.github.com/users/seegno/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/seegno/coding-standards","description":"","fork":false,"url":"https://api.github.com/repos/seegno/coding-standards","forks_url":"https://api.github.com/repos/seegno/coding-standards/forks","keys_url":"https://api.github.com/repos/seegno/coding-standards/keys{/key_id}","collaborators_url":"https://api.github.com/repos/seegno/coding-standards/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/seegno/coding-standards/teams","hooks_url":"https://api.github.com/repos/seegno/coding-standards/hooks","issue_events_url":"https://api.github.com/repos/seegno/coding-standards/issues/events{/number}","events_url":"https://api.github.com/repos/seegno/coding-standards/events","assignees_url":"https://api.github.com/repos/seegno/coding-standards/assignees{/user}","branches_url":"https://api.github.com/repos/seegno/coding-standards/branches{/branch}","tags_url":"https://api.github.com/repos/seegno/coding-standards/tags","blobs_url":"https://api.github.com/repos/seegno/coding-standards/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/seegno/coding-standards/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/seegno/coding-standards/git/refs{/sha}","trees_url":"https://api.github.com/repos/seegno/coding-standards/git/trees{/sha}","statuses_url":"https://api.github.com/repos/seegno/coding-standards/statuses/{sha}","languages_url":"https://api.github.com/repos/seegno/coding-standards/languages","stargazers_url":"https://api.github.com/repos/seegno/coding-standards/stargazers","contributors_url":"https://api.github.com/repos/seegno/coding-standards/contributors","subscribers_url":"https://api.github.com/repos/seegno/coding-standards/subscribers","subscription_url":"https://api.github.com/repos/seegno/coding-standards/subscription","commits_url":"https://api.github.com/repos/seegno/coding-standards/commits{/sha}","git_commits_url":"https://api.github.com/repos/seegno/coding-standards/git/commits{/sha}","comments_url":"https://api.github.com/repos/seegno/coding-standards/comments{/number}","issue_comment_url":"https://api.github.com/repos/seegno/coding-standards/issues/comments{/number}","contents_url":"https://api.github.com/repos/seegno/coding-standards/contents/{+path}","compare_url":"https://api.github.com/repos/seegno/coding-standards/compare/{base}...{head}","merges_url":"https://api.github.com/repos/seegno/coding-standards/merges","archive_url":"https://api.github.com/repos/seegno/coding-standards/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/seegno/coding-standards/downloads","issues_url":"https://api.github.com/repos/seegno/coding-standards/issues{/number}","pulls_url":"https://api.github.com/repos/seegno/coding-standards/pulls{/number}","milestones_url":"https://api.github.com/repos/seegno/coding-standards/milestones{/number}","notifications_url":"https://api.github.com/repos/seegno/coding-standards/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/seegno/coding-standards/labels{/name}","releases_url":"https://api.github.com/repos/seegno/coding-standards/releases{/id}","created_at":"2015-03-10T15:25:57Z","updated_at":"2015-03-10T15:25:57Z","pushed_at":"2015-03-13T09:48:01Z","git_url":"git://github.com/seegno/coding-standards.git","ssh_url":"git@github.com:seegno/coding-standards.git","clone_url":"https://github.com/seegno/coding-standards.git","svn_url":"https://github.com/seegno/coding-standards","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"seegno:master","ref":"master","sha":"d20b4a28cffa8ad5ae15ae17f27ed8e52da66694","user":{"login":"seegno","id":1326469,"avatar_url":"https://avatars.githubusercontent.com/u/1326469?v=3","gravatar_id":"","url":"https://api.github.com/users/seegno","html_url":"https://github.com/seegno","followers_url":"https://api.github.com/users/seegno/followers","following_url":"https://api.github.com/users/seegno/following{/other_user}","gists_url":"https://api.github.com/users/seegno/gists{/gist_id}","starred_url":"https://api.github.com/users/seegno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seegno/subscriptions","organizations_url":"https://api.github.com/users/seegno/orgs","repos_url":"https://api.github.com/users/seegno/repos","events_url":"https://api.github.com/users/seegno/events{/privacy}","received_events_url":"https://api.github.com/users/seegno/received_events","type":"Organization","site_admin":false},"repo":{"id":31965071,"name":"coding-standards","full_name":"seegno/coding-standards","owner":{"login":"seegno","id":1326469,"avatar_url":"https://avatars.githubusercontent.com/u/1326469?v=3","gravatar_id":"","url":"https://api.github.com/users/seegno","html_url":"https://github.com/seegno","followers_url":"https://api.github.com/users/seegno/followers","following_url":"https://api.github.com/users/seegno/following{/other_user}","gists_url":"https://api.github.com/users/seegno/gists{/gist_id}","starred_url":"https://api.github.com/users/seegno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seegno/subscriptions","organizations_url":"https://api.github.com/users/seegno/orgs","repos_url":"https://api.github.com/users/seegno/repos","events_url":"https://api.github.com/users/seegno/events{/privacy}","received_events_url":"https://api.github.com/users/seegno/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/seegno/coding-standards","description":"","fork":false,"url":"https://api.github.com/repos/seegno/coding-standards","forks_url":"https://api.github.com/repos/seegno/coding-standards/forks","keys_url":"https://api.github.com/repos/seegno/coding-standards/keys{/key_id}","collaborators_url":"https://api.github.com/repos/seegno/coding-standards/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/seegno/coding-standards/teams","hooks_url":"https://api.github.com/repos/seegno/coding-standards/hooks","issue_events_url":"https://api.github.com/repos/seegno/coding-standards/issues/events{/number}","events_url":"https://api.github.com/repos/seegno/coding-standards/events","assignees_url":"https://api.github.com/repos/seegno/coding-standards/assignees{/user}","branches_url":"https://api.github.com/repos/seegno/coding-standards/branches{/branch}","tags_url":"https://api.github.com/repos/seegno/coding-standards/tags","blobs_url":"https://api.github.com/repos/seegno/coding-standards/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/seegno/coding-standards/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/seegno/coding-standards/git/refs{/sha}","trees_url":"https://api.github.com/repos/seegno/coding-standards/git/trees{/sha}","statuses_url":"https://api.github.com/repos/seegno/coding-standards/statuses/{sha}","languages_url":"https://api.github.com/repos/seegno/coding-standards/languages","stargazers_url":"https://api.github.com/repos/seegno/coding-standards/stargazers","contributors_url":"https://api.github.com/repos/seegno/coding-standards/contributors","subscribers_url":"https://api.github.com/repos/seegno/coding-standards/subscribers","subscription_url":"https://api.github.com/repos/seegno/coding-standards/subscription","commits_url":"https://api.github.com/repos/seegno/coding-standards/commits{/sha}","git_commits_url":"https://api.github.com/repos/seegno/coding-standards/git/commits{/sha}","comments_url":"https://api.github.com/repos/seegno/coding-standards/comments{/number}","issue_comment_url":"https://api.github.com/repos/seegno/coding-standards/issues/comments{/number}","contents_url":"https://api.github.com/repos/seegno/coding-standards/contents/{+path}","compare_url":"https://api.github.com/repos/seegno/coding-standards/compare/{base}...{head}","merges_url":"https://api.github.com/repos/seegno/coding-standards/merges","archive_url":"https://api.github.com/repos/seegno/coding-standards/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/seegno/coding-standards/downloads","issues_url":"https://api.github.com/repos/seegno/coding-standards/issues{/number}","pulls_url":"https://api.github.com/repos/seegno/coding-standards/pulls{/number}","milestones_url":"https://api.github.com/repos/seegno/coding-standards/milestones{/number}","notifications_url":"https://api.github.com/repos/seegno/coding-standards/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/seegno/coding-standards/labels{/name}","releases_url":"https://api.github.com/repos/seegno/coding-standards/releases{/id}","created_at":"2015-03-10T15:25:57Z","updated_at":"2015-03-10T15:25:57Z","pushed_at":"2015-03-13T09:48:01Z","git_url":"git://github.com/seegno/coding-standards.git","ssh_url":"git@github.com:seegno/coding-standards.git","clone_url":"https://github.com/seegno/coding-standards.git","svn_url":"https://github.com/seegno/coding-standards","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/seegno/coding-standards/pulls/1"},"html":{"href":"https://github.com/seegno/coding-standards/pull/1"},"issue":{"href":"https://api.github.com/repos/seegno/coding-standards/issues/1"},"comments":{"href":"https://api.github.com/repos/seegno/coding-standards/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/seegno/coding-standards/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/seegno/coding-standards/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/seegno/coding-standards/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/seegno/coding-standards/statuses/be226ed364340ebbd2ca62d5c149472ed7c8cddb"}}}}