125 return std::move(_bucket);
138 explicit operator bool() const noexcept {
139 return _bucket.operator bool();
326 std::istream* source,
377 std::istream* source,
425 std::istream* source,
477 std::istream* source,
579 std::ostream* destination);
591 std::ostream* destination,
696 return {std::move(v)};
A polyfill for std::string_view.
Definition string_view.hpp:412
bucket() noexcept
Default constructs a bucket object. The bucket is equivalent to the state of a moved from bucket....
Definition bucket.hpp:84
A GridFS bucket.
Definition bucket.hpp:62
Supports MongoDB client session operations.
Definition client_session.hpp:58
A cursor over the documents returned by a query to a MongoDB server.
Definition cursor.hpp:50
A GridFS bucket.
Definition bucket.hpp:74
void upload_from_stream_with_id(bsoncxx::v_noabi::types::view id, bsoncxx::v_noabi::stdx::string_view filename, std::istream *source, v_noabi::options::gridfs::upload const &options={})
Creates a new GridFS file with a user-supplied unique id by uploading bytes from an input stream.
bucket(bucket &&other) noexcept=default
Move constructs a bucket.
v_noabi::gridfs::downloader open_download_stream(bsoncxx::v_noabi::types::view id)
Opens a gridfs::downloader to read a GridFS file.
v_noabi::gridfs::uploader open_upload_stream(bsoncxx::v_noabi::stdx::string_view filename, v_noabi::options::gridfs::upload const &options={})
Opens a gridfs::uploader to create a new GridFS file. The id of the file will be automatically genera...
bucket() noexcept
Default constructs a bucket object. The bucket is equivalent to the state of a moved from bucket....
Definition bucket.hpp:84
void delete_file(bsoncxx::v_noabi::types::view id)
Deletes a GridFS file from the bucket.
void download_to_stream(bsoncxx::v_noabi::types::view id, std::ostream *destination)
Downloads the contents of a stored GridFS file from the bucket and writes it to a stream.
bucket & operator=(bucket &&other) noexcept=default
Move assigns a bucket.
v_noabi::cursor find(bsoncxx::v_noabi::document::view_or_value filter, v_noabi::options::find const &options={})
Finds the documents in the files collection of the bucket which match the provided filter.
v_noabi::result::gridfs::upload upload_from_stream(bsoncxx::v_noabi::stdx::string_view filename, std::istream *source, v_noabi::options::gridfs::upload const &options={})
Creates a new GridFS file by uploading bytes from an input stream. The id of the file will be automat...
bsoncxx::v_noabi::stdx::string_view bucket_name() const
Gets the name of the GridFS bucket.
v_noabi::gridfs::uploader open_upload_stream_with_id(bsoncxx::v_noabi::types::view id, bsoncxx::v_noabi::stdx::string_view filename, v_noabi::options::gridfs::upload const &options={})
Opens a gridfs::uploader to create a new GridFS file.
Used to download a GridFS file.
Definition downloader.hpp:54
Used to upload a GridFS file.
Definition uploader.hpp:49
The result of a GridFS upload operation.
Definition upload.hpp:35
Provides bsoncxx::v_noabi::document::view_or_value.
Provides mongocxx::v_noabi::options::find.
#define MONGOCXX_ABI_EXPORT_CDECL(...)
Equivalent to MONGOCXX_ABI_EXPORT with MONGOCXX_ABI_CDECL.
Definition export.hpp:52
The mongocxx v_noabi macro guard postlude header.
The mongocxx v_noabi macro guard prelude header.
The top-level namespace within which all bsoncxx library entities are declared.
Declares entities whose ABI stability is guaranteed for documented symbols.
Declares entities related to GridFS.
Declares entities representing options to use with various commands.
Declares entities whose ABI stability is NOT guaranteed.
v1::bulk_write to_v1(v_noabi::bulk_write v)
Convert to the mongocxx::v1 equivalent of v.
Definition bulk_write.hpp:162
v_noabi::bulk_write from_v1(v1::bulk_write v)
Convert to the mongocxx::v_noabi equivalent of v.
Definition bulk_write.hpp:155
The top-level namespace within which all mongocxx library entities are declared.
Provides mongocxx::v_noabi::options::gridfs::upload.
Provides mongocxx::v_noabi::result::gridfs::upload.
Provides mongocxx::v1::gridfs::bucket.
Provides std::optional-related polyfills for library API usage.
Provides std::string_view-related polyfills for library API usage.
Provides bsoncxx::v_noabi::types::bson_value::view.
Provides mongocxx::v_noabi::client_session.
Provides mongocxx::v_noabi::cursor.
Declares mongocxx::v_noabi::database.
Declares mongocxx::v_noabi::gridfs::bucket.
Provides utilities to download GridFS files.
Provides utilities to upload GridFS files.
Provides mongocxx::v_noabi::options::gridfs::bucket.