MongoDB C++ Driver
4.2.0
Loading...
Searching...
No Matches
replace_one_result.hpp
Go to the documentation of this file.
1
// Copyright 2009-present MongoDB, Inc.
2
//
3
// Licensed under the Apache License, Version 2.0 (the "License");
4
// you may not use this file except in compliance with the License.
5
// You may obtain a copy of the License at
6
//
7
// http://www.apache.org/licenses/LICENSE-2.0
8
//
9
// Unless required by applicable law or agreed to in writing, software
10
// distributed under the License is distributed on an "AS IS" BASIS,
11
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
// See the License for the specific language governing permissions and
13
// limitations under the License.
14
15
#pragma once
16
17
#include <
mongocxx/v1/replace_one_result-fwd.hpp
>
// IWYU pragma: export
18
19
//
20
21
#include <
mongocxx/v1/detail/prelude.hpp
>
22
23
#include <
bsoncxx/v1/types/view-fwd.hpp
>
24
25
#include <
bsoncxx/v1/stdx/optional.hpp
>
26
27
#include <
mongocxx/v1/bulk_write.hpp
>
28
#include <
mongocxx/v1/config/export.hpp
>
29
30
#include <cstdint>
31
32
namespace
mongocxx
{
33
namespace
v1
{
34
46
class
replace_one_result
{
47
private
:
48
class
impl;
49
void
* _impl;
50
51
public
:
57
MONGOCXX_ABI_EXPORT_CDECL
()
~replace_one_result
();
58
65
MONGOCXX_ABI_EXPORT_CDECL
()
replace_one_result
(
replace_one_result
&& other) noexcept;
66
73
MONGOCXX_ABI_EXPORT_CDECL
(
replace_one_result
&) operator=(
replace_one_result
&& other) noexcept;
74
78
MONGOCXX_ABI_EXPORT_CDECL
()
replace_one_result
(
replace_one_result
const& other);
79
83
MONGOCXX_ABI_EXPORT_CDECL
(
replace_one_result
&) operator=(
replace_one_result
const& other);
84
88
MONGOCXX_ABI_EXPORT_CDECL
(
v1
::
bulk_write
::
result
)
result
() const;
89
93
MONGOCXX_ABI_EXPORT_CDECL
(std::int64_t)
matched_count
() const;
94
98
MONGOCXX_ABI_EXPORT_CDECL
(std::int64_t)
modified_count
() const;
99
105
MONGOCXX_ABI_EXPORT_CDECL
(
bsoncxx
::
v1
::stdx::optional<
bsoncxx
::
v1
::types::view>)
upserted_id
() const;
106
111
friend
MONGOCXX_ABI_EXPORT_CDECL
(
bool
) operator==(
replace_one_result
const& lhs,
replace_one_result
const& rhs);
112
113
friend
bool
operator!=(
replace_one_result
const& lhs,
replace_one_result
const& rhs) {
114
return
!(lhs == rhs);
115
}
116
118
119
class
internal;
120
121
private
:
122
/* explicit(false) */
replace_one_result
(
void
* impl);
123
};
124
125
}
// namespace v1
126
}
// namespace mongocxx
127
128
#include <
mongocxx/v1/detail/postlude.hpp
>
129
mongocxx::v1::bulk_write
A list of bulk write operations.
Definition
bulk_write.hpp:55
mongocxx::v1::replace_one_result::result
v1::bulk_write::result result() const
Return the raw bulk write result.
mongocxx::v1::replace_one_result::modified_count
std::int64_t modified_count() const
Return the number of documents that were modified.
mongocxx::v1::replace_one_result::replace_one_result
replace_one_result(replace_one_result &&other) noexcept
Move constructor.
mongocxx::v1::replace_one_result::~replace_one_result
~replace_one_result()
Destroy this object.
mongocxx::v1::replace_one_result::upserted_id
bsoncxx::v1::stdx::optional< bsoncxx::v1::types::view > upserted_id() const
Return the upserted document ID.
mongocxx::v1::replace_one_result::matched_count
std::int64_t matched_count() const
Return the number of documents that matched the filter.
export.hpp
Provides macros to control the set of symbols exported in the ABI.
MONGOCXX_ABI_EXPORT_CDECL
#define MONGOCXX_ABI_EXPORT_CDECL(...)
Equivalent to MONGOCXX_ABI_EXPORT with MONGOCXX_ABI_CDECL.
Definition
export.hpp:52
postlude.hpp
The mongocxx v1 macro guard postlude header.
prelude.hpp
The mongocxx v1 macro guard prelude header.
bsoncxx
The top-level namespace within which all bsoncxx library entities are declared.
mongocxx::v1
Declares entities whose ABI stability is guaranteed for documented symbols.
mongocxx
The top-level namespace within which all mongocxx library entities are declared.
replace_one_result-fwd.hpp
Declares mongocxx::v1::replace_one_result.
bulk_write.hpp
Provides entities related to write operations.
optional.hpp
Provides std::optional-related polyfills for library API usage.
view-fwd.hpp
Declares non-owning, read-only entities representing a BSON type value.
mongocxx
v1
replace_one_result.hpp
Generated by
1.15.0