DaanV2.UUID.Net 1.0.3

.NET Core 3.1 .NET Standard 2.0 .NET Framework 4.8
There is a newer version of this package available.
See the version list below for details.
NuGet\Install-Package DaanV2.UUID.Net -Version 1.0.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.
dotnet add package DaanV2.UUID.Net --version 1.0.3
<PackageReference Include="DaanV2.UUID.Net" Version="1.0.3" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add DaanV2.UUID.Net --version 1.0.3
#r "nuget: DaanV2.UUID.Net, 1.0.3"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install DaanV2.UUID.Net as a Cake Addin
#addin nuget:?package=DaanV2.UUID.Net&version=1.0.3

// Install DaanV2.UUID.Net as a Cake Tool
#tool nuget:?package=DaanV2.UUID.Net&version=1.0.3

UUID.Net

Provides a base class that can handle UUIDs as an object but also provides the generators to generate version 3, 4 and 5.

Table of Contents

Implicit Casting

This API contains pre-made casting methods that convert UUID to strings, char arrays or vice versa.

Usage Example

Below are two examples of generating UUIDs and usage

Generating UUIDs

Generate a UUID
UUID Temp = UUIDFactory.CreateUUID(4, 2); //Version 4, Variant 2
String UUID = UUIDFactory.CreateUUID(3, 1); //Version 3, Variant 1. auto cast to string
Generate a batch of UUIDs
UUID[] UUIDs = UUIDFactory.CreateUUIDs(100000, 4, 1); //Version 4, Variant 1, Amount of 100000
Generating through a Generator
IUUIDGenerator Generator = UUIDFactory.CreateGenerator(4, 1); //Get the version 4, variant 1 generator
IUUIDGenerator GeneratorV4 = new DaanV2.UUID.Generators.Version4.GeneratorVariant1(); //Get the version 4, variant 1 generator

UUID Out = GeneratorV4.Generate();

UUIDs Version

Version Variant Description Context Needed Context Type
3 1 A UUID generated from a string using MD5 hashing bits, 122 bits Yes String
4 1 A random generated UUID of 122 bits No Int32
4 2 A random generated UUID of 121 bits No Int32
5 1 A UUID generated from a string using SHA1 hashing bits, 122 bits Yes String

Performance

See Performance

Product Versions
.NET net5.0 net5.0-windows net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows
.NET Core netcoreapp2.0 netcoreapp2.1 netcoreapp2.2 netcoreapp3.0 netcoreapp3.1
.NET Standard netstandard2.0 netstandard2.1
.NET Framework net461 net462 net463 net47 net471 net472 net48
MonoAndroid monoandroid
MonoMac monomac
MonoTouch monotouch
Tizen tizen40 tizen60
Xamarin.iOS xamarinios
Xamarin.Mac xamarinmac
Xamarin.TVOS xamarintvos
Xamarin.WatchOS xamarinwatchos
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.
  • .NETCoreApp 3.1

    • No dependencies.
  • .NETFramework 4.8

    • No dependencies.
  • .NETStandard 2.0

    • No dependencies.
  • .NETStandard 2.1

    • No dependencies.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on DaanV2.UUID.Net:

Package Downloads
MiniJoyApp

Package Description

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.1.0 4,899 12/13/2020
1.0.4 1,183 9/3/2020
1.0.3 546 4/7/2020
1.0.2 408 3/1/2020
1.0.1 539 1/25/2020
1.0.0 537 12/31/2019

Added implicit guid casting