DeafMan1983.Utilities 1.2.0

dotnet add package DeafMan1983.Utilities --version 1.2.0
NuGet\Install-Package DeafMan1983.Utilities -Version 1.2.0
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="DeafMan1983.Utilities" Version="1.2.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add DeafMan1983.Utilities --version 1.2.0
#r "nuget: DeafMan1983.Utilities, 1.2.0"
#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 DeafMan1983.Utilities as a Cake Addin
#addin nuget:?package=DeafMan1983.Utilities&version=1.2.0

// Install DeafMan1983.Utilities as a Cake Tool
#tool nuget:?package=DeafMan1983.Utilities&version=1.2.0

DeafMan1983.Utilities (formely DeafMan1983.Conversions)

For char[], char*, char[][], char*[], char** and 2 length of sbyte* and sbyte** are for only charX and charXX. I would like to show how do you write easy with similar functions: char[] StringToCharArray(string str) and string CharArrayToString(char[] ary)

Example:

char[] charAry = StringToCharArray("Hello World!");
Console.WriteLine($"Result: {CharArrayToString(charAry)}.");
Console.WriteLine($"Length of char[]: {charAry.Length}.");

Result:

Result: Hello World!
Length of char[] 12

char* StringToCharPointer(string str), string CharPointerToString(char* ptr) and int CharPointerLength(char* ptr)

Example:

char* charPtr = StringToCharPointer("Hello World!");
Console.WriteLine($"Result: {CharPointerToString(charPtr)}");
Console.WriteLine($"Length of char*: {CharPointerLength(charPtr)}");

Result:

Result: Hello World!
Length of char* 12

char** StringArrayToCharDoublePointer(string[] arys) and string[] CharDoublePointerToStringArray(char** dblPtr)<br>

[!WARNING] Please do not forget to advanced solution!

You should to add - 1 instead strArys.Length and do not use int CharDoublePointerLength(char** dblPtr) because dotnet 8 will crash. That is why you need to follow my code.

Example:

string[] strArys = new string[]
{
  "Hello", "How are you?", "I'm fine.", string.Empty // <-- Add empty string.
}
char** charDblPtrs = StringArrayToCharDoublePointer(strings);
for (int i = 0; i < strArys.Length - 1; i++) // Need - 1
{
  charDblPtrs[i] = StringToCharPointer(strArys[i]);
  Console.WriteLine($"{strArys[i]}");
}
charDblPtrs[strings.Length - 1] = null; // <- Need fix null
int aryLenCharDblPtrs = CharDoublePointerLength(charDblPtrs);
Console.WriteLine($"Array's length of char**: {aryLenCharDblPtrs} ");

Result:

Hello
How are you?
I'm fine.
Array's length of char**: 3

And more I will release soon, if I already release UtilitiesForBinary for 01010101.

See you more examples from CodeProject Link And Github with TerraFX.Interop.Windows Link

Spending actions:

For PayPal: NO, Skrill NO, Payee NO

Wise Yes jenspetereckervogt@gmail.com ( PLEASE USE ONLY EUR ) Thanks!

If you use Crypto coins than you make sure screenshot to send me email jenspetereckervogt@gmail.com because It is proof cause balance happens from nothing. That is why I need to get proof this. Make sure ( USD, EUR, GBP, CHF, PHP or other. ) Note: Don't support Australia, New Zeeland, Russia and Nigeria - Sorry!

TRX:: TYnSLrEKJhrgZF3ztC4VWGvEFnoGRchHvD ( Make sure Tron Network )

BTC: 1LrFQkEBCJ75v4qRWmWyaPFmv3jMC6FAZY

MATIC: 0x6aeac3891528e7e051d89d44e52b82cbe719d0ec ( Make sure Polygon Network )

LTC: LPN9WNL5qc6va1okZq6vtmJCHVV3kHzgCw

Thank you for spending and supporting me!

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net8.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.2.0 79 6/5/2024
1.1.0 70 6/4/2024
1.0.0 83 5/20/2024