MongoDB C++ Driver  mongocxx-3.0.1
Public Member Functions | List of all members
mongocxx::options::distinct Class Reference

Class representing the optional arguments to a MongoDB distinct command. More...

#include <distinct.hpp>

Public Member Functions

void max_time (std::chrono::milliseconds max_time)
 Sets the maximum amount of time for this operation to run (server-side) in milliseconds. More...
 
const stdx::optional< std::chrono::milliseconds > & max_time () const
 The current max_time setting. More...
 
void read_preference (class read_preference rp)
 Sets the read_preference for this operation. More...
 
const stdx::optional< class read_preference > & read_preference () const
 The current read_preference for this operation. More...
 

Detailed Description

Class representing the optional arguments to a MongoDB distinct command.

Member Function Documentation

void mongocxx::options::distinct::max_time ( std::chrono::milliseconds  max_time)

Sets the maximum amount of time for this operation to run (server-side) in milliseconds.

Parameters
max_timeThe max amount of time (in milliseconds).
See also
http://docs.mongodb.org/manual/reference/operator/meta/maxTimeMS
const stdx::optional<std::chrono::milliseconds>& mongocxx::options::distinct::max_time ( ) const

The current max_time setting.

Returns
The current max time (in milliseconds).
See also
http://docs.mongodb.org/manual/reference/operator/meta/maxTimeMS
void mongocxx::options::distinct::read_preference ( class read_preference  rp)

Sets the read_preference for this operation.

Parameters
rpThe new read_preference.
See also
http://docs.mongodb.org/manual/core/read-preference/
const stdx::optional<class read_preference>& mongocxx::options::distinct::read_preference ( ) const

The current read_preference for this operation.

Returns
the current read_preference.
See also
http://docs.mongodb.org/manual/core/read-preference/

The documentation for this class was generated from the following file: