C# 클래스 FluentValidation.Internal.Comparer

Custom logic for performing comparisons
파일 보기 프로젝트 열기: JeremySkinner/FluentValidation

공개 메소드들

메소드 설명
GetComparisonResult ( IComparable value, IComparable valueToCompare ) : int

Tries to compare the two objects, but will throw an exception if it fails.

GetEqualsResult ( IComparable value, IComparable valueToCompare ) : bool

Tries to compare the two objects, but will throw an exception if it fails.

TryCompare ( IComparable value, IComparable valueToCompare, int &result ) : bool

Tries to compare the two objects.

비공개 메소드들

메소드 설명
Compare ( IComparable value, IComparable valueToCompare, int &result ) : void

Tries to do a proper comparison but may fail. First it tries the default comparison, if this fails, it will see if the values are fractions. If they are, then it does a double comparison, otherwise it does a long comparison.

메소드 상세

GetComparisonResult() 공개 정적인 메소드

Tries to compare the two objects, but will throw an exception if it fails.
public static GetComparisonResult ( IComparable value, IComparable valueToCompare ) : int
value IComparable
valueToCompare IComparable
리턴 int

GetEqualsResult() 공개 정적인 메소드

Tries to compare the two objects, but will throw an exception if it fails.
public static GetEqualsResult ( IComparable value, IComparable valueToCompare ) : bool
value IComparable
valueToCompare IComparable
리턴 bool

TryCompare() 공개 정적인 메소드

Tries to compare the two objects.
public static TryCompare ( IComparable value, IComparable valueToCompare, int &result ) : bool
value IComparable
valueToCompare IComparable
result int The resulting comparison value.
리턴 bool