{"action":"created","comment":{"url":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/comments/202474997","pull_request_review_id":137192862,"id":202474997,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwMjQ3NDk5Nw==","diff_hunk":"@@ -0,0 +1,31 @@\n+#ifndef RA_SERVICES_ILEADERBOARD_MANAGER_H\n+#define RA_SERVICES_ILEADERBOARD_MANAGER_H\n+#pragma once\n+\n+#include \"RA_Leaderboard.h\"\n+\n+namespace ra {\n+namespace services {\n+\n+class ILeaderboardManager\n+{\n+public:\n+    virtual void Test() = 0;\n+    virtual void Reset() = 0;\n+\n+    virtual void ActivateLeaderboard(const RA_Leaderboard& lb) const = 0;\n+    virtual void DeactivateLeaderboard(const RA_Leaderboard& lb) const = 0;\n+    virtual void SubmitLeaderboardEntry(const RA_Leaderboard& lb, unsigned int nValue) const = 0;\n+\n+    virtual void AddLeaderboard(const RA_Leaderboard& lb) = 0;\n+    virtual size_t Count() const = 0;\n+    virtual const RA_Leaderboard& GetLB(size_t index) const = 0;\n+    virtual RA_Leaderboard* FindLB(LeaderboardID nID) = 0;\n+    const RA_Leaderboard* FindLB(LeaderboardID nID) const { return const_cast<ILeaderboardManager*>(this)->FindLB(nID); }\n+    virtual void Clear() = 0;","path":"src/services/ILeaderboardManager.hh","position":25,"original_position":25,"commit_id":"10cc933ac9548582eea913bd11222337ea27cbcd","original_commit_id":"b22bed05522ec79097c84f13f2dc1bac9902d58c","user":{"login":"SyrianBallaS","id":18649925,"node_id":"MDQ6VXNlcjE4NjQ5OTI1","avatar_url":"https://avatars2.githubusercontent.com/u/18649925?v=4","gravatar_id":"","url":"https://api.github.com/users/SyrianBallaS","html_url":"https://github.com/SyrianBallaS","followers_url":"https://api.github.com/users/SyrianBallaS/followers","following_url":"https://api.github.com/users/SyrianBallaS/following{/other_user}","gists_url":"https://api.github.com/users/SyrianBallaS/gists{/gist_id}","starred_url":"https://api.github.com/users/SyrianBallaS/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SyrianBallaS/subscriptions","organizations_url":"https://api.github.com/users/SyrianBallaS/orgs","repos_url":"https://api.github.com/users/SyrianBallaS/repos","events_url":"https://api.github.com/users/SyrianBallaS/events{/privacy}","received_events_url":"https://api.github.com/users/SyrianBallaS/received_events","type":"User","site_admin":false},"body":"Sweet, yeah I agree that interfaces shouldn't have constraints but I think their implementations should.\r\n\r\nIt's all good, one step at a time.","created_at":"2018-07-13T21:17:18Z","updated_at":"2018-07-13T21:17:18Z","html_url":"https://github.com/RetroAchievements/RAIntegration/pull/66#discussion_r202474997","pull_request_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/66","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/comments/202474997"},"html":{"href":"https://github.com/RetroAchievements/RAIntegration/pull/66#discussion_r202474997"},"pull_request":{"href":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/66"}},"in_reply_to_id":199336304},"pull_request":{"url":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/66","id":198382188,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk4MzgyMTg4","html_url":"https://github.com/RetroAchievements/RAIntegration/pull/66","diff_url":"https://github.com/RetroAchievements/RAIntegration/pull/66.diff","patch_url":"https://github.com/RetroAchievements/RAIntegration/pull/66.patch","issue_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues/66","number":66,"state":"open","locked":false,"title":"Introduce ServiceLocator","user":{"login":"Jamiras","id":32680403,"node_id":"MDQ6VXNlcjMyNjgwNDAz","avatar_url":"https://avatars1.githubusercontent.com/u/32680403?v=4","gravatar_id":"","url":"https://api.github.com/users/Jamiras","html_url":"https://github.com/Jamiras","followers_url":"https://api.github.com/users/Jamiras/followers","following_url":"https://api.github.com/users/Jamiras/following{/other_user}","gists_url":"https://api.github.com/users/Jamiras/gists{/gist_id}","starred_url":"https://api.github.com/users/Jamiras/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jamiras/subscriptions","organizations_url":"https://api.github.com/users/Jamiras/orgs","repos_url":"https://api.github.com/users/Jamiras/repos","events_url":"https://api.github.com/users/Jamiras/events{/privacy}","received_events_url":"https://api.github.com/users/Jamiras/received_events","type":"User","site_admin":false},"body":"This PR illustrates how to use the service locator pattern to replace globals. \r\n\r\nFor this example, I've moved the \"RAPrefs_\" logic into an `IConfiguration` service, using an implementation specific to reading/writing a JSON file.\r\n\r\nI've also replaced the \"g_LeaderboardManager\" singleton with an `ILeaderboardManager` service, which uses DependencyInjection to reference the `IConfiguration` service.\r\n\r\nI don't plan to merge this PR until after 0.73 is released.","created_at":"2018-06-29T17:46:36Z","updated_at":"2018-07-13T21:17:18Z","closed_at":null,"merged_at":null,"merge_commit_sha":"289217824bfdf26e883b78ba68e354c40caeb96f","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":{"url":"https://api.github.com/repos/RetroAchievements/RAIntegration/milestones/2","html_url":"https://github.com/RetroAchievements/RAIntegration/milestone/2","labels_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/milestones/2/labels","id":3491286,"node_id":"MDk6TWlsZXN0b25lMzQ5MTI4Ng==","number":2,"title":"0.74","description":null,"creator":{"login":"Jamiras","id":32680403,"node_id":"MDQ6VXNlcjMyNjgwNDAz","avatar_url":"https://avatars1.githubusercontent.com/u/32680403?v=4","gravatar_id":"","url":"https://api.github.com/users/Jamiras","html_url":"https://github.com/Jamiras","followers_url":"https://api.github.com/users/Jamiras/followers","following_url":"https://api.github.com/users/Jamiras/following{/other_user}","gists_url":"https://api.github.com/users/Jamiras/gists{/gist_id}","starred_url":"https://api.github.com/users/Jamiras/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jamiras/subscriptions","organizations_url":"https://api.github.com/users/Jamiras/orgs","repos_url":"https://api.github.com/users/Jamiras/repos","events_url":"https://api.github.com/users/Jamiras/events{/privacy}","received_events_url":"https://api.github.com/users/Jamiras/received_events","type":"User","site_admin":false},"open_issues":1,"closed_issues":0,"state":"open","created_at":"2018-07-12T12:51:28Z","updated_at":"2018-07-12T12:51:28Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/66/commits","review_comments_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/66/comments","review_comment_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/comments{/number}","comments_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues/66/comments","statuses_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/statuses/10cc933ac9548582eea913bd11222337ea27cbcd","head":{"label":"RetroAchievements:svc_locator","ref":"svc_locator","sha":"10cc933ac9548582eea913bd11222337ea27cbcd","user":{"login":"RetroAchievements","id":5411318,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU0MTEzMTg=","avatar_url":"https://avatars3.githubusercontent.com/u/5411318?v=4","gravatar_id":"","url":"https://api.github.com/users/RetroAchievements","html_url":"https://github.com/RetroAchievements","followers_url":"https://api.github.com/users/RetroAchievements/followers","following_url":"https://api.github.com/users/RetroAchievements/following{/other_user}","gists_url":"https://api.github.com/users/RetroAchievements/gists{/gist_id}","starred_url":"https://api.github.com/users/RetroAchievements/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RetroAchievements/subscriptions","organizations_url":"https://api.github.com/users/RetroAchievements/orgs","repos_url":"https://api.github.com/users/RetroAchievements/repos","events_url":"https://api.github.com/users/RetroAchievements/events{/privacy}","received_events_url":"https://api.github.com/users/RetroAchievements/received_events","type":"Organization","site_admin":false},"repo":{"id":129603848,"node_id":"MDEwOlJlcG9zaXRvcnkxMjk2MDM4NDg=","name":"RAIntegration","full_name":"RetroAchievements/RAIntegration","owner":{"login":"RetroAchievements","id":5411318,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU0MTEzMTg=","avatar_url":"https://avatars3.githubusercontent.com/u/5411318?v=4","gravatar_id":"","url":"https://api.github.com/users/RetroAchievements","html_url":"https://github.com/RetroAchievements","followers_url":"https://api.github.com/users/RetroAchievements/followers","following_url":"https://api.github.com/users/RetroAchievements/following{/other_user}","gists_url":"https://api.github.com/users/RetroAchievements/gists{/gist_id}","starred_url":"https://api.github.com/users/RetroAchievements/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RetroAchievements/subscriptions","organizations_url":"https://api.github.com/users/RetroAchievements/orgs","repos_url":"https://api.github.com/users/RetroAchievements/repos","events_url":"https://api.github.com/users/RetroAchievements/events{/privacy}","received_events_url":"https://api.github.com/users/RetroAchievements/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/RetroAchievements/RAIntegration","description":"The DLL responsible to integrate emulators with RetroAchievements.org","fork":false,"url":"https://api.github.com/repos/RetroAchievements/RAIntegration","forks_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/forks","keys_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/keys{/key_id}","collaborators_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/teams","hooks_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/hooks","issue_events_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues/events{/number}","events_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/events","assignees_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/assignees{/user}","branches_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/branches{/branch}","tags_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/tags","blobs_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/refs{/sha}","trees_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/trees{/sha}","statuses_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/statuses/{sha}","languages_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/languages","stargazers_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/stargazers","contributors_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/contributors","subscribers_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/subscribers","subscription_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/subscription","commits_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/commits{/sha}","git_commits_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/commits{/sha}","comments_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/comments{/number}","issue_comment_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues/comments{/number}","contents_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/contents/{+path}","compare_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/compare/{base}...{head}","merges_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/merges","archive_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/downloads","issues_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues{/number}","pulls_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls{/number}","milestones_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/milestones{/number}","notifications_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/labels{/name}","releases_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/releases{/id}","deployments_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/deployments","created_at":"2018-04-15T11:33:17Z","updated_at":"2018-07-13T21:09:38Z","pushed_at":"2018-07-13T20:59:20Z","git_url":"git://github.com/RetroAchievements/RAIntegration.git","ssh_url":"git@github.com:RetroAchievements/RAIntegration.git","clone_url":"https://github.com/RetroAchievements/RAIntegration.git","svn_url":"https://github.com/RetroAchievements/RAIntegration","homepage":"http://retroachievements.org","size":3060,"stargazers_count":8,"watchers_count":8,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":27,"license":null,"forks":1,"open_issues":27,"watchers":8,"default_branch":"master"}},"base":{"label":"RetroAchievements:master","ref":"master","sha":"e57608977b0cef126d10b2ee27a9a941274090ad","user":{"login":"RetroAchievements","id":5411318,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU0MTEzMTg=","avatar_url":"https://avatars3.githubusercontent.com/u/5411318?v=4","gravatar_id":"","url":"https://api.github.com/users/RetroAchievements","html_url":"https://github.com/RetroAchievements","followers_url":"https://api.github.com/users/RetroAchievements/followers","following_url":"https://api.github.com/users/RetroAchievements/following{/other_user}","gists_url":"https://api.github.com/users/RetroAchievements/gists{/gist_id}","starred_url":"https://api.github.com/users/RetroAchievements/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RetroAchievements/subscriptions","organizations_url":"https://api.github.com/users/RetroAchievements/orgs","repos_url":"https://api.github.com/users/RetroAchievements/repos","events_url":"https://api.github.com/users/RetroAchievements/events{/privacy}","received_events_url":"https://api.github.com/users/RetroAchievements/received_events","type":"Organization","site_admin":false},"repo":{"id":129603848,"node_id":"MDEwOlJlcG9zaXRvcnkxMjk2MDM4NDg=","name":"RAIntegration","full_name":"RetroAchievements/RAIntegration","owner":{"login":"RetroAchievements","id":5411318,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU0MTEzMTg=","avatar_url":"https://avatars3.githubusercontent.com/u/5411318?v=4","gravatar_id":"","url":"https://api.github.com/users/RetroAchievements","html_url":"https://github.com/RetroAchievements","followers_url":"https://api.github.com/users/RetroAchievements/followers","following_url":"https://api.github.com/users/RetroAchievements/following{/other_user}","gists_url":"https://api.github.com/users/RetroAchievements/gists{/gist_id}","starred_url":"https://api.github.com/users/RetroAchievements/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RetroAchievements/subscriptions","organizations_url":"https://api.github.com/users/RetroAchievements/orgs","repos_url":"https://api.github.com/users/RetroAchievements/repos","events_url":"https://api.github.com/users/RetroAchievements/events{/privacy}","received_events_url":"https://api.github.com/users/RetroAchievements/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/RetroAchievements/RAIntegration","description":"The DLL responsible to integrate emulators with RetroAchievements.org","fork":false,"url":"https://api.github.com/repos/RetroAchievements/RAIntegration","forks_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/forks","keys_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/keys{/key_id}","collaborators_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/teams","hooks_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/hooks","issue_events_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues/events{/number}","events_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/events","assignees_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/assignees{/user}","branches_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/branches{/branch}","tags_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/tags","blobs_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/refs{/sha}","trees_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/trees{/sha}","statuses_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/statuses/{sha}","languages_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/languages","stargazers_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/stargazers","contributors_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/contributors","subscribers_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/subscribers","subscription_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/subscription","commits_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/commits{/sha}","git_commits_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/git/commits{/sha}","comments_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/comments{/number}","issue_comment_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues/comments{/number}","contents_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/contents/{+path}","compare_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/compare/{base}...{head}","merges_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/merges","archive_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/downloads","issues_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues{/number}","pulls_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls{/number}","milestones_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/milestones{/number}","notifications_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/labels{/name}","releases_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/releases{/id}","deployments_url":"https://api.github.com/repos/RetroAchievements/RAIntegration/deployments","created_at":"2018-04-15T11:33:17Z","updated_at":"2018-07-13T21:09:38Z","pushed_at":"2018-07-13T20:59:20Z","git_url":"git://github.com/RetroAchievements/RAIntegration.git","ssh_url":"git@github.com:RetroAchievements/RAIntegration.git","clone_url":"https://github.com/RetroAchievements/RAIntegration.git","svn_url":"https://github.com/RetroAchievements/RAIntegration","homepage":"http://retroachievements.org","size":3060,"stargazers_count":8,"watchers_count":8,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":27,"license":null,"forks":1,"open_issues":27,"watchers":8,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/66"},"html":{"href":"https://github.com/RetroAchievements/RAIntegration/pull/66"},"issue":{"href":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues/66"},"comments":{"href":"https://api.github.com/repos/RetroAchievements/RAIntegration/issues/66/comments"},"review_comments":{"href":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/66/comments"},"review_comment":{"href":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/RetroAchievements/RAIntegration/pulls/66/commits"},"statuses":{"href":"https://api.github.com/repos/RetroAchievements/RAIntegration/statuses/10cc933ac9548582eea913bd11222337ea27cbcd"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"SyrianBallaS"}}