{"action":"created","comment":{"url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/comments/69897205","id":69897205,"diff_hunk":"@@ -41,107 +41,84 @@ class MPValues\n \n   MPValues() = default;\n \n-  MPValues(MPValuesParameters<dim, spacedim> const &params);\n-\n   virtual ~MPValues() = default;\n \n   virtual void get_values(std::string const &key,\n                           active_cell_iterator const &cell,\n-                          std::vector<double> &values) const;\n+                          std::vector<double> &values) const = 0;\n+};\n+\n+//////////////////////// NEWER STUFF ///////////////////////////////////////////\n+template <int dim, int spacedim = dim>\n+class CompositeMat : public MPValues<dim, spacedim>\n+{\n+public:\n+  using active_cell_iterator =\n+      typename dealii::DoFHandler<dim, spacedim>::active_cell_iterator;\n \n-  virtual void\n-  get_values(std::string const &key, active_cell_iterator const &cell,\n-             std::vector<dealii::Tensor<1, spacedim>> &values) const;\n+  CompositeMat() = default;\n+\n+  void get_values(std::string const &key, active_cell_iterator const &cell,\n+                  std::vector<double> &values) const override;\n \n protected:\n   std::unordered_map<dealii::types::material_id, std::shared_ptr<MPValues<dim>>>\n-      materials;\n+      _materials = {};\n };\n \n-//////////////////////// NEW STUFF ////////////////////////////\n template <int dim, int spacedim = dim>\n-class NewStuffMPValues : public MPValues<dim, spacedim>\n+class CompositePro : public MPValues<dim, spacedim>\n {\n public:\n-  typedef typename dealii::DoFHandler<dim, spacedim>::active_cell_iterator\n-      active_cell_iterator;\n-\n-  NewStuffMPValues(MPValuesParameters<dim, spacedim> const &parameters);\n+  using active_cell_iterator =\n+      typename dealii::DoFHandler<dim, spacedim>::active_cell_iterator;\n \n-  // Needed to fix hidding of get_values.\n-  using MPValues<dim, spacedim>::get_values;\n+  CompositePro() = default;\n \n   void get_values(std::string const &key, active_cell_iterator const &cell,\n                   std::vector<double> &values) const override;\n \n protected:\n-  std::unordered_map<std::string,\n-                     std::function<void(active_cell_iterator const &,\n-                                        std::vector<double> &)>> properties;\n+  std::unordered_map<std::string, std::shared_ptr<MPValues<dim>>> _properties =\n+      {};\n };\n \n template <int dim, int spacedim = dim>\n-class PorousElectrodeMPValues : public NewStuffMPValues<dim, spacedim>\n+class UniformConstantMPValues : public MPValues<dim, spacedim>\n {\n public:\n-  typedef typename dealii::DoFHandler<dim, spacedim>::active_cell_iterator\n-      active_cell_iterator;\n-  PorousElectrodeMPValues(MPValuesParameters<dim, spacedim> const &parameters);\n+  using active_cell_iterator =\n+      typename dealii::DoFHandler<dim, spacedim>::active_cell_iterator;\n+\n+  UniformConstantMPValues(double const &value);\n+\n+  void get_values(std::string const &key, active_cell_iterator const &cell,\n+                  std::vector<double> &values) const override;\n+\n+protected:\n+  double _value;","path":"cpp/source/deal.II/mp_values.h","position":81,"original_position":81,"commit_id":"44a66ea7ff74103f39c87b432816b319e0ec4cdd","original_commit_id":"44a66ea7ff74103f39c87b432816b319e0ec4cdd","user":{"login":"Rombur","id":368538,"avatar_url":"https://avatars.githubusercontent.com/u/368538?v=3","gravatar_id":"","url":"https://api.github.com/users/Rombur","html_url":"https://github.com/Rombur","followers_url":"https://api.github.com/users/Rombur/followers","following_url":"https://api.github.com/users/Rombur/following{/other_user}","gists_url":"https://api.github.com/users/Rombur/gists{/gist_id}","starred_url":"https://api.github.com/users/Rombur/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Rombur/subscriptions","organizations_url":"https://api.github.com/users/Rombur/orgs","repos_url":"https://api.github.com/users/Rombur/repos","events_url":"https://api.github.com/users/Rombur/events{/privacy}","received_events_url":"https://api.github.com/users/Rombur/received_events","type":"User","site_admin":false},"body":"```_value``` is not very descriptive, please add a comment on what this variable does.","created_at":"2016-07-07T12:30:02Z","updated_at":"2016-07-07T12:30:02Z","html_url":"https://github.com/ORNL-CEES/Cap/pull/192#discussion_r69897205","pull_request_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/192","_links":{"self":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/comments/69897205"},"html":{"href":"https://github.com/ORNL-CEES/Cap/pull/192#discussion_r69897205"},"pull_request":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/192"}}},"pull_request":{"url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/192","id":76089191,"html_url":"https://github.com/ORNL-CEES/Cap/pull/192","diff_url":"https://github.com/ORNL-CEES/Cap/pull/192.diff","patch_url":"https://github.com/ORNL-CEES/Cap/pull/192.patch","issue_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues/192","number":192,"state":"open","locked":false,"title":"Refactor MPValues","user":{"login":"dalg24","id":296978,"avatar_url":"https://avatars.githubusercontent.com/u/296978?v=3","gravatar_id":"","url":"https://api.github.com/users/dalg24","html_url":"https://github.com/dalg24","followers_url":"https://api.github.com/users/dalg24/followers","following_url":"https://api.github.com/users/dalg24/following{/other_user}","gists_url":"https://api.github.com/users/dalg24/gists{/gist_id}","starred_url":"https://api.github.com/users/dalg24/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dalg24/subscriptions","organizations_url":"https://api.github.com/users/dalg24/orgs","repos_url":"https://api.github.com/users/dalg24/repos","events_url":"https://api.github.com/users/dalg24/events{/privacy}","received_events_url":"https://api.github.com/users/dalg24/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-07-03T13:36:35Z","updated_at":"2016-07-07T12:30:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4ceeec0322fb74a3d35c7e95d6be4273091a9ea2","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/192/commits","review_comments_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/192/comments","review_comment_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues/192/comments","statuses_url":"https://api.github.com/repos/ORNL-CEES/Cap/statuses/44a66ea7ff74103f39c87b432816b319e0ec4cdd","head":{"label":"dalg24:mp_values","ref":"mp_values","sha":"44a66ea7ff74103f39c87b432816b319e0ec4cdd","user":{"login":"dalg24","id":296978,"avatar_url":"https://avatars.githubusercontent.com/u/296978?v=3","gravatar_id":"","url":"https://api.github.com/users/dalg24","html_url":"https://github.com/dalg24","followers_url":"https://api.github.com/users/dalg24/followers","following_url":"https://api.github.com/users/dalg24/following{/other_user}","gists_url":"https://api.github.com/users/dalg24/gists{/gist_id}","starred_url":"https://api.github.com/users/dalg24/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dalg24/subscriptions","organizations_url":"https://api.github.com/users/dalg24/orgs","repos_url":"https://api.github.com/users/dalg24/repos","events_url":"https://api.github.com/users/dalg24/events{/privacy}","received_events_url":"https://api.github.com/users/dalg24/received_events","type":"User","site_admin":false},"repo":{"id":50518669,"name":"Cap","full_name":"dalg24/Cap","owner":{"login":"dalg24","id":296978,"avatar_url":"https://avatars.githubusercontent.com/u/296978?v=3","gravatar_id":"","url":"https://api.github.com/users/dalg24","html_url":"https://github.com/dalg24","followers_url":"https://api.github.com/users/dalg24/followers","following_url":"https://api.github.com/users/dalg24/following{/other_user}","gists_url":"https://api.github.com/users/dalg24/gists{/gist_id}","starred_url":"https://api.github.com/users/dalg24/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dalg24/subscriptions","organizations_url":"https://api.github.com/users/dalg24/orgs","repos_url":"https://api.github.com/users/dalg24/repos","events_url":"https://api.github.com/users/dalg24/events{/privacy}","received_events_url":"https://api.github.com/users/dalg24/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/dalg24/Cap","description":"A library for modeling energy storage devices.","fork":true,"url":"https://api.github.com/repos/dalg24/Cap","forks_url":"https://api.github.com/repos/dalg24/Cap/forks","keys_url":"https://api.github.com/repos/dalg24/Cap/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dalg24/Cap/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dalg24/Cap/teams","hooks_url":"https://api.github.com/repos/dalg24/Cap/hooks","issue_events_url":"https://api.github.com/repos/dalg24/Cap/issues/events{/number}","events_url":"https://api.github.com/repos/dalg24/Cap/events","assignees_url":"https://api.github.com/repos/dalg24/Cap/assignees{/user}","branches_url":"https://api.github.com/repos/dalg24/Cap/branches{/branch}","tags_url":"https://api.github.com/repos/dalg24/Cap/tags","blobs_url":"https://api.github.com/repos/dalg24/Cap/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dalg24/Cap/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dalg24/Cap/git/refs{/sha}","trees_url":"https://api.github.com/repos/dalg24/Cap/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dalg24/Cap/statuses/{sha}","languages_url":"https://api.github.com/repos/dalg24/Cap/languages","stargazers_url":"https://api.github.com/repos/dalg24/Cap/stargazers","contributors_url":"https://api.github.com/repos/dalg24/Cap/contributors","subscribers_url":"https://api.github.com/repos/dalg24/Cap/subscribers","subscription_url":"https://api.github.com/repos/dalg24/Cap/subscription","commits_url":"https://api.github.com/repos/dalg24/Cap/commits{/sha}","git_commits_url":"https://api.github.com/repos/dalg24/Cap/git/commits{/sha}","comments_url":"https://api.github.com/repos/dalg24/Cap/comments{/number}","issue_comment_url":"https://api.github.com/repos/dalg24/Cap/issues/comments{/number}","contents_url":"https://api.github.com/repos/dalg24/Cap/contents/{+path}","compare_url":"https://api.github.com/repos/dalg24/Cap/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dalg24/Cap/merges","archive_url":"https://api.github.com/repos/dalg24/Cap/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dalg24/Cap/downloads","issues_url":"https://api.github.com/repos/dalg24/Cap/issues{/number}","pulls_url":"https://api.github.com/repos/dalg24/Cap/pulls{/number}","milestones_url":"https://api.github.com/repos/dalg24/Cap/milestones{/number}","notifications_url":"https://api.github.com/repos/dalg24/Cap/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dalg24/Cap/labels{/name}","releases_url":"https://api.github.com/repos/dalg24/Cap/releases{/id}","deployments_url":"https://api.github.com/repos/dalg24/Cap/deployments","created_at":"2016-01-27T15:55:11Z","updated_at":"2016-03-16T23:13:07Z","pushed_at":"2016-07-06T18:11:57Z","git_url":"git://github.com/dalg24/Cap.git","ssh_url":"git@github.com:dalg24/Cap.git","clone_url":"https://github.com/dalg24/Cap.git","svn_url":"https://github.com/dalg24/Cap","homepage":"http://cap.readthedocs.org","size":1604,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ORNL-CEES:master","ref":"master","sha":"9b5708fb951671dac402514e23dad9eed14def79","user":{"login":"ORNL-CEES","id":6653148,"avatar_url":"https://avatars.githubusercontent.com/u/6653148?v=3","gravatar_id":"","url":"https://api.github.com/users/ORNL-CEES","html_url":"https://github.com/ORNL-CEES","followers_url":"https://api.github.com/users/ORNL-CEES/followers","following_url":"https://api.github.com/users/ORNL-CEES/following{/other_user}","gists_url":"https://api.github.com/users/ORNL-CEES/gists{/gist_id}","starred_url":"https://api.github.com/users/ORNL-CEES/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ORNL-CEES/subscriptions","organizations_url":"https://api.github.com/users/ORNL-CEES/orgs","repos_url":"https://api.github.com/users/ORNL-CEES/repos","events_url":"https://api.github.com/users/ORNL-CEES/events{/privacy}","received_events_url":"https://api.github.com/users/ORNL-CEES/received_events","type":"Organization","site_admin":false},"repo":{"id":50514800,"name":"Cap","full_name":"ORNL-CEES/Cap","owner":{"login":"ORNL-CEES","id":6653148,"avatar_url":"https://avatars.githubusercontent.com/u/6653148?v=3","gravatar_id":"","url":"https://api.github.com/users/ORNL-CEES","html_url":"https://github.com/ORNL-CEES","followers_url":"https://api.github.com/users/ORNL-CEES/followers","following_url":"https://api.github.com/users/ORNL-CEES/following{/other_user}","gists_url":"https://api.github.com/users/ORNL-CEES/gists{/gist_id}","starred_url":"https://api.github.com/users/ORNL-CEES/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ORNL-CEES/subscriptions","organizations_url":"https://api.github.com/users/ORNL-CEES/orgs","repos_url":"https://api.github.com/users/ORNL-CEES/repos","events_url":"https://api.github.com/users/ORNL-CEES/events{/privacy}","received_events_url":"https://api.github.com/users/ORNL-CEES/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ORNL-CEES/Cap","description":"A library for modeling energy storage devices.","fork":false,"url":"https://api.github.com/repos/ORNL-CEES/Cap","forks_url":"https://api.github.com/repos/ORNL-CEES/Cap/forks","keys_url":"https://api.github.com/repos/ORNL-CEES/Cap/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ORNL-CEES/Cap/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ORNL-CEES/Cap/teams","hooks_url":"https://api.github.com/repos/ORNL-CEES/Cap/hooks","issue_events_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues/events{/number}","events_url":"https://api.github.com/repos/ORNL-CEES/Cap/events","assignees_url":"https://api.github.com/repos/ORNL-CEES/Cap/assignees{/user}","branches_url":"https://api.github.com/repos/ORNL-CEES/Cap/branches{/branch}","tags_url":"https://api.github.com/repos/ORNL-CEES/Cap/tags","blobs_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/refs{/sha}","trees_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ORNL-CEES/Cap/statuses/{sha}","languages_url":"https://api.github.com/repos/ORNL-CEES/Cap/languages","stargazers_url":"https://api.github.com/repos/ORNL-CEES/Cap/stargazers","contributors_url":"https://api.github.com/repos/ORNL-CEES/Cap/contributors","subscribers_url":"https://api.github.com/repos/ORNL-CEES/Cap/subscribers","subscription_url":"https://api.github.com/repos/ORNL-CEES/Cap/subscription","commits_url":"https://api.github.com/repos/ORNL-CEES/Cap/commits{/sha}","git_commits_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/commits{/sha}","comments_url":"https://api.github.com/repos/ORNL-CEES/Cap/comments{/number}","issue_comment_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues/comments{/number}","contents_url":"https://api.github.com/repos/ORNL-CEES/Cap/contents/{+path}","compare_url":"https://api.github.com/repos/ORNL-CEES/Cap/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ORNL-CEES/Cap/merges","archive_url":"https://api.github.com/repos/ORNL-CEES/Cap/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ORNL-CEES/Cap/downloads","issues_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues{/number}","pulls_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls{/number}","milestones_url":"https://api.github.com/repos/ORNL-CEES/Cap/milestones{/number}","notifications_url":"https://api.github.com/repos/ORNL-CEES/Cap/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ORNL-CEES/Cap/labels{/name}","releases_url":"https://api.github.com/repos/ORNL-CEES/Cap/releases{/id}","deployments_url":"https://api.github.com/repos/ORNL-CEES/Cap/deployments","created_at":"2016-01-27T14:56:58Z","updated_at":"2016-05-15T11:42:43Z","pushed_at":"2016-07-06T18:09:25Z","git_url":"git://github.com/ORNL-CEES/Cap.git","ssh_url":"git@github.com:ORNL-CEES/Cap.git","clone_url":"https://github.com/ORNL-CEES/Cap.git","svn_url":"https://github.com/ORNL-CEES/Cap","homepage":"http://cap.readthedocs.org","size":1615,"stargazers_count":1,"watchers_count":1,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":10,"forks":4,"open_issues":10,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/192"},"html":{"href":"https://github.com/ORNL-CEES/Cap/pull/192"},"issue":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/issues/192"},"comments":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/issues/192/comments"},"review_comments":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/192/comments"},"review_comment":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/192/commits"},"statuses":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/statuses/44a66ea7ff74103f39c87b432816b319e0ec4cdd"}}}}
{"actor":{"display_login":"Rombur"}}