GitHub PullRequestReviewCommentEvent at 2014-05-04 17:01:04
Repository: mongo-cxx-driver
Actor: acmorrow
Payload: {"comment":{"url":"https://api.github.com/repos/mongodb/mongo-cxx-driver/pulls/comments/12262634","id":12262634,"diff_hunk":"@@ -0,0 +1,36 @@\n+/*    Copyright 2014 MongoDB Inc.\n+ *\n+ *    Licensed under the Apache License, Version 2.0 (the \"License\");\n+ *    you may not use this file except in compliance with the License.\n+ *    You may obtain a copy of the License at\n+ *\n+ *    http://www.apache.org/licenses/LICENSE-2.0\n+ *\n+ *    Unless required by applicable law or agreed to in writing, software\n+ *    distributed under the License is distributed on an \"AS IS\" BASIS,\n+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+ *    See the License for the specific language governing permissions and\n+ *    limitations under the License.\n+ */\n+\n+#include \"mongo/client/exceptions.h\"\n+\n+namespace {\n+    const char kName[] = \"OperationException\";\n+}\n+\n+namespace mongo {\n+\n+    OperationException::OperationException(const BSONObj& gle_result) throw()\n+        : std::runtime_error(std::string(kName) + \": \" + gle_result.toString())","path":"src/mongo/client/exceptions.cpp","position":25,"original_position":25,"commit_id":"2d16bce4dbe0edd62c82818983d5cc37e4489352","original_commit_id":"2d16bce4dbe0edd62c82818983d5cc37e4489352","user":{"login":"acmorrow","id":268253,"avatar_url":"https://avatars.githubusercontent.com/u/268253?","gravatar_id":"dbfcfc0e3c4b2b0baef2383fbc97f687","url":"https://api.github.com/users/acmorrow","html_url":"https://github.com/acmorrow","followers_url":"https://api.github.com/users/acmorrow/followers","following_url":"https://api.github.com/users/acmorrow/following{/other_user}","gists_url":"https://api.github.com/users/acmorrow/gists{/gist_id}","starred_url":"https://api.github.com/users/acmorrow/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/acmorrow/subscriptions","organizations_url":"https://api.github.com/users/acmorrow/orgs","repos_url":"https://api.github.com/users/acmorrow/repos","events_url":"https://api.github.com/users/acmorrow/events{/privacy}","received_events_url":"https://api.github.com/users/acmorrow/received_events","type":"User","site_admin":false},"body":"If you want to keep this stringified version (which I'm certainly OK with) after dropping runtime_exception as a base class, I would just add a const std::string member to the OperationException and initialize it in the initializer list.","created_at":"2014-05-04T17:01:04Z","updated_at":"2014-05-04T17:01:04Z","html_url":"https://github.com/mongodb/mongo-cxx-driver/pull/67#discussion_r12262634","pull_request_url":"https://api.github.com/repos/mongodb/mongo-cxx-driver/pulls/67","_links":{"self":{"href":"https://api.github.com/repos/mongodb/mongo-cxx-driver/pulls/comments/12262634"},"html":{"href":"https://github.com/mongodb/mongo-cxx-driver/pull/67#discussion_r12262634"},"pull_request":{"href":"https://api.github.com/repos/mongodb/mongo-cxx-driver/pulls/67"}}}}