![]() |
Mangrove
The C++ Object Document Mapper for MongoDB
|
Represents a comparison expression as above, but stores a value instead of a reference. More...
#include <query_builder.hpp>
Additional Inherited Members | |
![]() | |
constexpr | comparison_expr (const NvpT &nvp, const U &field, const char *op) |
Constructs a query expression for the given key, value, and comparison type. More... | |
constexpr | comparison_expr (const comparison_expr &expr, const char *op) |
Takes a comparison expression, and creates a new one with a different operator, but the same value and field. More... | |
std::string & | append_name (std::string &s) const |
Appends the name of the contained field to a string. | |
void | append_to_bson (bsoncxx::builder::core &builder, bool wrap=false, bool omit_name=false) const |
Appends this expression to a BSON core builder, as a key-value pair of the form "key: {$cmp: val}", where $cmp is some comparison operator. More... | |
operator bsoncxx::document::view_or_value () const | |
Converts the expression to a BSON filter for a query. More... | |
Represents a comparison expression as above, but stores a value instead of a reference.
This is useful for storing temporary or computed values. Internally, it uses a comparison_expr whose value is a b_regex.