/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include #include #include #include #include #include #include namespace Aws { static const char TAG[] = "GlobalEnumOverflowContainer"; static Aws::Crt::ApiHandle* g_apiHandle; static std::shared_ptr g_defaultClientBootstrap(nullptr); static std::shared_ptr g_defaultTlsConnectionOptions(nullptr); Aws::Crt::ApiHandle* GetApiHandle() { return g_apiHandle; } void SetDefaultClientBootstrap(const std::shared_ptr& clientBootstrap) { g_defaultClientBootstrap = clientBootstrap; } Aws::Crt::Io::ClientBootstrap* GetDefaultClientBootstrap() { return g_defaultClientBootstrap.get(); } void SetDefaultTlsConnectionOptions(const std::shared_ptr& tlsConnectionOptions) { g_defaultTlsConnectionOptions = tlsConnectionOptions; } Aws::Crt::Io::TlsConnectionOptions* GetDefaultTlsConnectionOptions() { return g_defaultTlsConnectionOptions.get(); } void InitializeCrt() { g_apiHandle = Aws::New(TAG, Aws::get_aws_allocator()); } void CleanupCrt() { Aws::SetDefaultClientBootstrap(nullptr); Aws::SetDefaultTlsConnectionOptions(nullptr); Aws::Delete(g_apiHandle); g_apiHandle = nullptr; } static Utils::EnumParseOverflowContainer* g_enumOverflow; Utils::EnumParseOverflowContainer* GetEnumOverflowContainer() { return g_enumOverflow; } void InitializeEnumOverflowContainer() { g_enumOverflow = Aws::New(TAG); } void CleanupEnumOverflowContainer() { Aws::Delete(g_enumOverflow); } }