CommonNetFuncs.Core
3.4.21
See the version list below for details.
dotnet add package CommonNetFuncs.Core --version 3.4.21
NuGet\Install-Package CommonNetFuncs.Core -Version 3.4.21
<PackageReference Include="CommonNetFuncs.Core" Version="3.4.21" />
<PackageVersion Include="CommonNetFuncs.Core" Version="3.4.21" />
<PackageReference Include="CommonNetFuncs.Core" />
paket add CommonNetFuncs.Core --version 3.4.21
#r "nuget: CommonNetFuncs.Core, 3.4.21"
#:package CommonNetFuncs.Core@3.4.21
#addin nuget:?package=CommonNetFuncs.Core&version=3.4.21
#tool nuget:?package=CommonNetFuncs.Core&version=3.4.21
CommonNetFuncs.Core
This lightweight project contains helper methods for several common functions required by applications.
Contents
- Async
- Collections
- Copy
- DateOnlyHelpers
- DateTimeHelpers
- DimensionScale
- ExceptionLocation
- FileHelpers
- Inspect
- MathHelpers
- Random
- RunBatches
- Streams
- Strings
- TypeChecks
- UnitConversion
Async
Helper methods for dealing with asynchronous processes. <details> <summary><h3>Usage Examples</h3></summary>
ObjectUpdate
Asynchronously update properties of a class using ObjectUpdate
//Fill the Name and Address property using async tasks
Person person = new();
//AsyncIntString helper class is used for int and string types since they can't otherwise be gotten asynchronously like this
AsyncIntString personPhotoLocation = new();
person.Id = 1;
List<Task> tasks =
[
person.ObjectUpdate(nameof(Person.Name), GetPersonNameByIdAsync(person.Id)), //Fills person.Name with results of GetPersonNameByIdAsync(person.Id)
person.ObjectUpdate(nameof(Person.Address), GetPersonAddressByIdAsync(person.Id)), //Fills person.Address with results of GetPersonAddressByIdAsync(person.Id)
personPhotoLocation.ObjectUpdate(nameof(AsyncIntString.AsyncString), GetPersonPhotoLocationById(person.Id)) //Fills personPhotoLocation.AsyncString with the results of GetPersonPhotoLocationById(person.Id)
]
await Task.WhenAll(tasks);
ObjectFill
Object fill can be used to asynchronously fill classes and lists with.
Person person = new();
ConcurrentBag<Person> people = [];
List<Task> tasks =
[
person.ObjectUpdate(GetPersonById(1)), //person is filled by results of GetPersonById(1) which returns type Person
//people is filled by the results of all three calls to GetPeopleByState additively (all results will be present in people)
people.ObjectUpdate(GetPeopleByState("Ohio")),
people.ObjectUpdate(GetPeopleByState("California")),
people.ObjectUpdate(GetPeopleByState("Texas"))
]
await Task.WhenAll(tasks);
</details>
Collections
Collections Usage Examples
Helper methods that work with collections such as IEnumerable, List, IDictionary, ConcurrentBag, and DataTable
<details> <summary><h3>Usage Examples</h3></summary>
AnyFast
Used to address issue CA1860 where it suggests using .Count for performance in an easier to type extension method
bool x = collection?.Any() == true;
//Or
collection?.Count > 0;
//Becomes
bool x = collection.AnyFast();
AddDictionaryItem & AddDictionaryItems
Used to directly TryAdd a KeyValuePair object(s) to a dictionary
KeyValuePair<string, string> JsonContentHeader = new("Content-Type", "application/json");
//Single addition
ConcurrentDictionary<string, string>? httpHeaders = [];
httpHeaders.AddDictionaryItem(JsonContentHeader);
//Add multiples
List<KeyValuePair<string, string>> keyValuePairs = [new("Accept-Encoding", "br"), new("Accept-Encoding", "gzip")];
httpHeaders.AddDictionaryItems(keyValuePairs);
AddRange & AddRangeParallel
[Description]
SetValue & SetValueParallel
[Description]
SelectNonEmpty
[Description]
SelectNonNull
[Description]
SingleToList
[Description]
GetObjectByPartial
[Description]
ToList
[Description]
ToListParallel
[Description]
ToDataTable
[Description]
ToDataTableReflection
[Description]
CombineExpressions
[Description]
StringAggProps
[Description]
IndexOf
[Description]
</details>
Copy
Copy Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
DateOnlyHelpers
DateHelpers Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
DateTimeHelpers
DateHelpers Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
DimensionScale
DimensionScale Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
ExceptionLocation
ExceptionLocation Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
FileHelpers
FileHelpers Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
Inspect
Inspect Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
MathHelpers
MathHelpers Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
Random
Random Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
RunBatches
RunBatches Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
Streams
Streams Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
Strings
Strings Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
TypeChecks
TypeChecks Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
</details>
UnitConversion
UnitConversion Usage Examples
[Description here]
<details> <summary><h3>Usage Examples</h3></summary>
[MethodNameHere]
//Code here
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net9.0 is compatible. 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. |
-
net9.0
- FastExpressionCompiler (>= 5.3.0)
NuGet packages (15)
Showing the top 5 NuGet packages that depend on CommonNetFuncs.Core:
| Package | Downloads |
|---|---|
|
CommonNetFuncs.Web.Aws.S3
Helper methods that deal with AWS S3 interactions |
|
|
CommonNetFuncs.EFCore
Helper methods that deal with EFCore, including providing basic actions against a DB Context and handling navigation properties. |
|
|
CommonNetFuncs.Web.Requests
Helper methods that deal with creating, sending, and handling the responses from REST API calls |
|
|
CommonNetFuncs.Web.Api
Generic API endpoints for use in an ASP.NET API |
|
|
CommonNetFuncs.Sql.Common
Helper methods that deal with preparing and executing queries. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated | |
|---|---|---|---|
| 4.0.2 | 830 | 12/2/2025 | |
| 4.0.1 | 303 | 11/27/2025 | |
| 4.0.0 | 355 | 11/23/2025 | |
| 3.8.20 | 871 | 12/1/2025 | |
| 3.8.19 | 477 | 11/21/2025 | |
| 3.8.18 | 656 | 11/20/2025 | |
| 3.8.16 | 655 | 11/17/2025 | |
| 3.8.13 | 549 | 11/10/2025 | |
| 3.8.12 | 193 | 11/6/2025 | |
| 3.8.11 | 209 | 11/5/2025 | |
| 3.8.4 | 633 | 10/9/2025 | |
| 3.7.18 | 1,144 | 9/15/2025 | |
| 3.7.17 | 405 | 9/11/2025 | |
| 3.7.13 | 462 | 9/8/2025 | |
| 3.7.0 | 803 | 8/18/2025 | |
| 3.6.27 | 366 | 8/18/2025 | |
| 3.6.26 | 387 | 8/14/2025 | |
| 3.6.25 | 409 | 8/13/2025 | |
| 3.6.24 | 387 | 8/12/2025 | |
| 3.6.19 | 469 | 7/28/2025 | |
| 3.6.18 | 508 | 7/25/2025 | |
| 3.6.6 | 863 | 7/21/2025 | |
| 3.6.1 | 437 | 7/14/2025 | |
| 3.6.0 | 323 | 7/11/2025 | |
| 3.5.3 | 343 | 7/10/2025 | |
| 3.5.2 | 200 | 7/9/2025 | |
| 3.5.1 | 175 | 7/8/2025 | |
| 3.5.0 | 402 | 7/7/2025 | |
| 3.4.30 | 175 | 7/7/2025 | |
| 3.4.23 | 385 | 6/26/2025 | |
| 3.4.21 | 291 | 6/26/2025 | |
| 3.4.20 | 351 | 6/25/2025 | |
| 3.4.18 | 369 | 6/23/2025 | |
| 3.4.17 | 209 | 6/19/2025 | |
| 3.4.14 | 318 | 6/17/2025 | |
| 3.4.13 | 310 | 6/13/2025 | |
| 3.4.12 | 336 | 6/12/2025 | |
| 3.4.11 | 335 | 6/12/2025 | |
| 3.4.10 | 328 | 6/11/2025 | |
| 3.4.9 | 489 | 6/11/2025 | |
| 3.4.8 | 503 | 6/11/2025 | |
| 3.4.5 | 351 | 6/9/2025 | |
| 3.4.2 | 478 | 6/2/2025 | |
| 3.4.1 | 391 | 5/30/2025 | |
| 3.4.0 | 455 | 5/30/2025 | |
| 3.3.16 | 205 | 5/28/2025 | |
| 3.3.12 | 302 | 5/19/2025 | |
| 3.3.11 | 440 | 5/18/2025 | |
| 3.3.10 | 532 | 5/13/2025 | |
| 3.3.8 | 283 | 5/13/2025 | |
| 3.3.7 | 277 | 5/12/2025 | |
| 3.3.3 | 222 | 4/30/2025 | |
| 3.3.0 | 511 | 4/29/2025 | |
| 3.2.36 | 264 | 4/15/2025 | |
| 3.2.35 | 260 | 4/14/2025 | |
| 3.2.33 | 282 | 4/14/2025 | |
| 3.2.32 | 243 | 4/14/2025 | |
| 3.2.31 | 170 | 4/11/2025 | |
| 3.2.30 | 162 | 4/11/2025 | |
| 3.2.29 | 149 | 4/11/2025 | |
| 3.2.25 | 384 | 4/7/2025 | |
| 3.2.24 | 186 | 4/1/2025 | |
| 3.2.22 | 451 | 3/12/2025 | |
| 3.2.19 | 269 | 2/28/2025 | |
| 3.2.18 | 146 | 2/28/2025 | |
| 3.2.17 | 225 | 2/26/2025 | |
| 3.2.14 | 318 | 2/20/2025 | |
| 3.2.13 | 531 | 2/13/2025 | |
| 3.2.9 | 399 | 2/4/2025 | |
| 3.2.8 | 207 | 1/31/2025 | |
| 3.2.6 | 266 | 1/28/2025 | |
| 3.2.5 | 174 | 1/27/2025 | |
| 3.2.3 | 276 | 1/17/2025 | |
| 3.2.1 | 218 | 1/7/2025 | |
| 3.2.0 | 438 | 12/19/2024 | |
| 3.1.5 | 194 | 12/16/2024 | |
| 3.1.2 | 256 | 12/13/2024 | |
| 3.1.0 | 507 | 12/6/2024 | |
| 3.0.0 | 401 | 12/3/2024 | |
| 2.1.3 | 443 | 12/3/2024 | |
| 2.1.0 | 406 | 12/2/2024 | |
| 2.0.5 | 380 | 11/26/2024 | |
| 2.0.3 | 157 | 11/20/2024 | |
| 2.0.2 | 462 | 11/18/2024 | |
| 2.0.1 | 362 | 11/15/2024 | |
| 2.0.0 | 398 | 11/14/2024 | |
| 1.0.47 | 443 | 11/14/2024 | |
| 1.0.42 | 503 | 11/12/2024 | |
| 1.0.40 | 539 | 11/12/2024 | |
| 1.0.37 | 559 | 11/4/2024 | |
| 1.0.31 | 481 | 10/31/2024 | |
| 1.0.28 | 529 | 10/25/2024 | |
| 1.0.26 | 498 | 10/18/2024 | |
| 1.0.25 | 416 | 10/17/2024 | |
| 1.0.24 | 376 | 10/17/2024 | |
| 1.0.19 | 505 | 10/11/2024 | |
| 1.0.17 | 712 | 9/27/2024 | |
| 1.0.16 | 434 | 9/27/2024 | |
| 1.0.14 | 458 | 9/23/2024 | |
| 1.0.13 | 477 | 9/18/2024 | |
| 1.0.12 | 652 | 9/18/2024 | |
| 1.0.10 | 507 | 9/11/2024 | |
| 1.0.9 | 512 | 9/11/2024 | |
| 1.0.8 | 562 | 9/11/2024 | |
| 1.0.7 | 580 | 9/11/2024 | |
| 1.0.6 | 211 | 9/9/2024 | |
| 1.0.5 | 221 | 9/5/2024 | |
| 1.0.4 | 195 | 9/5/2024 | |
| 1.0.3 | 186 | 9/4/2024 | |
| 1.0.2 | 191 | 9/4/2024 | |
| 1.0.1 | 549 | 9/4/2024 | |
| 1.0.0 | 561 | 9/2/2024 |