summaryrefslogtreecommitdiff
path: root/src/mongo/db/repl/read_after_optime_response.cpp
diff options
context:
space:
mode:
authorMark Benvenuto <mark.benvenuto@mongodb.com>2015-06-20 00:22:50 -0400
committerMark Benvenuto <mark.benvenuto@mongodb.com>2015-06-20 10:56:02 -0400
commit9c2ed42daa8fbbef4a919c21ec564e2db55e8d60 (patch)
tree3814f79c10d7b490948d8cb7b112ac1dd41ceff1 /src/mongo/db/repl/read_after_optime_response.cpp
parent01965cf52bce6976637ecb8f4a622aeb05ab256a (diff)
downloadmongo-9c2ed42daa8fbbef4a919c21ec564e2db55e8d60.tar.gz
SERVER-18579: Clang-Format - reformat code, no comment reflow
Diffstat (limited to 'src/mongo/db/repl/read_after_optime_response.cpp')
-rw-r--r--src/mongo/db/repl/read_after_optime_response.cpp62
1 files changed, 27 insertions, 35 deletions
diff --git a/src/mongo/db/repl/read_after_optime_response.cpp b/src/mongo/db/repl/read_after_optime_response.cpp
index 3a6d5fc9962..332508c9e3c 100644
--- a/src/mongo/db/repl/read_after_optime_response.cpp
+++ b/src/mongo/db/repl/read_after_optime_response.cpp
@@ -39,48 +39,40 @@ using std::string;
namespace mongo {
namespace repl {
- const string ReadAfterOpTimeResponse::kWaitedMSFieldName("waitedMS");
+const string ReadAfterOpTimeResponse::kWaitedMSFieldName("waitedMS");
- ReadAfterOpTimeResponse::ReadAfterOpTimeResponse(Status status):
- ReadAfterOpTimeResponse(status, stdx::chrono::milliseconds(0), false) {
- }
+ReadAfterOpTimeResponse::ReadAfterOpTimeResponse(Status status)
+ : ReadAfterOpTimeResponse(status, stdx::chrono::milliseconds(0), false) {}
- ReadAfterOpTimeResponse::ReadAfterOpTimeResponse():
- ReadAfterOpTimeResponse(Status::OK()) {
- }
+ReadAfterOpTimeResponse::ReadAfterOpTimeResponse() : ReadAfterOpTimeResponse(Status::OK()) {}
- ReadAfterOpTimeResponse::ReadAfterOpTimeResponse(Status status,
- stdx::chrono::milliseconds duration):
- ReadAfterOpTimeResponse(status, duration, true) {
- }
-
- ReadAfterOpTimeResponse::ReadAfterOpTimeResponse(Status status,
- stdx::chrono::milliseconds duration,
- bool waited):
- _waited(waited),
- _duration(duration),
- _status(status) {
- }
+ReadAfterOpTimeResponse::ReadAfterOpTimeResponse(Status status, stdx::chrono::milliseconds duration)
+ : ReadAfterOpTimeResponse(status, duration, true) {}
- void ReadAfterOpTimeResponse::appendInfo(BSONObjBuilder* builder) {
- if (!_waited) {
- return;
- }
+ReadAfterOpTimeResponse::ReadAfterOpTimeResponse(Status status,
+ stdx::chrono::milliseconds duration,
+ bool waited)
+ : _waited(waited), _duration(duration), _status(status) {}
- builder->append(kWaitedMSFieldName, durationCount<Milliseconds>(_duration));
+void ReadAfterOpTimeResponse::appendInfo(BSONObjBuilder* builder) {
+ if (!_waited) {
+ return;
}
- bool ReadAfterOpTimeResponse::didWait() const {
- return _waited;
- }
+ builder->append(kWaitedMSFieldName, durationCount<Milliseconds>(_duration));
+}
- stdx::chrono::milliseconds ReadAfterOpTimeResponse::getDuration() const {
- return _duration;
- }
+bool ReadAfterOpTimeResponse::didWait() const {
+ return _waited;
+}
- Status ReadAfterOpTimeResponse::getStatus() const {
- return _status;
- }
+stdx::chrono::milliseconds ReadAfterOpTimeResponse::getDuration() const {
+ return _duration;
+}
+
+Status ReadAfterOpTimeResponse::getStatus() const {
+ return _status;
+}
-} // namespace repl
-} // namespace mongo
+} // namespace repl
+} // namespace mongo