TrishkaV.TypeDetect
1.0.1
dotnet add package TrishkaV.TypeDetect --version 1.0.1
NuGet\Install-Package TrishkaV.TypeDetect -Version 1.0.1
<PackageReference Include="TrishkaV.TypeDetect" Version="1.0.1" />
<PackageVersion Include="TrishkaV.TypeDetect" Version="1.0.1" />
<PackageReference Include="TrishkaV.TypeDetect" />
paket add TrishkaV.TypeDetect --version 1.0.1
#r "nuget: TrishkaV.TypeDetect, 1.0.1"
#:package TrishkaV.TypeDetect@1.0.1
#addin nuget:?package=TrishkaV.TypeDetect&version=1.0.1
#tool nuget:?package=TrishkaV.TypeDetect&version=1.0.1
TypeDetect
Library: Lightweight C# language extension to assess objects types, including nullables and objects mapped from database readers.
What to expect: this library provides a series of methods that allow to detect the underlying type of an object, including if this is a nullable (it's value can be null) or if is a null as returned by a database reader (DBNull).
add "using TypeDetect;" to enable the language extension and call the type detection methods on all objects.
Examples: ".IsDateTime()" returns true if the object is a datetime and false otherwise. ".IsDateTimeNullable()" returns true if the object is a datetime OR null, and false otherwise.
".IsNumeric()" returns true if the object is "int", "short", "double", ... ".IsNumericNullable()" as before, including null values.
".IsText()" returns true for strings and chars. ".IsTextNullable()" as before, including null values.
NOTE Legally this comes with no warranty and you are using it at your own risk.
This library have been tested agaist real database extractions and objects of all the mentioned types its results hold correct.
If you find an issue with the results or implementation or an optimization could be made please feel free to contact me or issue a pull request. You will be credited for any contribution.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. 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. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net6.0
- No dependencies.
NuGet packages (1)
Showing the top 1 NuGet packages that depend on TrishkaV.TypeDetect:
Package | Downloads |
---|---|
TrishkaV.EntityScribe
Lightweight C# language extension to map objects and type from database reader executions, memory allocation is optimized for performance. Open source project at github.com/TrishkaV/EntityScribe |
GitHub repositories
This package is not used by any popular GitHub repositories.