SiddiqSoft.AzureCppUtils
1.2.2
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.2
NuGet\Install-Package SiddiqSoft.AzureCppUtils -Version 1.2.2
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.2" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="SiddiqSoft.AzureCppUtils" Version="1.2.2" />
<PackageReference Include="SiddiqSoft.AzureCppUtils" />
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add SiddiqSoft.AzureCppUtils --version 1.2.2
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: SiddiqSoft.AzureCppUtils, 1.2.2"
#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.
#addin nuget:?package=SiddiqSoft.AzureCppUtils&version=1.2.2
#tool nuget:?package=SiddiqSoft.AzureCppUtils&version=1.2.2
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 |
---|---|---|
3.0.1 | 125 | 12/22/2024 |
3.0.0 | 100 | 12/22/2024 |
2.0.1 | 231 | 12/12/2024 |
2.0.0 | 126 | 12/12/2024 |
1.6.7 | 115 | 12/7/2024 |
1.6.6 | 120 | 12/6/2024 |
1.6.5.1 | 116 | 12/4/2024 |
1.6.3.1 | 107 | 12/4/2024 |
1.6.2 | 106 | 12/4/2024 |
1.6.1.1 | 106 | 12/4/2024 |
1.5.6 | 169 | 10/26/2024 |
1.5.5 | 264 | 9/30/2024 |
1.5.4 | 127 | 9/28/2024 |
1.5.3 | 662 | 12/22/2021 |
1.5.2 | 473 | 12/20/2021 |
1.5.1 | 588 | 12/20/2021 |
1.5.0 | 6,184 | 12/16/2021 |
1.4.2 | 800 | 12/8/2021 |
1.4.1 | 2,971 | 11/20/2021 |
1.3.0 | 2,087 | 10/11/2021 |
1.2.9 | 641 | 9/3/2021 |
1.2.8 | 553 | 9/3/2021 |
1.2.7 | 566 | 9/2/2021 |
1.2.6 | 642 | 9/2/2021 |
1.2.5 | 592 | 9/2/2021 |
1.2.4 | 584 | 9/2/2021 |
1.2.3 | 492 | 9/2/2021 |
1.2.2 | 676 | 8/28/2021 |
1.2.1 | 632 | 8/27/2021 |
1.1.2 | 622 | 8/26/2021 |
1.1.1 | 635 | 8/24/2021 |
1.1.0 | 597 | 8/23/2021 |
1.0.2 | 614 | 8/22/2021 |
1.0.1 | 673 | 8/22/2021 |
1.0.0 | 4,556 | 8/22/2021 |