SiddiqSoft.AzureCppUtils
1.2.3
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package SiddiqSoft.AzureCppUtils --version 1.2.3
NuGet\Install-Package SiddiqSoft.AzureCppUtils -Version 1.2.3
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SiddiqSoft.AzureCppUtils" Version="1.2.3" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add SiddiqSoft.AzureCppUtils --version 1.2.3
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: SiddiqSoft.AzureCppUtils, 1.2.3"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install SiddiqSoft.AzureCppUtils as a Cake Addin #addin nuget:?package=SiddiqSoft.AzureCppUtils&version=1.2.3 // Install SiddiqSoft.AzureCppUtils as a Cake Tool #tool nuget:?package=SiddiqSoft.AzureCppUtils&version=1.2.3
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Azure C++ Utils : Azure REST API Helpers for Modern C++
Objective
- Collect useful helpers for Azure REST API in a single location.
- Header-only
- Use Win32 functions on Windows
Requirements
- The build and tests are for Visual Studio 2019 under x64.
Usage
- Use the nuget SiddiqSoft.AzureCppUtils
- Copy paste..whatever works.
Features
- DateUtils
- RFC7231 and RFC1123
- ISO8601
- ConversionUtils
- utf8fromWide
- wideFromUtf8
- Bas64Utils
- encode
- decode
- EncryptionUtils
- MD5
- HMAC
- JWTSHA256
- SASToken
- CosmosToken
All of the functions support string and wstring. However, the EncryptionUtils have disabled the support for wstring as it is
API
struct ConversionUtils
{
string asciiFromWide(const wstring& src);
string utf8FromWide( const wstring& src);
wstring wideFromUtf8( const string& src);
wstring wideFromAscii(const string& src);
}
struct DateUtils
{
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T> ISO8601(const chrono::system_clock::time_point& rawtp = chrono::system_clock::now())
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T> RFC7231(const chrono::system_clock::time_point& rawtp = chrono::system_clock::now())
}
struct Base64Utils
{
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T> urlEscape(const basic_string<T>& src)
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T> encode(const basic_string<T>& argBin)
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T> decode(const basic_string<T>& argEncoded)
}
struct UrlUtils
{
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T> encode(const basic_string<T>& source, bool lowerCase = false)
}
struct EncryptionUtils
{
// Always returns a "binary" in std::string
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
string MD5(const basic_string<T>& source)
// Always returns a "binary" in std::string
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
string HMAC(const basic_string<T>& message,
const string& key) // "binary" or decoded
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T>
JWTHMAC256(const string& key, // "binary" or decoded
const basic_string<T>& header,
const basic_string<T>& payload)
// Returns tokens that can be used in the HTTP request header
// Note that the key is always in std::string since they are decoded from base64 values from the Azure portal.
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T> SASToken(const string& key, // "binary" or decoded
const basic_string<T>& url,
const basic_string<T>& keyName,
const chrono::seconds& timeout)
// Returns tokens that can be used in the HTTP request header
// Note that the key is always in std::string since they are decoded from base64 values from the Azure portal.
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T> SASToken(const string& key, // "binary" or decoded
const basic_string<T>& url,
const basic_string<T>& keyName,
const basic_string<T>& expiry)
// Returns tokens that can be used in the HTTP request header
// Note that the key is always in std::string since they are decoded from base64 values from the Azure portal.
template <typename T = char>
requires same_as<T, char> || same_as<T, wchar_t>
basic_string<T> CosmosToken(const string& key, // "binary" or decoded
const basic_string<T>& verb,
const basic_string<T>& type,
const basic_string<T>& resourceLink,
const basic_string<T>& date)
}
<p align="right"> © 2021 Siddiq Software LLC. All rights reserved. </p>
Product | Versions Compatible and additional computed target framework versions. |
---|---|
native | native is compatible. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
- SiddiqSoft.RunOnEnd (>= 1.2.0)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on SiddiqSoft.AzureCppUtils:
Package | Downloads |
---|---|
SiddiqSoft.restcl
Focussed REST Client for modern C++ |
|
SiddiqSoft.CosmosClient
Azure Cosmos REST-API Client for Modern C++ |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
1.5.6 | 125 | 10/26/2024 |
1.5.5 | 238 | 9/30/2024 |
1.5.4 | 106 | 9/28/2024 |
1.5.3 | 611 | 12/22/2021 |
1.5.2 | 424 | 12/20/2021 |
1.5.1 | 539 | 12/20/2021 |
1.5.0 | 6,046 | 12/16/2021 |
1.4.2 | 751 | 12/8/2021 |
1.4.1 | 2,920 | 11/20/2021 |
1.3.0 | 2,033 | 10/11/2021 |
1.2.9 | 593 | 9/3/2021 |
1.2.8 | 501 | 9/3/2021 |
1.2.7 | 518 | 9/2/2021 |
1.2.6 | 594 | 9/2/2021 |
1.2.5 | 542 | 9/2/2021 |
1.2.4 | 536 | 9/2/2021 |
1.2.3 | 444 | 9/2/2021 |
1.2.2 | 628 | 8/28/2021 |
1.2.1 | 580 | 8/27/2021 |
1.1.2 | 574 | 8/26/2021 |
1.1.1 | 583 | 8/24/2021 |
1.1.0 | 549 | 8/23/2021 |
1.0.2 | 564 | 8/22/2021 |
1.0.1 | 621 | 8/22/2021 |
1.0.0 | 4,507 | 8/22/2021 |