diff options
| author | Adam Midvidy <amidvidy@gmail.com> | 2015-08-28 20:36:56 -0400 |
|---|---|---|
| committer | Andrew Morrow <acm@mongodb.com> | 2015-09-01 10:45:55 -0400 |
| commit | 176930bbdb1d2eb668d7322bc9fdfaff39a9e970 (patch) | |
| tree | 6d39738445cd53b04b17808e294ca2a69b1ea993 /src/mongo/base/data_range.h | |
| parent | 90715c4e616649b79b4563ecf68e72afb9951753 (diff) | |
| download | mongo-176930bbdb1d2eb668d7322bc9fdfaff39a9e970.tar.gz | |
SERVER-19275 downconvert find/getMore in NetworkInterfaceASIO
Diffstat (limited to 'src/mongo/base/data_range.h')
| -rw-r--r-- | src/mongo/base/data_range.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mongo/base/data_range.h b/src/mongo/base/data_range.h index 9226e6c133a..ee6da34ee7a 100644 --- a/src/mongo/base/data_range.h +++ b/src/mongo/base/data_range.h @@ -62,6 +62,10 @@ public: return _end - _begin; } + bool empty() const { + return length() == 0; + } + template <typename T> Status read(T* t, size_t offset = 0) const { if (offset > length()) { |
