Loading...
Searching...
No Matches
bsoncxx::v1::types::b_binary Struct Reference

`#include <bsoncxx/v1/types/view.hpp>`

## Description

BSON type value "Binary Data".

## Public Member Functions

| b_binary ()=default
| Zero-initialize the represented value.
| b_binary (binary_subtype subtype, std::uint32_t size, std::uint8_t const *bytes)
| Initialize with the given binary subtype and pointer to binary data.

## Public Attributes

std::uint8_t const * | bytes = {}
| The represented value's binary data.
std::uint32_t | size = {}
| The represented value's length of binary data.
binary_subtype | subtype = {}
| The represented value's binary subtype component.

## Static Public Attributes

static constexpr id | type_id = id::k_binary
| The type represented by this BSON type value.

## Friends

bool | operator== (b_binary const &lhs, b_binary const &rhs)
| Compare equal when the binary subtype and pointed-to bytes compare equal.
bool | operator!= (b_binary const &lhs, b_binary const &rhs)
| Compare equal when the binary subtype and pointed-to bytes compare equal.

## Constructor & Destructor Documentation

## b_binary() [1/2]

bsoncxx::v1::types::b_binary::b_binary | ( |  | ) |

default

Zero-initialize the represented value.

## b_binary() [2/2]

bsoncxx::v1::types::b_binary::b_binary | ( | binary_subtype | subtype,
|  | std::uint32_t | size,
|  | std::uint8_t const * | bytes )

inline

Initialize with the given binary subtype and pointer to binary data.

## Friends And Related Symbol Documentation

## operator!=

bool operator!= | ( | b_binary const & | lhs,
|  | b_binary const & | rhs )

friend

Compare equal when the binary subtype and pointed-to bytes compare equal.

An "empty" range of bytes (when bytes is null or size is zero) only compares equal to another "empty" range of bytes. The value of subtype is ignored for an empty range of bytes.

## operator==

bool operator== | ( | b_binary const & | lhs,
|  | b_binary const & | rhs )

friend

Compare equal when the binary subtype and pointed-to bytes compare equal.

An "empty" range of bytes (when bytes is null or size is zero) only compares equal to another "empty" range of bytes. The value of subtype is ignored for an empty range of bytes.

## Member Data Documentation

## bytes

std::uint8_t const* bsoncxx::v1::types::b_binary::bytes = {}

The represented value's binary data.

## size

std::uint32_t bsoncxx::v1::types::b_binary::size = {}

The represented value's length of binary data.

## subtype

binary_subtype bsoncxx::v1::types::b_binary::subtype = {}

The represented value's binary subtype component.

## type_id

id bsoncxx::v1::types::b_binary::type_id = id::k_binary

static constexpr

The type represented by this BSON type value.

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

- bsoncxx/v1/types/view.hpp