{"action":"created","comment":{"url":"https://api.github.com/repos/talk-to/swagger/pulls/comments/92253506","pull_request_review_id":12765666,"id":92253506,"diff_hunk":"@@ -655,6 +684,55 @@ public Reader getTemplate(String name) {\n         return files;\n     }\n \n+    private void createEventHandler(List<String> allEvents) throws IOException {\n+        for (String templateName : config.eventTemplateFiles().keySet()) {\n+            String suffix = config.eventTemplateFiles().get(templateName);\n+            String filename = config.modelFileFolder() + File.separator + config.getEventHandlerFileName() + suffix;\n+            processTemplateToFile(processEvents(allEvents), templateName, filename);\n+        }\n+    }\n+\n+    private void createEventHandlerClient(List<String> allEvents) throws IOException {\n+        for (String templateName : config.eventsClientTemplateFiles().keySet()) {\n+            String suffix = config.eventsClientTemplateFiles().get(templateName);\n+            String filename = config.modelFileFolder() + File.separator + config.getEventHandlerClientFileName() + suffix;\n+            Map<String, Object> templateData = processEvents(allEvents);\n+            config.addAdditionalPropertiesForEventHandlerClient(templateData);\n+            processTemplateToFile(templateData, templateName, filename);\n+        }\n+    }\n+\n+    private Map<String, Object> processEvents(List<String> events) {","path":"modules/swagger-codegen/src/main/java/io/swagger/codegen/DefaultGenerator.java","position":76,"original_position":94,"commit_id":"840d8e52ce4abb69120a01b05721c4143cb70997","original_commit_id":"96092e1de85db21a0cd8700790483d6fc0556290","user":{"login":"rishabhja","id":21194759,"avatar_url":"https://avatars.githubusercontent.com/u/21194759?v=3","gravatar_id":"","url":"https://api.github.com/users/rishabhja","html_url":"https://github.com/rishabhja","followers_url":"https://api.github.com/users/rishabhja/followers","following_url":"https://api.github.com/users/rishabhja/following{/other_user}","gists_url":"https://api.github.com/users/rishabhja/gists{/gist_id}","starred_url":"https://api.github.com/users/rishabhja/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rishabhja/subscriptions","organizations_url":"https://api.github.com/users/rishabhja/orgs","repos_url":"https://api.github.com/users/rishabhja/repos","events_url":"https://api.github.com/users/rishabhja/events{/privacy}","received_events_url":"https://api.github.com/users/rishabhja/received_events","type":"User","site_admin":false},"body":"done","created_at":"2016-12-13T20:00:10Z","updated_at":"2016-12-13T20:00:10Z","html_url":"https://github.com/talk-to/swagger/pull/9#discussion_r92253506","pull_request_url":"https://api.github.com/repos/talk-to/swagger/pulls/9","_links":{"self":{"href":"https://api.github.com/repos/talk-to/swagger/pulls/comments/92253506"},"html":{"href":"https://github.com/talk-to/swagger/pull/9#discussion_r92253506"},"pull_request":{"href":"https://api.github.com/repos/talk-to/swagger/pulls/9"}}},"pull_request":{"url":"https://api.github.com/repos/talk-to/swagger/pulls/9","id":96919263,"html_url":"https://github.com/talk-to/swagger/pull/9","diff_url":"https://github.com/talk-to/swagger/pull/9.diff","patch_url":"https://github.com/talk-to/swagger/pull/9.patch","issue_url":"https://api.github.com/repos/talk-to/swagger/issues/9","number":9,"state":"open","locked":false,"title":"Add events","user":{"login":"rishabhja","id":21194759,"avatar_url":"https://avatars.githubusercontent.com/u/21194759?v=3","gravatar_id":"","url":"https://api.github.com/users/rishabhja","html_url":"https://github.com/rishabhja","followers_url":"https://api.github.com/users/rishabhja/followers","following_url":"https://api.github.com/users/rishabhja/following{/other_user}","gists_url":"https://api.github.com/users/rishabhja/gists{/gist_id}","starred_url":"https://api.github.com/users/rishabhja/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rishabhja/subscriptions","organizations_url":"https://api.github.com/users/rishabhja/orgs","repos_url":"https://api.github.com/users/rishabhja/repos","events_url":"https://api.github.com/users/rishabhja/events{/privacy}","received_events_url":"https://api.github.com/users/rishabhja/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-12-07T13:02:01Z","updated_at":"2016-12-13T20:00:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ed54f7c77e8aa3bb90a3ce6086dc85e7a30306c7","assignee":{"login":"ajitd","id":736119,"avatar_url":"https://avatars.githubusercontent.com/u/736119?v=3","gravatar_id":"","url":"https://api.github.com/users/ajitd","html_url":"https://github.com/ajitd","followers_url":"https://api.github.com/users/ajitd/followers","following_url":"https://api.github.com/users/ajitd/following{/other_user}","gists_url":"https://api.github.com/users/ajitd/gists{/gist_id}","starred_url":"https://api.github.com/users/ajitd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ajitd/subscriptions","organizations_url":"https://api.github.com/users/ajitd/orgs","repos_url":"https://api.github.com/users/ajitd/repos","events_url":"https://api.github.com/users/ajitd/events{/privacy}","received_events_url":"https://api.github.com/users/ajitd/received_events","type":"User","site_admin":false},"assignees":[{"login":"ajitd","id":736119,"avatar_url":"https://avatars.githubusercontent.com/u/736119?v=3","gravatar_id":"","url":"https://api.github.com/users/ajitd","html_url":"https://github.com/ajitd","followers_url":"https://api.github.com/users/ajitd/followers","following_url":"https://api.github.com/users/ajitd/following{/other_user}","gists_url":"https://api.github.com/users/ajitd/gists{/gist_id}","starred_url":"https://api.github.com/users/ajitd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ajitd/subscriptions","organizations_url":"https://api.github.com/users/ajitd/orgs","repos_url":"https://api.github.com/users/ajitd/repos","events_url":"https://api.github.com/users/ajitd/events{/privacy}","received_events_url":"https://api.github.com/users/ajitd/received_events","type":"User","site_admin":false},{"login":"prateeksultania","id":4730899,"avatar_url":"https://avatars.githubusercontent.com/u/4730899?v=3","gravatar_id":"","url":"https://api.github.com/users/prateeksultania","html_url":"https://github.com/prateeksultania","followers_url":"https://api.github.com/users/prateeksultania/followers","following_url":"https://api.github.com/users/prateeksultania/following{/other_user}","gists_url":"https://api.github.com/users/prateeksultania/gists{/gist_id}","starred_url":"https://api.github.com/users/prateeksultania/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/prateeksultania/subscriptions","organizations_url":"https://api.github.com/users/prateeksultania/orgs","repos_url":"https://api.github.com/users/prateeksultania/repos","events_url":"https://api.github.com/users/prateeksultania/events{/privacy}","received_events_url":"https://api.github.com/users/prateeksultania/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/talk-to/swagger/pulls/9/commits","review_comments_url":"https://api.github.com/repos/talk-to/swagger/pulls/9/comments","review_comment_url":"https://api.github.com/repos/talk-to/swagger/pulls/comments{/number}","comments_url":"https://api.github.com/repos/talk-to/swagger/issues/9/comments","statuses_url":"https://api.github.com/repos/talk-to/swagger/statuses/840d8e52ce4abb69120a01b05721c4143cb70997","head":{"label":"talk-to:add_events","ref":"add_events","sha":"840d8e52ce4abb69120a01b05721c4143cb70997","user":{"login":"talk-to","id":5801463,"avatar_url":"https://avatars.githubusercontent.com/u/5801463?v=3","gravatar_id":"","url":"https://api.github.com/users/talk-to","html_url":"https://github.com/talk-to","followers_url":"https://api.github.com/users/talk-to/followers","following_url":"https://api.github.com/users/talk-to/following{/other_user}","gists_url":"https://api.github.com/users/talk-to/gists{/gist_id}","starred_url":"https://api.github.com/users/talk-to/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/talk-to/subscriptions","organizations_url":"https://api.github.com/users/talk-to/orgs","repos_url":"https://api.github.com/users/talk-to/repos","events_url":"https://api.github.com/users/talk-to/events{/privacy}","received_events_url":"https://api.github.com/users/talk-to/received_events","type":"Organization","site_admin":false},"repo":{"id":72837697,"name":"swagger","full_name":"talk-to/swagger","owner":{"login":"talk-to","id":5801463,"avatar_url":"https://avatars.githubusercontent.com/u/5801463?v=3","gravatar_id":"","url":"https://api.github.com/users/talk-to","html_url":"https://github.com/talk-to","followers_url":"https://api.github.com/users/talk-to/followers","following_url":"https://api.github.com/users/talk-to/following{/other_user}","gists_url":"https://api.github.com/users/talk-to/gists{/gist_id}","starred_url":"https://api.github.com/users/talk-to/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/talk-to/subscriptions","organizations_url":"https://api.github.com/users/talk-to/orgs","repos_url":"https://api.github.com/users/talk-to/repos","events_url":"https://api.github.com/users/talk-to/events{/privacy}","received_events_url":"https://api.github.com/users/talk-to/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/talk-to/swagger","description":"Documentation for FlockOS with swagger","fork":true,"url":"https://api.github.com/repos/talk-to/swagger","forks_url":"https://api.github.com/repos/talk-to/swagger/forks","keys_url":"https://api.github.com/repos/talk-to/swagger/keys{/key_id}","collaborators_url":"https://api.github.com/repos/talk-to/swagger/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/talk-to/swagger/teams","hooks_url":"https://api.github.com/repos/talk-to/swagger/hooks","issue_events_url":"https://api.github.com/repos/talk-to/swagger/issues/events{/number}","events_url":"https://api.github.com/repos/talk-to/swagger/events","assignees_url":"https://api.github.com/repos/talk-to/swagger/assignees{/user}","branches_url":"https://api.github.com/repos/talk-to/swagger/branches{/branch}","tags_url":"https://api.github.com/repos/talk-to/swagger/tags","blobs_url":"https://api.github.com/repos/talk-to/swagger/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/talk-to/swagger/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/talk-to/swagger/git/refs{/sha}","trees_url":"https://api.github.com/repos/talk-to/swagger/git/trees{/sha}","statuses_url":"https://api.github.com/repos/talk-to/swagger/statuses/{sha}","languages_url":"https://api.github.com/repos/talk-to/swagger/languages","stargazers_url":"https://api.github.com/repos/talk-to/swagger/stargazers","contributors_url":"https://api.github.com/repos/talk-to/swagger/contributors","subscribers_url":"https://api.github.com/repos/talk-to/swagger/subscribers","subscription_url":"https://api.github.com/repos/talk-to/swagger/subscription","commits_url":"https://api.github.com/repos/talk-to/swagger/commits{/sha}","git_commits_url":"https://api.github.com/repos/talk-to/swagger/git/commits{/sha}","comments_url":"https://api.github.com/repos/talk-to/swagger/comments{/number}","issue_comment_url":"https://api.github.com/repos/talk-to/swagger/issues/comments{/number}","contents_url":"https://api.github.com/repos/talk-to/swagger/contents/{+path}","compare_url":"https://api.github.com/repos/talk-to/swagger/compare/{base}...{head}","merges_url":"https://api.github.com/repos/talk-to/swagger/merges","archive_url":"https://api.github.com/repos/talk-to/swagger/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/talk-to/swagger/downloads","issues_url":"https://api.github.com/repos/talk-to/swagger/issues{/number}","pulls_url":"https://api.github.com/repos/talk-to/swagger/pulls{/number}","milestones_url":"https://api.github.com/repos/talk-to/swagger/milestones{/number}","notifications_url":"https://api.github.com/repos/talk-to/swagger/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/talk-to/swagger/labels{/name}","releases_url":"https://api.github.com/repos/talk-to/swagger/releases{/id}","deployments_url":"https://api.github.com/repos/talk-to/swagger/deployments","created_at":"2016-11-04T10:28:21Z","updated_at":"2016-11-04T10:29:50Z","pushed_at":"2016-12-13T12:27:28Z","git_url":"git://github.com/talk-to/swagger.git","ssh_url":"git@github.com:talk-to/swagger.git","clone_url":"https://github.com/talk-to/swagger.git","svn_url":"https://github.com/talk-to/swagger","homepage":null,"size":9325,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"talk-to:master","ref":"master","sha":"4ca4ef84c839939ab83c426273a5ec8d12765fdb","user":{"login":"talk-to","id":5801463,"avatar_url":"https://avatars.githubusercontent.com/u/5801463?v=3","gravatar_id":"","url":"https://api.github.com/users/talk-to","html_url":"https://github.com/talk-to","followers_url":"https://api.github.com/users/talk-to/followers","following_url":"https://api.github.com/users/talk-to/following{/other_user}","gists_url":"https://api.github.com/users/talk-to/gists{/gist_id}","starred_url":"https://api.github.com/users/talk-to/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/talk-to/subscriptions","organizations_url":"https://api.github.com/users/talk-to/orgs","repos_url":"https://api.github.com/users/talk-to/repos","events_url":"https://api.github.com/users/talk-to/events{/privacy}","received_events_url":"https://api.github.com/users/talk-to/received_events","type":"Organization","site_admin":false},"repo":{"id":72837697,"name":"swagger","full_name":"talk-to/swagger","owner":{"login":"talk-to","id":5801463,"avatar_url":"https://avatars.githubusercontent.com/u/5801463?v=3","gravatar_id":"","url":"https://api.github.com/users/talk-to","html_url":"https://github.com/talk-to","followers_url":"https://api.github.com/users/talk-to/followers","following_url":"https://api.github.com/users/talk-to/following{/other_user}","gists_url":"https://api.github.com/users/talk-to/gists{/gist_id}","starred_url":"https://api.github.com/users/talk-to/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/talk-to/subscriptions","organizations_url":"https://api.github.com/users/talk-to/orgs","repos_url":"https://api.github.com/users/talk-to/repos","events_url":"https://api.github.com/users/talk-to/events{/privacy}","received_events_url":"https://api.github.com/users/talk-to/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/talk-to/swagger","description":"Documentation for FlockOS with swagger","fork":true,"url":"https://api.github.com/repos/talk-to/swagger","forks_url":"https://api.github.com/repos/talk-to/swagger/forks","keys_url":"https://api.github.com/repos/talk-to/swagger/keys{/key_id}","collaborators_url":"https://api.github.com/repos/talk-to/swagger/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/talk-to/swagger/teams","hooks_url":"https://api.github.com/repos/talk-to/swagger/hooks","issue_events_url":"https://api.github.com/repos/talk-to/swagger/issues/events{/number}","events_url":"https://api.github.com/repos/talk-to/swagger/events","assignees_url":"https://api.github.com/repos/talk-to/swagger/assignees{/user}","branches_url":"https://api.github.com/repos/talk-to/swagger/branches{/branch}","tags_url":"https://api.github.com/repos/talk-to/swagger/tags","blobs_url":"https://api.github.com/repos/talk-to/swagger/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/talk-to/swagger/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/talk-to/swagger/git/refs{/sha}","trees_url":"https://api.github.com/repos/talk-to/swagger/git/trees{/sha}","statuses_url":"https://api.github.com/repos/talk-to/swagger/statuses/{sha}","languages_url":"https://api.github.com/repos/talk-to/swagger/languages","stargazers_url":"https://api.github.com/repos/talk-to/swagger/stargazers","contributors_url":"https://api.github.com/repos/talk-to/swagger/contributors","subscribers_url":"https://api.github.com/repos/talk-to/swagger/subscribers","subscription_url":"https://api.github.com/repos/talk-to/swagger/subscription","commits_url":"https://api.github.com/repos/talk-to/swagger/commits{/sha}","git_commits_url":"https://api.github.com/repos/talk-to/swagger/git/commits{/sha}","comments_url":"https://api.github.com/repos/talk-to/swagger/comments{/number}","issue_comment_url":"https://api.github.com/repos/talk-to/swagger/issues/comments{/number}","contents_url":"https://api.github.com/repos/talk-to/swagger/contents/{+path}","compare_url":"https://api.github.com/repos/talk-to/swagger/compare/{base}...{head}","merges_url":"https://api.github.com/repos/talk-to/swagger/merges","archive_url":"https://api.github.com/repos/talk-to/swagger/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/talk-to/swagger/downloads","issues_url":"https://api.github.com/repos/talk-to/swagger/issues{/number}","pulls_url":"https://api.github.com/repos/talk-to/swagger/pulls{/number}","milestones_url":"https://api.github.com/repos/talk-to/swagger/milestones{/number}","notifications_url":"https://api.github.com/repos/talk-to/swagger/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/talk-to/swagger/labels{/name}","releases_url":"https://api.github.com/repos/talk-to/swagger/releases{/id}","deployments_url":"https://api.github.com/repos/talk-to/swagger/deployments","created_at":"2016-11-04T10:28:21Z","updated_at":"2016-11-04T10:29:50Z","pushed_at":"2016-12-13T12:27:28Z","git_url":"git://github.com/talk-to/swagger.git","ssh_url":"git@github.com:talk-to/swagger.git","clone_url":"https://github.com/talk-to/swagger.git","svn_url":"https://github.com/talk-to/swagger","homepage":null,"size":9325,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/talk-to/swagger/pulls/9"},"html":{"href":"https://github.com/talk-to/swagger/pull/9"},"issue":{"href":"https://api.github.com/repos/talk-to/swagger/issues/9"},"comments":{"href":"https://api.github.com/repos/talk-to/swagger/issues/9/comments"},"review_comments":{"href":"https://api.github.com/repos/talk-to/swagger/pulls/9/comments"},"review_comment":{"href":"https://api.github.com/repos/talk-to/swagger/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/talk-to/swagger/pulls/9/commits"},"statuses":{"href":"https://api.github.com/repos/talk-to/swagger/statuses/840d8e52ce4abb69120a01b05721c4143cb70997"}}}}
{"actor":{"display_login":"rishabhja"}}