{"action":"closed","number":71,"pull_request":{"url":"https://api.github.com/repos/monero-integrations/monerophp/pulls/71","id":180341782,"html_url":"https://github.com/monero-integrations/monerophp/pull/71","diff_url":"https://github.com/monero-integrations/monerophp/pull/71.diff","patch_url":"https://github.com/monero-integrations/monerophp/pull/71.patch","issue_url":"https://api.github.com/repos/monero-integrations/monerophp/issues/71","number":71,"state":"closed","locked":false,"title":"Allow daemon and wallet RPC classes to be optionally constructed with parameters passed in as objects/dictionaries (associative arrays)","user":{"login":"sneurlax","id":4107993,"avatar_url":"https://avatars1.githubusercontent.com/u/4107993?v=4","gravatar_id":"","url":"https://api.github.com/users/sneurlax","html_url":"https://github.com/sneurlax","followers_url":"https://api.github.com/users/sneurlax/followers","following_url":"https://api.github.com/users/sneurlax/following{/other_user}","gists_url":"https://api.github.com/users/sneurlax/gists{/gist_id}","starred_url":"https://api.github.com/users/sneurlax/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sneurlax/subscriptions","organizations_url":"https://api.github.com/users/sneurlax/orgs","repos_url":"https://api.github.com/users/sneurlax/repos","events_url":"https://api.github.com/users/sneurlax/events{/privacy}","received_events_url":"https://api.github.com/users/sneurlax/received_events","type":"User","site_admin":false},"body":"This pull request adds the *optional* (backwards-compatible) ability for the wallet and daemon RPC classes to be initialized with/parameters passed in as objects/dictionaries (associative arrays.)  After this pull request, RPC classes can be initialized in any of the following ways:\r\n\r\n```php\r\n$daemonRPC = new daemonRPC('127.0.0.1', 28082);\r\n```\r\n\r\n```php\r\n$daemonRPC = new daemonRPC(['host' => '127.0.0.1', 'port' => 28082]);\r\n```\r\n\r\n*or*\r\n\r\n```php\r\n$daemonRPC = new daemonRPC(['user' => 'username', 'password' => 'passphrase']);\r\n```\r\n\r\nThe last example demonstrates how parameters can be passed in in any order or combination, with parameters using their default values if they're not defined.\r\n\r\nThis pull request isn't necessary at the moment but it does add the capability needed to pass in `['autoconnect' => true]`, which is the next functionality I'm adding (see https://github.com/sneurlax/moneronodejs/commit/9f17be53cf43e9e1136536d5527b738af330a3e5 for the autoconnect functionality I'm going to port over here.)\r\n\r\nThis is optional and backwards-compatible, *ie.* nobody has to change what they're doing now; all current code will continue working as normal.","created_at":"2018-04-09T15:15:48Z","updated_at":"2018-04-16T19:16:11Z","closed_at":"2018-04-16T19:16:11Z","merged_at":"2018-04-16T19:16:11Z","merge_commit_sha":"d6903ecae91224bdac581499618692e6b1fe5c20","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/monero-integrations/monerophp/pulls/71/commits","review_comments_url":"https://api.github.com/repos/monero-integrations/monerophp/pulls/71/comments","review_comment_url":"https://api.github.com/repos/monero-integrations/monerophp/pulls/comments{/number}","comments_url":"https://api.github.com/repos/monero-integrations/monerophp/issues/71/comments","statuses_url":"https://api.github.com/repos/monero-integrations/monerophp/statuses/5cae7e9f03c4b7614379817c14237b825d49243d","head":{"label":"sneurlax:feature/object-initialization","ref":"feature/object-initialization","sha":"5cae7e9f03c4b7614379817c14237b825d49243d","user":{"login":"sneurlax","id":4107993,"avatar_url":"https://avatars1.githubusercontent.com/u/4107993?v=4","gravatar_id":"","url":"https://api.github.com/users/sneurlax","html_url":"https://github.com/sneurlax","followers_url":"https://api.github.com/users/sneurlax/followers","following_url":"https://api.github.com/users/sneurlax/following{/other_user}","gists_url":"https://api.github.com/users/sneurlax/gists{/gist_id}","starred_url":"https://api.github.com/users/sneurlax/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sneurlax/subscriptions","organizations_url":"https://api.github.com/users/sneurlax/orgs","repos_url":"https://api.github.com/users/sneurlax/repos","events_url":"https://api.github.com/users/sneurlax/events{/privacy}","received_events_url":"https://api.github.com/users/sneurlax/received_events","type":"User","site_admin":false},"repo":{"id":122150381,"name":"monerophp","full_name":"sneurlax/monerophp","owner":{"login":"sneurlax","id":4107993,"avatar_url":"https://avatars1.githubusercontent.com/u/4107993?v=4","gravatar_id":"","url":"https://api.github.com/users/sneurlax","html_url":"https://github.com/sneurlax","followers_url":"https://api.github.com/users/sneurlax/followers","following_url":"https://api.github.com/users/sneurlax/following{/other_user}","gists_url":"https://api.github.com/users/sneurlax/gists{/gist_id}","starred_url":"https://api.github.com/users/sneurlax/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sneurlax/subscriptions","organizations_url":"https://api.github.com/users/sneurlax/orgs","repos_url":"https://api.github.com/users/sneurlax/repos","events_url":"https://api.github.com/users/sneurlax/events{/privacy}","received_events_url":"https://api.github.com/users/sneurlax/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/sneurlax/monerophp","description":"Monero PHP library and JSON RPC client","fork":true,"url":"https://api.github.com/repos/sneurlax/monerophp","forks_url":"https://api.github.com/repos/sneurlax/monerophp/forks","keys_url":"https://api.github.com/repos/sneurlax/monerophp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sneurlax/monerophp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sneurlax/monerophp/teams","hooks_url":"https://api.github.com/repos/sneurlax/monerophp/hooks","issue_events_url":"https://api.github.com/repos/sneurlax/monerophp/issues/events{/number}","events_url":"https://api.github.com/repos/sneurlax/monerophp/events","assignees_url":"https://api.github.com/repos/sneurlax/monerophp/assignees{/user}","branches_url":"https://api.github.com/repos/sneurlax/monerophp/branches{/branch}","tags_url":"https://api.github.com/repos/sneurlax/monerophp/tags","blobs_url":"https://api.github.com/repos/sneurlax/monerophp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sneurlax/monerophp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sneurlax/monerophp/git/refs{/sha}","trees_url":"https://api.github.com/repos/sneurlax/monerophp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sneurlax/monerophp/statuses/{sha}","languages_url":"https://api.github.com/repos/sneurlax/monerophp/languages","stargazers_url":"https://api.github.com/repos/sneurlax/monerophp/stargazers","contributors_url":"https://api.github.com/repos/sneurlax/monerophp/contributors","subscribers_url":"https://api.github.com/repos/sneurlax/monerophp/subscribers","subscription_url":"https://api.github.com/repos/sneurlax/monerophp/subscription","commits_url":"https://api.github.com/repos/sneurlax/monerophp/commits{/sha}","git_commits_url":"https://api.github.com/repos/sneurlax/monerophp/git/commits{/sha}","comments_url":"https://api.github.com/repos/sneurlax/monerophp/comments{/number}","issue_comment_url":"https://api.github.com/repos/sneurlax/monerophp/issues/comments{/number}","contents_url":"https://api.github.com/repos/sneurlax/monerophp/contents/{+path}","compare_url":"https://api.github.com/repos/sneurlax/monerophp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sneurlax/monerophp/merges","archive_url":"https://api.github.com/repos/sneurlax/monerophp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sneurlax/monerophp/downloads","issues_url":"https://api.github.com/repos/sneurlax/monerophp/issues{/number}","pulls_url":"https://api.github.com/repos/sneurlax/monerophp/pulls{/number}","milestones_url":"https://api.github.com/repos/sneurlax/monerophp/milestones{/number}","notifications_url":"https://api.github.com/repos/sneurlax/monerophp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sneurlax/monerophp/labels{/name}","releases_url":"https://api.github.com/repos/sneurlax/monerophp/releases{/id}","deployments_url":"https://api.github.com/repos/sneurlax/monerophp/deployments","created_at":"2018-02-20T03:20:59Z","updated_at":"2018-04-02T19:32:41Z","pushed_at":"2018-04-09T15:09:59Z","git_url":"git://github.com/sneurlax/monerophp.git","ssh_url":"git@github.com:sneurlax/monerophp.git","clone_url":"https://github.com/sneurlax/monerophp.git","svn_url":"https://github.com/sneurlax/monerophp","homepage":"https://github.com/monero-integrations/monerophp","size":607,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":12,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":0,"open_issues":12,"watchers":0,"default_branch":"master"}},"base":{"label":"monero-integrations:master","ref":"master","sha":"2fcf6977828b741afb4ef683f793e90b8999fa9e","user":{"login":"monero-integrations","id":29192264,"avatar_url":"https://avatars2.githubusercontent.com/u/29192264?v=4","gravatar_id":"","url":"https://api.github.com/users/monero-integrations","html_url":"https://github.com/monero-integrations","followers_url":"https://api.github.com/users/monero-integrations/followers","following_url":"https://api.github.com/users/monero-integrations/following{/other_user}","gists_url":"https://api.github.com/users/monero-integrations/gists{/gist_id}","starred_url":"https://api.github.com/users/monero-integrations/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/monero-integrations/subscriptions","organizations_url":"https://api.github.com/users/monero-integrations/orgs","repos_url":"https://api.github.com/users/monero-integrations/repos","events_url":"https://api.github.com/users/monero-integrations/events{/privacy}","received_events_url":"https://api.github.com/users/monero-integrations/received_events","type":"Organization","site_admin":false},"repo":{"id":93746333,"name":"monerophp","full_name":"monero-integrations/monerophp","owner":{"login":"monero-integrations","id":29192264,"avatar_url":"https://avatars2.githubusercontent.com/u/29192264?v=4","gravatar_id":"","url":"https://api.github.com/users/monero-integrations","html_url":"https://github.com/monero-integrations","followers_url":"https://api.github.com/users/monero-integrations/followers","following_url":"https://api.github.com/users/monero-integrations/following{/other_user}","gists_url":"https://api.github.com/users/monero-integrations/gists{/gist_id}","starred_url":"https://api.github.com/users/monero-integrations/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/monero-integrations/subscriptions","organizations_url":"https://api.github.com/users/monero-integrations/orgs","repos_url":"https://api.github.com/users/monero-integrations/repos","events_url":"https://api.github.com/users/monero-integrations/events{/privacy}","received_events_url":"https://api.github.com/users/monero-integrations/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/monero-integrations/monerophp","description":"Monero Php library + JsonRPC Client","fork":false,"url":"https://api.github.com/repos/monero-integrations/monerophp","forks_url":"https://api.github.com/repos/monero-integrations/monerophp/forks","keys_url":"https://api.github.com/repos/monero-integrations/monerophp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/monero-integrations/monerophp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/monero-integrations/monerophp/teams","hooks_url":"https://api.github.com/repos/monero-integrations/monerophp/hooks","issue_events_url":"https://api.github.com/repos/monero-integrations/monerophp/issues/events{/number}","events_url":"https://api.github.com/repos/monero-integrations/monerophp/events","assignees_url":"https://api.github.com/repos/monero-integrations/monerophp/assignees{/user}","branches_url":"https://api.github.com/repos/monero-integrations/monerophp/branches{/branch}","tags_url":"https://api.github.com/repos/monero-integrations/monerophp/tags","blobs_url":"https://api.github.com/repos/monero-integrations/monerophp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/monero-integrations/monerophp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/monero-integrations/monerophp/git/refs{/sha}","trees_url":"https://api.github.com/repos/monero-integrations/monerophp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/monero-integrations/monerophp/statuses/{sha}","languages_url":"https://api.github.com/repos/monero-integrations/monerophp/languages","stargazers_url":"https://api.github.com/repos/monero-integrations/monerophp/stargazers","contributors_url":"https://api.github.com/repos/monero-integrations/monerophp/contributors","subscribers_url":"https://api.github.com/repos/monero-integrations/monerophp/subscribers","subscription_url":"https://api.github.com/repos/monero-integrations/monerophp/subscription","commits_url":"https://api.github.com/repos/monero-integrations/monerophp/commits{/sha}","git_commits_url":"https://api.github.com/repos/monero-integrations/monerophp/git/commits{/sha}","comments_url":"https://api.github.com/repos/monero-integrations/monerophp/comments{/number}","issue_comment_url":"https://api.github.com/repos/monero-integrations/monerophp/issues/comments{/number}","contents_url":"https://api.github.com/repos/monero-integrations/monerophp/contents/{+path}","compare_url":"https://api.github.com/repos/monero-integrations/monerophp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/monero-integrations/monerophp/merges","archive_url":"https://api.github.com/repos/monero-integrations/monerophp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/monero-integrations/monerophp/downloads","issues_url":"https://api.github.com/repos/monero-integrations/monerophp/issues{/number}","pulls_url":"https://api.github.com/repos/monero-integrations/monerophp/pulls{/number}","milestones_url":"https://api.github.com/repos/monero-integrations/monerophp/milestones{/number}","notifications_url":"https://api.github.com/repos/monero-integrations/monerophp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/monero-integrations/monerophp/labels{/name}","releases_url":"https://api.github.com/repos/monero-integrations/monerophp/releases{/id}","deployments_url":"https://api.github.com/repos/monero-integrations/monerophp/deployments","created_at":"2017-06-08T12:20:25Z","updated_at":"2018-04-11T08:01:46Z","pushed_at":"2018-04-16T19:16:11Z","git_url":"git://github.com/monero-integrations/monerophp.git","ssh_url":"git@github.com:monero-integrations/monerophp.git","clone_url":"https://github.com/monero-integrations/monerophp.git","svn_url":"https://github.com/monero-integrations/monerophp","homepage":null,"size":534,"stargazers_count":26,"watchers_count":26,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":20,"mirror_url":null,"archived":false,"open_issues_count":4,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":20,"open_issues":4,"watchers":26,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/monero-integrations/monerophp/pulls/71"},"html":{"href":"https://github.com/monero-integrations/monerophp/pull/71"},"issue":{"href":"https://api.github.com/repos/monero-integrations/monerophp/issues/71"},"comments":{"href":"https://api.github.com/repos/monero-integrations/monerophp/issues/71/comments"},"review_comments":{"href":"https://api.github.com/repos/monero-integrations/monerophp/pulls/71/comments"},"review_comment":{"href":"https://api.github.com/repos/monero-integrations/monerophp/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/monero-integrations/monerophp/pulls/71/commits"},"statuses":{"href":"https://api.github.com/repos/monero-integrations/monerophp/statuses/5cae7e9f03c4b7614379817c14237b825d49243d"}},"author_association":"CONTRIBUTOR","merged":true,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":{"login":"serhack","id":27734319,"avatar_url":"https://avatars3.githubusercontent.com/u/27734319?v=4","gravatar_id":"","url":"https://api.github.com/users/serhack","html_url":"https://github.com/serhack","followers_url":"https://api.github.com/users/serhack/followers","following_url":"https://api.github.com/users/serhack/following{/other_user}","gists_url":"https://api.github.com/users/serhack/gists{/gist_id}","starred_url":"https://api.github.com/users/serhack/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/serhack/subscriptions","organizations_url":"https://api.github.com/users/serhack/orgs","repos_url":"https://api.github.com/users/serhack/repos","events_url":"https://api.github.com/users/serhack/events{/privacy}","received_events_url":"https://api.github.com/users/serhack/received_events","type":"User","site_admin":false},"comments":2,"review_comments":0,"maintainer_can_modify":false,"commits":1,"additions":64,"deletions":3,"changed_files":5}}
{"actor":{"display_login":"serhack"}}