{"action":"created","comment":{"url":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/comments/198916065","pull_request_review_id":132933613,"id":198916065,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDE5ODkxNjA2NQ==","diff_hunk":"@@ -0,0 +1,96 @@\n+package com.example.felipe.criminalintent\n+\n+import android.support.v4.app.Fragment\n+import android.os.Bundle\n+import android.support.v7.widget.LinearLayoutManager\n+import android.support.v7.widget.RecyclerView\n+import android.view.LayoutInflater\n+import android.view.View\n+import android.view.ViewGroup\n+import android.widget.Toast\n+import kotlinx.android.synthetic.main.fragment_crime_list.view.*\n+import kotlinx.android.synthetic.main.list_item_crime.view.*\n+\n+class CrimeListFragment : Fragment() {\n+    override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View {\n+        super.onCreateView(inflater, container, savedInstanceState)\n+        val view = inflater.inflate(R.layout.fragment_crime_list, container, false)\n+        view.recycleViewCrimes.layoutManager = LinearLayoutManager(activity)\n+        val crimeController = CrimeController.SingletonClass.getInstance()\n+        view.recycleViewCrimes.adapter = CrimeAdapter(crimeController.listCrimes())\n+        return view\n+    }\n+\n+    private inner class CrimeHolder(inflater: LayoutInflater, parent: ViewGroup) :\n+            RecyclerView.ViewHolder(inflater.inflate(R.layout.list_item_crime, parent, false)),\n+            View.OnClickListener {\n+        private var crime: Crime? = null\n+\n+        init {\n+            itemView.setOnClickListener(this)\n+        }\n+\n+        fun bind(crime: Crime) {\n+            this.crime = crime\n+            itemView.txtCrimeTitle.text = crime.title\n+            itemView.txtCrimeDate.text = crime.date.toString()\n+        }\n+\n+        override fun onClick(view: View) {\n+            Toast.makeText(activity, \"${crime?.title} clicked!\", Toast.LENGTH_SHORT).show()\n+        }\n+    }\n+\n+    private inner class CrimeHolderPolice(inflater: LayoutInflater, parent: ViewGroup) :\n+            RecyclerView.ViewHolder(inflater.inflate(R.layout.list_item_crime_police, parent, false)),\n+            View.OnClickListener {\n+        private var crime: Crime? = null\n+\n+        init {\n+            itemView.setOnClickListener(this)\n+        }\n+\n+        fun bind(crime: Crime) {\n+            this.crime = crime\n+            itemView.txtCrimeTitle.text = crime.title\n+            itemView.txtCrimeDate.text = crime.date.toString()\n+        }\n+\n+        override fun onClick(view: View) {\n+            Toast.makeText(activity, \"${crime?.title} clicked!\", Toast.LENGTH_SHORT).show()\n+        }\n+    }\n+\n+    private inner class CrimeAdapter(var crimes: List<Crime>) : RecyclerView.Adapter<RecyclerView.ViewHolder>() {\n+        override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): RecyclerView.ViewHolder {\n+            val layoutInflater = LayoutInflater.from(activity)\n+            return when (viewType) {\n+                1 -> CrimeHolderPolice(layoutInflater, parent)\n+                else -> CrimeHolder(layoutInflater, parent)\n+            }\n+","path":"app/src/main/java/com/example/felipe/criminalintent/CrimeListFragment.kt","position":71,"original_position":71,"commit_id":"41935e7f0ca7dbe9b5592ac1f51b0627f43cd9b6","original_commit_id":"41935e7f0ca7dbe9b5592ac1f51b0627f43cd9b6","user":{"login":"matir91","id":8472881,"node_id":"MDQ6VXNlcjg0NzI4ODE=","avatar_url":"https://avatars2.githubusercontent.com/u/8472881?v=4","gravatar_id":"","url":"https://api.github.com/users/matir91","html_url":"https://github.com/matir91","followers_url":"https://api.github.com/users/matir91/followers","following_url":"https://api.github.com/users/matir91/following{/other_user}","gists_url":"https://api.github.com/users/matir91/gists{/gist_id}","starred_url":"https://api.github.com/users/matir91/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matir91/subscriptions","organizations_url":"https://api.github.com/users/matir91/orgs","repos_url":"https://api.github.com/users/matir91/repos","events_url":"https://api.github.com/users/matir91/events{/privacy}","received_events_url":"https://api.github.com/users/matir91/received_events","type":"User","site_admin":false},"body":"rm","created_at":"2018-06-28T17:05:30Z","updated_at":"2018-06-28T17:08:03Z","html_url":"https://github.com/f7deleon/CriminalIntent/pull/3#discussion_r198916065","pull_request_url":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/3","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/comments/198916065"},"html":{"href":"https://github.com/f7deleon/CriminalIntent/pull/3#discussion_r198916065"},"pull_request":{"href":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/3"}}},"pull_request":{"url":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/3","id":198092278,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk4MDkyMjc4","html_url":"https://github.com/f7deleon/CriminalIntent/pull/3","diff_url":"https://github.com/f7deleon/CriminalIntent/pull/3.diff","patch_url":"https://github.com/f7deleon/CriminalIntent/pull/3.patch","issue_url":"https://api.github.com/repos/f7deleon/CriminalIntent/issues/3","number":3,"state":"open","locked":false,"title":"Added crime list and police required items","user":{"login":"f7deleon","id":13909040,"node_id":"MDQ6VXNlcjEzOTA5MDQw","avatar_url":"https://avatars1.githubusercontent.com/u/13909040?v=4","gravatar_id":"","url":"https://api.github.com/users/f7deleon","html_url":"https://github.com/f7deleon","followers_url":"https://api.github.com/users/f7deleon/followers","following_url":"https://api.github.com/users/f7deleon/following{/other_user}","gists_url":"https://api.github.com/users/f7deleon/gists{/gist_id}","starred_url":"https://api.github.com/users/f7deleon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/f7deleon/subscriptions","organizations_url":"https://api.github.com/users/f7deleon/orgs","repos_url":"https://api.github.com/users/f7deleon/repos","events_url":"https://api.github.com/users/f7deleon/events{/privacy}","received_events_url":"https://api.github.com/users/f7deleon/received_events","type":"User","site_admin":false},"body":"Added crime list and police required items\r\n\r\n### Related Trello cards:\r\nhttps://trello.com/c/bHfnm6Jc\r\n\r\n### UI preview:\r\n![ac3oqmt8s1](https://user-images.githubusercontent.com/13909040/42049077-4b842eee-7adb-11e8-943c-06d2c71a8e9d.gif)\r\n\r\n\r\n\r\n\r\n","created_at":"2018-06-28T16:55:25Z","updated_at":"2018-06-28T17:08:03Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d7f2d8e76ad19c18bbbb75a780cfdc9a4ac565e1","assignee":null,"assignees":[],"requested_reviewers":[{"login":"FerrariBruno","id":13987465,"node_id":"MDQ6VXNlcjEzOTg3NDY1","avatar_url":"https://avatars3.githubusercontent.com/u/13987465?v=4","gravatar_id":"","url":"https://api.github.com/users/FerrariBruno","html_url":"https://github.com/FerrariBruno","followers_url":"https://api.github.com/users/FerrariBruno/followers","following_url":"https://api.github.com/users/FerrariBruno/following{/other_user}","gists_url":"https://api.github.com/users/FerrariBruno/gists{/gist_id}","starred_url":"https://api.github.com/users/FerrariBruno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FerrariBruno/subscriptions","organizations_url":"https://api.github.com/users/FerrariBruno/orgs","repos_url":"https://api.github.com/users/FerrariBruno/repos","events_url":"https://api.github.com/users/FerrariBruno/events{/privacy}","received_events_url":"https://api.github.com/users/FerrariBruno/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/3/commits","review_comments_url":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/3/comments","review_comment_url":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/comments{/number}","comments_url":"https://api.github.com/repos/f7deleon/CriminalIntent/issues/3/comments","statuses_url":"https://api.github.com/repos/f7deleon/CriminalIntent/statuses/41935e7f0ca7dbe9b5592ac1f51b0627f43cd9b6","head":{"label":"f7deleon:CrimeCollection","ref":"CrimeCollection","sha":"41935e7f0ca7dbe9b5592ac1f51b0627f43cd9b6","user":{"login":"f7deleon","id":13909040,"node_id":"MDQ6VXNlcjEzOTA5MDQw","avatar_url":"https://avatars1.githubusercontent.com/u/13909040?v=4","gravatar_id":"","url":"https://api.github.com/users/f7deleon","html_url":"https://github.com/f7deleon","followers_url":"https://api.github.com/users/f7deleon/followers","following_url":"https://api.github.com/users/f7deleon/following{/other_user}","gists_url":"https://api.github.com/users/f7deleon/gists{/gist_id}","starred_url":"https://api.github.com/users/f7deleon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/f7deleon/subscriptions","organizations_url":"https://api.github.com/users/f7deleon/orgs","repos_url":"https://api.github.com/users/f7deleon/repos","events_url":"https://api.github.com/users/f7deleon/events{/privacy}","received_events_url":"https://api.github.com/users/f7deleon/received_events","type":"User","site_admin":false},"repo":{"id":138766204,"node_id":"MDEwOlJlcG9zaXRvcnkxMzg3NjYyMDQ=","name":"CriminalIntent","full_name":"f7deleon/CriminalIntent","owner":{"login":"f7deleon","id":13909040,"node_id":"MDQ6VXNlcjEzOTA5MDQw","avatar_url":"https://avatars1.githubusercontent.com/u/13909040?v=4","gravatar_id":"","url":"https://api.github.com/users/f7deleon","html_url":"https://github.com/f7deleon","followers_url":"https://api.github.com/users/f7deleon/followers","following_url":"https://api.github.com/users/f7deleon/following{/other_user}","gists_url":"https://api.github.com/users/f7deleon/gists{/gist_id}","starred_url":"https://api.github.com/users/f7deleon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/f7deleon/subscriptions","organizations_url":"https://api.github.com/users/f7deleon/orgs","repos_url":"https://api.github.com/users/f7deleon/repos","events_url":"https://api.github.com/users/f7deleon/events{/privacy}","received_events_url":"https://api.github.com/users/f7deleon/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/f7deleon/CriminalIntent","description":null,"fork":false,"url":"https://api.github.com/repos/f7deleon/CriminalIntent","forks_url":"https://api.github.com/repos/f7deleon/CriminalIntent/forks","keys_url":"https://api.github.com/repos/f7deleon/CriminalIntent/keys{/key_id}","collaborators_url":"https://api.github.com/repos/f7deleon/CriminalIntent/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/f7deleon/CriminalIntent/teams","hooks_url":"https://api.github.com/repos/f7deleon/CriminalIntent/hooks","issue_events_url":"https://api.github.com/repos/f7deleon/CriminalIntent/issues/events{/number}","events_url":"https://api.github.com/repos/f7deleon/CriminalIntent/events","assignees_url":"https://api.github.com/repos/f7deleon/CriminalIntent/assignees{/user}","branches_url":"https://api.github.com/repos/f7deleon/CriminalIntent/branches{/branch}","tags_url":"https://api.github.com/repos/f7deleon/CriminalIntent/tags","blobs_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/refs{/sha}","trees_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/trees{/sha}","statuses_url":"https://api.github.com/repos/f7deleon/CriminalIntent/statuses/{sha}","languages_url":"https://api.github.com/repos/f7deleon/CriminalIntent/languages","stargazers_url":"https://api.github.com/repos/f7deleon/CriminalIntent/stargazers","contributors_url":"https://api.github.com/repos/f7deleon/CriminalIntent/contributors","subscribers_url":"https://api.github.com/repos/f7deleon/CriminalIntent/subscribers","subscription_url":"https://api.github.com/repos/f7deleon/CriminalIntent/subscription","commits_url":"https://api.github.com/repos/f7deleon/CriminalIntent/commits{/sha}","git_commits_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/commits{/sha}","comments_url":"https://api.github.com/repos/f7deleon/CriminalIntent/comments{/number}","issue_comment_url":"https://api.github.com/repos/f7deleon/CriminalIntent/issues/comments{/number}","contents_url":"https://api.github.com/repos/f7deleon/CriminalIntent/contents/{+path}","compare_url":"https://api.github.com/repos/f7deleon/CriminalIntent/compare/{base}...{head}","merges_url":"https://api.github.com/repos/f7deleon/CriminalIntent/merges","archive_url":"https://api.github.com/repos/f7deleon/CriminalIntent/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/f7deleon/CriminalIntent/downloads","issues_url":"https://api.github.com/repos/f7deleon/CriminalIntent/issues{/number}","pulls_url":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls{/number}","milestones_url":"https://api.github.com/repos/f7deleon/CriminalIntent/milestones{/number}","notifications_url":"https://api.github.com/repos/f7deleon/CriminalIntent/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/f7deleon/CriminalIntent/labels{/name}","releases_url":"https://api.github.com/repos/f7deleon/CriminalIntent/releases{/id}","deployments_url":"https://api.github.com/repos/f7deleon/CriminalIntent/deployments","created_at":"2018-06-26T16:45:01Z","updated_at":"2018-06-27T19:41:36Z","pushed_at":"2018-06-28T16:55:26Z","git_url":"git://github.com/f7deleon/CriminalIntent.git","ssh_url":"git@github.com:f7deleon/CriminalIntent.git","clone_url":"https://github.com/f7deleon/CriminalIntent.git","svn_url":"https://github.com/f7deleon/CriminalIntent","homepage":null,"size":135,"stargazers_count":0,"watchers_count":0,"language":"Kotlin","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":"f7deleon:master","ref":"master","sha":"c83860c998ac9288aa52d49759e5b4ba634d9a27","user":{"login":"f7deleon","id":13909040,"node_id":"MDQ6VXNlcjEzOTA5MDQw","avatar_url":"https://avatars1.githubusercontent.com/u/13909040?v=4","gravatar_id":"","url":"https://api.github.com/users/f7deleon","html_url":"https://github.com/f7deleon","followers_url":"https://api.github.com/users/f7deleon/followers","following_url":"https://api.github.com/users/f7deleon/following{/other_user}","gists_url":"https://api.github.com/users/f7deleon/gists{/gist_id}","starred_url":"https://api.github.com/users/f7deleon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/f7deleon/subscriptions","organizations_url":"https://api.github.com/users/f7deleon/orgs","repos_url":"https://api.github.com/users/f7deleon/repos","events_url":"https://api.github.com/users/f7deleon/events{/privacy}","received_events_url":"https://api.github.com/users/f7deleon/received_events","type":"User","site_admin":false},"repo":{"id":138766204,"node_id":"MDEwOlJlcG9zaXRvcnkxMzg3NjYyMDQ=","name":"CriminalIntent","full_name":"f7deleon/CriminalIntent","owner":{"login":"f7deleon","id":13909040,"node_id":"MDQ6VXNlcjEzOTA5MDQw","avatar_url":"https://avatars1.githubusercontent.com/u/13909040?v=4","gravatar_id":"","url":"https://api.github.com/users/f7deleon","html_url":"https://github.com/f7deleon","followers_url":"https://api.github.com/users/f7deleon/followers","following_url":"https://api.github.com/users/f7deleon/following{/other_user}","gists_url":"https://api.github.com/users/f7deleon/gists{/gist_id}","starred_url":"https://api.github.com/users/f7deleon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/f7deleon/subscriptions","organizations_url":"https://api.github.com/users/f7deleon/orgs","repos_url":"https://api.github.com/users/f7deleon/repos","events_url":"https://api.github.com/users/f7deleon/events{/privacy}","received_events_url":"https://api.github.com/users/f7deleon/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/f7deleon/CriminalIntent","description":null,"fork":false,"url":"https://api.github.com/repos/f7deleon/CriminalIntent","forks_url":"https://api.github.com/repos/f7deleon/CriminalIntent/forks","keys_url":"https://api.github.com/repos/f7deleon/CriminalIntent/keys{/key_id}","collaborators_url":"https://api.github.com/repos/f7deleon/CriminalIntent/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/f7deleon/CriminalIntent/teams","hooks_url":"https://api.github.com/repos/f7deleon/CriminalIntent/hooks","issue_events_url":"https://api.github.com/repos/f7deleon/CriminalIntent/issues/events{/number}","events_url":"https://api.github.com/repos/f7deleon/CriminalIntent/events","assignees_url":"https://api.github.com/repos/f7deleon/CriminalIntent/assignees{/user}","branches_url":"https://api.github.com/repos/f7deleon/CriminalIntent/branches{/branch}","tags_url":"https://api.github.com/repos/f7deleon/CriminalIntent/tags","blobs_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/refs{/sha}","trees_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/trees{/sha}","statuses_url":"https://api.github.com/repos/f7deleon/CriminalIntent/statuses/{sha}","languages_url":"https://api.github.com/repos/f7deleon/CriminalIntent/languages","stargazers_url":"https://api.github.com/repos/f7deleon/CriminalIntent/stargazers","contributors_url":"https://api.github.com/repos/f7deleon/CriminalIntent/contributors","subscribers_url":"https://api.github.com/repos/f7deleon/CriminalIntent/subscribers","subscription_url":"https://api.github.com/repos/f7deleon/CriminalIntent/subscription","commits_url":"https://api.github.com/repos/f7deleon/CriminalIntent/commits{/sha}","git_commits_url":"https://api.github.com/repos/f7deleon/CriminalIntent/git/commits{/sha}","comments_url":"https://api.github.com/repos/f7deleon/CriminalIntent/comments{/number}","issue_comment_url":"https://api.github.com/repos/f7deleon/CriminalIntent/issues/comments{/number}","contents_url":"https://api.github.com/repos/f7deleon/CriminalIntent/contents/{+path}","compare_url":"https://api.github.com/repos/f7deleon/CriminalIntent/compare/{base}...{head}","merges_url":"https://api.github.com/repos/f7deleon/CriminalIntent/merges","archive_url":"https://api.github.com/repos/f7deleon/CriminalIntent/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/f7deleon/CriminalIntent/downloads","issues_url":"https://api.github.com/repos/f7deleon/CriminalIntent/issues{/number}","pulls_url":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls{/number}","milestones_url":"https://api.github.com/repos/f7deleon/CriminalIntent/milestones{/number}","notifications_url":"https://api.github.com/repos/f7deleon/CriminalIntent/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/f7deleon/CriminalIntent/labels{/name}","releases_url":"https://api.github.com/repos/f7deleon/CriminalIntent/releases{/id}","deployments_url":"https://api.github.com/repos/f7deleon/CriminalIntent/deployments","created_at":"2018-06-26T16:45:01Z","updated_at":"2018-06-27T19:41:36Z","pushed_at":"2018-06-28T16:55:26Z","git_url":"git://github.com/f7deleon/CriminalIntent.git","ssh_url":"git@github.com:f7deleon/CriminalIntent.git","clone_url":"https://github.com/f7deleon/CriminalIntent.git","svn_url":"https://github.com/f7deleon/CriminalIntent","homepage":null,"size":135,"stargazers_count":0,"watchers_count":0,"language":"Kotlin","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/f7deleon/CriminalIntent/pulls/3"},"html":{"href":"https://github.com/f7deleon/CriminalIntent/pull/3"},"issue":{"href":"https://api.github.com/repos/f7deleon/CriminalIntent/issues/3"},"comments":{"href":"https://api.github.com/repos/f7deleon/CriminalIntent/issues/3/comments"},"review_comments":{"href":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/3/comments"},"review_comment":{"href":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/f7deleon/CriminalIntent/pulls/3/commits"},"statuses":{"href":"https://api.github.com/repos/f7deleon/CriminalIntent/statuses/41935e7f0ca7dbe9b5592ac1f51b0627f43cd9b6"}},"author_association":"OWNER"}}
{"actor":{"display_login":"matir91"}}