{"action":"created","comment":{"url":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/comments/175291498","pull_request_review_id":104799561,"id":175291498,"diff_hunk":"@@ -0,0 +1,72 @@\n+package ru.spbau.mit.trie;\n+\n+public class Node {\n+\n+    public Node() {\n+        next = new Node[52];\n+        isTerminal = false;\n+        numberWordsAfter = 0;\n+    }\n+\n+    public int getIndex(char letter) {\n+        if (letter >= 'a' && letter <= 'z') {\n+            return letter - 'a';\n+        } else if (letter >= 'A' && letter <= 'Z') {\n+            return letter - 'A';\n+        }\n+        return -1;\n+    }\n+\n+    public int getNumberWordsAfter() {\n+        return numberWordsAfter;\n+    }\n+\n+    final Node nodeByChar(final char letter) {\n+        final int indexSearchedNode = getIndex(letter);\n+        return next[indexSearchedNode];\n+    }\n+\n+    public Node getNextNeededNode(char letter) {\n+        return next[getIndex(letter)];\n+    }\n+\n+    public boolean isTerminal() {\n+        return isTerminal;\n+    }\n+\n+    public void addNextNewLetter(char letter) {\n+        next[getIndex(letter)] = new Node();\n+        return;\n+    }\n+\n+    public void increaseNumberWordsAfter() {\n+        numberWordsAfter++;\n+        return;\n+    }\n+\n+    public void decreaseNumberWordsAfter() {\n+        numberWordsAfter--;\n+        return;\n+    }\n+\n+    public void setTerminal() {\n+        isTerminal = true;\n+    }\n+\n+    public void unsetTerminal() {\n+        isTerminal = false;\n+    }\n+\n+    public boolean checkWasteLetters() {\n+        if (numberWordsAfter == 0) {\n+            next = new Node[52];\n+            return true;\n+        }\n+\n+        return false;\n+    }\n+\n+    private int numberWordsAfter;\n+    private Node[] next;\n+    private boolean isTerminal;","path":"src/main/java/ru/spbau/mit/trie/Node.java","position":71,"original_position":71,"commit_id":"2a9969b6b56763615f6a8ca30c691767df8aba16","original_commit_id":"2a9969b6b56763615f6a8ca30c691767df8aba16","user":{"login":"sproshev","id":4990763,"avatar_url":"https://avatars3.githubusercontent.com/u/4990763?v=4","gravatar_id":"","url":"https://api.github.com/users/sproshev","html_url":"https://github.com/sproshev","followers_url":"https://api.github.com/users/sproshev/followers","following_url":"https://api.github.com/users/sproshev/following{/other_user}","gists_url":"https://api.github.com/users/sproshev/gists{/gist_id}","starred_url":"https://api.github.com/users/sproshev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sproshev/subscriptions","organizations_url":"https://api.github.com/users/sproshev/orgs","repos_url":"https://api.github.com/users/sproshev/repos","events_url":"https://api.github.com/users/sproshev/events{/privacy}","received_events_url":"https://api.github.com/users/sproshev/received_events","type":"User","site_admin":false},"body":"поля в джаве обычно в начале описываются\r\n\r\nnext может быть final","created_at":"2018-03-18T14:43:47Z","updated_at":"2018-03-18T14:57:11Z","html_url":"https://github.com/natalymr/spbau_java_hw/pull/1#discussion_r175291498","pull_request_url":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/1","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/comments/175291498"},"html":{"href":"https://github.com/natalymr/spbau_java_hw/pull/1#discussion_r175291498"},"pull_request":{"href":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/1","id":175424427,"html_url":"https://github.com/natalymr/spbau_java_hw/pull/1","diff_url":"https://github.com/natalymr/spbau_java_hw/pull/1.diff","patch_url":"https://github.com/natalymr/spbau_java_hw/pull/1.patch","issue_url":"https://api.github.com/repos/natalymr/spbau_java_hw/issues/1","number":1,"state":"open","locked":false,"title":"Java05. ДЗ 01 Мурычева Наталья","user":{"login":"natalymr","id":31903015,"avatar_url":"https://avatars0.githubusercontent.com/u/31903015?v=4","gravatar_id":"","url":"https://api.github.com/users/natalymr","html_url":"https://github.com/natalymr","followers_url":"https://api.github.com/users/natalymr/followers","following_url":"https://api.github.com/users/natalymr/following{/other_user}","gists_url":"https://api.github.com/users/natalymr/gists{/gist_id}","starred_url":"https://api.github.com/users/natalymr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/natalymr/subscriptions","organizations_url":"https://api.github.com/users/natalymr/orgs","repos_url":"https://api.github.com/users/natalymr/repos","events_url":"https://api.github.com/users/natalymr/events{/privacy}","received_events_url":"https://api.github.com/users/natalymr/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-03-16T02:14:55Z","updated_at":"2018-03-18T14:57:11Z","closed_at":null,"merged_at":null,"merge_commit_sha":"23507f0e6d3a4bffbd7c59a31739f6197dc87e1d","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/1/commits","review_comments_url":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/1/comments","review_comment_url":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/comments{/number}","comments_url":"https://api.github.com/repos/natalymr/spbau_java_hw/issues/1/comments","statuses_url":"https://api.github.com/repos/natalymr/spbau_java_hw/statuses/2a9969b6b56763615f6a8ca30c691767df8aba16","head":{"label":"natalymr:home","ref":"home","sha":"2a9969b6b56763615f6a8ca30c691767df8aba16","user":{"login":"natalymr","id":31903015,"avatar_url":"https://avatars0.githubusercontent.com/u/31903015?v=4","gravatar_id":"","url":"https://api.github.com/users/natalymr","html_url":"https://github.com/natalymr","followers_url":"https://api.github.com/users/natalymr/followers","following_url":"https://api.github.com/users/natalymr/following{/other_user}","gists_url":"https://api.github.com/users/natalymr/gists{/gist_id}","starred_url":"https://api.github.com/users/natalymr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/natalymr/subscriptions","organizations_url":"https://api.github.com/users/natalymr/orgs","repos_url":"https://api.github.com/users/natalymr/repos","events_url":"https://api.github.com/users/natalymr/events{/privacy}","received_events_url":"https://api.github.com/users/natalymr/received_events","type":"User","site_admin":false},"repo":{"id":125450938,"name":"spbau_java_hw","full_name":"natalymr/spbau_java_hw","owner":{"login":"natalymr","id":31903015,"avatar_url":"https://avatars0.githubusercontent.com/u/31903015?v=4","gravatar_id":"","url":"https://api.github.com/users/natalymr","html_url":"https://github.com/natalymr","followers_url":"https://api.github.com/users/natalymr/followers","following_url":"https://api.github.com/users/natalymr/following{/other_user}","gists_url":"https://api.github.com/users/natalymr/gists{/gist_id}","starred_url":"https://api.github.com/users/natalymr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/natalymr/subscriptions","organizations_url":"https://api.github.com/users/natalymr/orgs","repos_url":"https://api.github.com/users/natalymr/repos","events_url":"https://api.github.com/users/natalymr/events{/privacy}","received_events_url":"https://api.github.com/users/natalymr/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/natalymr/spbau_java_hw","description":null,"fork":false,"url":"https://api.github.com/repos/natalymr/spbau_java_hw","forks_url":"https://api.github.com/repos/natalymr/spbau_java_hw/forks","keys_url":"https://api.github.com/repos/natalymr/spbau_java_hw/keys{/key_id}","collaborators_url":"https://api.github.com/repos/natalymr/spbau_java_hw/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/natalymr/spbau_java_hw/teams","hooks_url":"https://api.github.com/repos/natalymr/spbau_java_hw/hooks","issue_events_url":"https://api.github.com/repos/natalymr/spbau_java_hw/issues/events{/number}","events_url":"https://api.github.com/repos/natalymr/spbau_java_hw/events","assignees_url":"https://api.github.com/repos/natalymr/spbau_java_hw/assignees{/user}","branches_url":"https://api.github.com/repos/natalymr/spbau_java_hw/branches{/branch}","tags_url":"https://api.github.com/repos/natalymr/spbau_java_hw/tags","blobs_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/refs{/sha}","trees_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/trees{/sha}","statuses_url":"https://api.github.com/repos/natalymr/spbau_java_hw/statuses/{sha}","languages_url":"https://api.github.com/repos/natalymr/spbau_java_hw/languages","stargazers_url":"https://api.github.com/repos/natalymr/spbau_java_hw/stargazers","contributors_url":"https://api.github.com/repos/natalymr/spbau_java_hw/contributors","subscribers_url":"https://api.github.com/repos/natalymr/spbau_java_hw/subscribers","subscription_url":"https://api.github.com/repos/natalymr/spbau_java_hw/subscription","commits_url":"https://api.github.com/repos/natalymr/spbau_java_hw/commits{/sha}","git_commits_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/commits{/sha}","comments_url":"https://api.github.com/repos/natalymr/spbau_java_hw/comments{/number}","issue_comment_url":"https://api.github.com/repos/natalymr/spbau_java_hw/issues/comments{/number}","contents_url":"https://api.github.com/repos/natalymr/spbau_java_hw/contents/{+path}","compare_url":"https://api.github.com/repos/natalymr/spbau_java_hw/compare/{base}...{head}","merges_url":"https://api.github.com/repos/natalymr/spbau_java_hw/merges","archive_url":"https://api.github.com/repos/natalymr/spbau_java_hw/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/natalymr/spbau_java_hw/downloads","issues_url":"https://api.github.com/repos/natalymr/spbau_java_hw/issues{/number}","pulls_url":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls{/number}","milestones_url":"https://api.github.com/repos/natalymr/spbau_java_hw/milestones{/number}","notifications_url":"https://api.github.com/repos/natalymr/spbau_java_hw/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/natalymr/spbau_java_hw/labels{/name}","releases_url":"https://api.github.com/repos/natalymr/spbau_java_hw/releases{/id}","deployments_url":"https://api.github.com/repos/natalymr/spbau_java_hw/deployments","created_at":"2018-03-16T02:10:56Z","updated_at":"2018-03-16T02:10:58Z","pushed_at":"2018-03-16T02:14:55Z","git_url":"git://github.com/natalymr/spbau_java_hw.git","ssh_url":"git@github.com:natalymr/spbau_java_hw.git","clone_url":"https://github.com/natalymr/spbau_java_hw.git","svn_url":"https://github.com/natalymr/spbau_java_hw","homepage":null,"size":60,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"natalymr:master","ref":"master","sha":"a0efe6f5f02b194feb5616f619acbe8a8617c181","user":{"login":"natalymr","id":31903015,"avatar_url":"https://avatars0.githubusercontent.com/u/31903015?v=4","gravatar_id":"","url":"https://api.github.com/users/natalymr","html_url":"https://github.com/natalymr","followers_url":"https://api.github.com/users/natalymr/followers","following_url":"https://api.github.com/users/natalymr/following{/other_user}","gists_url":"https://api.github.com/users/natalymr/gists{/gist_id}","starred_url":"https://api.github.com/users/natalymr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/natalymr/subscriptions","organizations_url":"https://api.github.com/users/natalymr/orgs","repos_url":"https://api.github.com/users/natalymr/repos","events_url":"https://api.github.com/users/natalymr/events{/privacy}","received_events_url":"https://api.github.com/users/natalymr/received_events","type":"User","site_admin":false},"repo":{"id":125450938,"name":"spbau_java_hw","full_name":"natalymr/spbau_java_hw","owner":{"login":"natalymr","id":31903015,"avatar_url":"https://avatars0.githubusercontent.com/u/31903015?v=4","gravatar_id":"","url":"https://api.github.com/users/natalymr","html_url":"https://github.com/natalymr","followers_url":"https://api.github.com/users/natalymr/followers","following_url":"https://api.github.com/users/natalymr/following{/other_user}","gists_url":"https://api.github.com/users/natalymr/gists{/gist_id}","starred_url":"https://api.github.com/users/natalymr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/natalymr/subscriptions","organizations_url":"https://api.github.com/users/natalymr/orgs","repos_url":"https://api.github.com/users/natalymr/repos","events_url":"https://api.github.com/users/natalymr/events{/privacy}","received_events_url":"https://api.github.com/users/natalymr/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/natalymr/spbau_java_hw","description":null,"fork":false,"url":"https://api.github.com/repos/natalymr/spbau_java_hw","forks_url":"https://api.github.com/repos/natalymr/spbau_java_hw/forks","keys_url":"https://api.github.com/repos/natalymr/spbau_java_hw/keys{/key_id}","collaborators_url":"https://api.github.com/repos/natalymr/spbau_java_hw/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/natalymr/spbau_java_hw/teams","hooks_url":"https://api.github.com/repos/natalymr/spbau_java_hw/hooks","issue_events_url":"https://api.github.com/repos/natalymr/spbau_java_hw/issues/events{/number}","events_url":"https://api.github.com/repos/natalymr/spbau_java_hw/events","assignees_url":"https://api.github.com/repos/natalymr/spbau_java_hw/assignees{/user}","branches_url":"https://api.github.com/repos/natalymr/spbau_java_hw/branches{/branch}","tags_url":"https://api.github.com/repos/natalymr/spbau_java_hw/tags","blobs_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/refs{/sha}","trees_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/trees{/sha}","statuses_url":"https://api.github.com/repos/natalymr/spbau_java_hw/statuses/{sha}","languages_url":"https://api.github.com/repos/natalymr/spbau_java_hw/languages","stargazers_url":"https://api.github.com/repos/natalymr/spbau_java_hw/stargazers","contributors_url":"https://api.github.com/repos/natalymr/spbau_java_hw/contributors","subscribers_url":"https://api.github.com/repos/natalymr/spbau_java_hw/subscribers","subscription_url":"https://api.github.com/repos/natalymr/spbau_java_hw/subscription","commits_url":"https://api.github.com/repos/natalymr/spbau_java_hw/commits{/sha}","git_commits_url":"https://api.github.com/repos/natalymr/spbau_java_hw/git/commits{/sha}","comments_url":"https://api.github.com/repos/natalymr/spbau_java_hw/comments{/number}","issue_comment_url":"https://api.github.com/repos/natalymr/spbau_java_hw/issues/comments{/number}","contents_url":"https://api.github.com/repos/natalymr/spbau_java_hw/contents/{+path}","compare_url":"https://api.github.com/repos/natalymr/spbau_java_hw/compare/{base}...{head}","merges_url":"https://api.github.com/repos/natalymr/spbau_java_hw/merges","archive_url":"https://api.github.com/repos/natalymr/spbau_java_hw/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/natalymr/spbau_java_hw/downloads","issues_url":"https://api.github.com/repos/natalymr/spbau_java_hw/issues{/number}","pulls_url":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls{/number}","milestones_url":"https://api.github.com/repos/natalymr/spbau_java_hw/milestones{/number}","notifications_url":"https://api.github.com/repos/natalymr/spbau_java_hw/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/natalymr/spbau_java_hw/labels{/name}","releases_url":"https://api.github.com/repos/natalymr/spbau_java_hw/releases{/id}","deployments_url":"https://api.github.com/repos/natalymr/spbau_java_hw/deployments","created_at":"2018-03-16T02:10:56Z","updated_at":"2018-03-16T02:10:58Z","pushed_at":"2018-03-16T02:14:55Z","git_url":"git://github.com/natalymr/spbau_java_hw.git","ssh_url":"git@github.com:natalymr/spbau_java_hw.git","clone_url":"https://github.com/natalymr/spbau_java_hw.git","svn_url":"https://github.com/natalymr/spbau_java_hw","homepage":null,"size":60,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/1"},"html":{"href":"https://github.com/natalymr/spbau_java_hw/pull/1"},"issue":{"href":"https://api.github.com/repos/natalymr/spbau_java_hw/issues/1"},"comments":{"href":"https://api.github.com/repos/natalymr/spbau_java_hw/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/natalymr/spbau_java_hw/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/natalymr/spbau_java_hw/statuses/2a9969b6b56763615f6a8ca30c691767df8aba16"}},"author_association":"OWNER"}}
{"actor":{"display_login":"sproshev"}}