diff options
author | Matt Dannenberg <matt.dannenberg@10gen.com> | 2013-05-16 15:17:54 -0400 |
---|---|---|
committer | Mathias Stearn <mathias@10gen.com> | 2013-06-18 12:51:15 -0400 |
commit | d9c570d95817d3a17c08f5cfab98112f55220a64 (patch) | |
tree | 61d97b626a519d74ab211519dd41b24e695f0891 /src/mongo/db/pipeline/document.h | |
parent | c020b94a9e3154cf0b18ea8e504992f2ab3ae885 (diff) | |
download | mongo-d9c570d95817d3a17c08f5cfab98112f55220a64.tar.gz |
exchanged toBson(Obj|Array) to serialize in agg
Diffstat (limited to 'src/mongo/db/pipeline/document.h')
-rw-r--r-- | src/mongo/db/pipeline/document.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mongo/db/pipeline/document.h b/src/mongo/db/pipeline/document.h index b51efa91497..2cf64291dfe 100644 --- a/src/mongo/db/pipeline/document.h +++ b/src/mongo/db/pipeline/document.h @@ -316,6 +316,11 @@ namespace mongo { return ret; } + /// Used to simplify the common pattern of creating a value of the document. + Value freezeToValue() { + return Value(freeze()); + } + /** Borrow a readable reference to this Document. * * Note that unlike freeze(), this indicates intention to continue |