| Clean Architecture Toolkit for .NET | |||||
|
Clean Architecture Toolkit is a clean, modular architecture foundation for .NET applications. It embraces SOLID principles and focuses on maintainability, testability, and scalability through clear boundaries and pluggable design. |
|
||||
|
| HOME | MODULE OVERVIEW | DEMO | CAT.EXTENSIONS | |
|||||
Code Reference
» Cat.Object.Extensions Assembly » Cat.Object.Extensions Namespace » ObjectExtensions Class
ObjectExtensions.CompareDefault<T>(T, T) Method
Compares two values using T’s default comparison.
private static int CompareDefault<T>(T value, T other);
Type parameters
T
The type being compared. Must implement System.IComparable<>.
Parameters
value T
The value to compare.
other T
The value to compare with.
Returns
System.Int32
A negative number when value is lower, zero when they are equal, a positive number when it is higher.
Exceptions
System.ArgumentException
Thrown when T doesn’t implement System.IComparable<>.