NVIDIA DeepStream SDK API Reference
9.2 Release
9.2/includes/opentelemetry/sdk/common/base64.h
Go to the documentation of this file.
1
// Copyright The OpenTelemetry Authors
2
// SPDX-License-Identifier: Apache-2.0
3
4
#pragma once
5
6
#include <string>
7
8
#include "opentelemetry/nostd/string_view.h"
9
#include "opentelemetry/version.h"
10
11
OPENTELEMETRY_BEGIN_NAMESPACE
12
namespace
sdk
13
{
14
namespace
common
15
{
16
// Base64Escape()
17
//
18
// Encodes a `src` string into a base64-encoded 'dest' string with padding
19
// characters. This function conforms with RFC 4648 section 4 (base64) and RFC
20
// 2045.
21
OPENTELEMETRY_EXPORT
void
Base64Escape
(
opentelemetry::nostd::string_view
src, std::string *dest);
22
OPENTELEMETRY_EXPORT
std::string
Base64Escape
(
opentelemetry::nostd::string_view
src);
23
24
// Base64Unescape()
25
//
26
// Converts a `src` string encoded in Base64 (RFC 4648 section 4) to its binary
27
// equivalent, writing it to a `dest` buffer, returning `true` on success. If
28
// `src` contains invalid characters, `dest` is cleared and returns `false`.
29
// If padding is included (note that `Base64Escape()` does produce it), it must
30
// be correct. In the padding, '=' are treated identically.
31
OPENTELEMETRY_EXPORT
bool
Base64Unescape
(
opentelemetry::nostd::string_view
src, std::string *dest);
32
33
}
// namespace common
34
}
// namespace sdk
35
OPENTELEMETRY_END_NAMESPACE
OPENTELEMETRY_EXPORT
#define OPENTELEMETRY_EXPORT
Definition:
includes/opentelemetry/common/macros.h:386
OPENTELEMETRY_BEGIN_NAMESPACE
#define OPENTELEMETRY_BEGIN_NAMESPACE
Definition:
includes/opentelemetry/version.h:21
OPENTELEMETRY_END_NAMESPACE
#define OPENTELEMETRY_END_NAMESPACE
Definition:
includes/opentelemetry/version.h:24
sdk::common::Base64Unescape
OPENTELEMETRY_EXPORT bool Base64Unescape(opentelemetry::nostd::string_view src, std::string *dest)
sdk
Definition:
includes/opentelemetry/sdk/common/atomic_shared_ptr.h:13
nostd::string_view
std::string_view string_view
Definition:
includes/opentelemetry/std/string_view.h:18
sdk::common::Base64Escape
OPENTELEMETRY_EXPORT void Base64Escape(opentelemetry::nostd::string_view src, std::string *dest)
common
Definition:
includes/opentelemetry/common/attribute_value.h:14
Privacy Policy
|
Your Privacy Choices
|
Terms of Service
|
Accessibility
|
Corporate Policies
|
Product Security
|
Contact
© 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
NVIDIA Confidential | Subject to Change | For test and development only.
Wed Oct 28 2026 12:02:00 | PR-09318-R32