MongoDB C++ Driver mongocxx-3.4.0
Loading...
Searching...
No Matches
Public Member Functions | List of all members
mongocxx::options::create_view Class Reference

Class representing the optional arguments to a view creation operation. More...

#include <create_view.hpp>

Public Member Functions

create_viewcollation (bsoncxx::document::view_or_value collation)
 Sets the default collation for this view.
 
const stdx::optional< bsoncxx::document::view_or_value > & collation () const
 Gets the default collation for this view.
 
create_viewpipeline (pipeline pipeline)
 Sets the pipeline that will be used to compute this view.
 
const stdx::optional< class pipeline > & pipeline () const
 Gets the pipeline that will be used to compute this view.
 
create_viewwrite_concern (mongocxx::write_concern write_concern)
 Sets the write concern that will be used when computing this view.
 
const stdx::optional< class mongocxx::write_concern > & write_concern () const
 Gets the write concern that will be used when computing this view.
 
bsoncxx::document::value to_document () const
 Return a bson document representing the options set on this object.
 
 operator bsoncxx::document::value () const
 

Detailed Description

Class representing the optional arguments to a view creation operation.

See also
https://docs.mongodb.com/master/core/views/

Member Function Documentation

◆ collation() [1/2]

const stdx::optional< bsoncxx::document::view_or_value > & mongocxx::options::create_view::collation ( ) const

Gets the default collation for this view.

Returns
The default collation for the view.
See also
https://docs.mongodb.com/master/reference/collation/

◆ collation() [2/2]

create_view & mongocxx::options::create_view::collation ( bsoncxx::document::view_or_value  collation)

Sets the default collation for this view.

Parameters
collationThe default collation for the view.
Returns
A reference to the object on which this member function is being called. This facilitates method chaining.
See also
https://docs.mongodb.com/master/reference/collation/

◆ operator bsoncxx::document::value()

mongocxx::options::create_view::operator bsoncxx::document::value ( ) const
Deprecated:
This method is deprecated. To determine which options are set on this object, use the provided accessors instead.

◆ pipeline() [1/2]

const stdx::optional< class pipeline > & mongocxx::options::create_view::pipeline ( ) const

Gets the pipeline that will be used to compute this view.

Returns
Pipeline that will be used to compute the view.

◆ pipeline() [2/2]

create_view & mongocxx::options::create_view::pipeline ( pipeline  pipeline)

Sets the pipeline that will be used to compute this view.

Parameters
pipelinePipeline that will be used to compute the view.
Returns
A reference to the object on which this member function is being called. This facilitates method chaining.

◆ to_document()

bsoncxx::document::value mongocxx::options::create_view::to_document ( ) const

Return a bson document representing the options set on this object.

Deprecated:
This method is deprecated. To determine which options are set on this object, use the provided accessors instead.
Returns
Options, as a document.

◆ write_concern() [1/2]

const stdx::optional< class mongocxx::write_concern > & mongocxx::options::create_view::write_concern ( ) const

Gets the write concern that will be used when computing this view.

Returns
Write concern that will be used when computing the view.

◆ write_concern() [2/2]

create_view & mongocxx::options::create_view::write_concern ( mongocxx::write_concern  write_concern)

Sets the write concern that will be used when computing this view.

Parameters
write_concernWrite concern that will be used when computing the view.
Returns
A reference to the object on which this member function is being called. This facilitates method chaining.

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