C# 클래스 Neddle.Extensions.ObjectExtensions

Contains object extension methods.
파일 보기 프로젝트 열기: kcargile/neddle

공개 메소드들

메소드 설명
CalculateHash ( this obj ) : int

Calculates a hash for the object using reflection.

NullSafeEquals ( this obj1, object obj2 ) : bool

Determines if the two objects are equivalent in a way that will not throw if the current object is null.

NullSafeHash ( this obj, int seed ) : int

Calculates a hash for the object in a way that will not throw or influence the value if the current object is null.

메소드 상세

CalculateHash() 공개 정적인 메소드

Calculates a hash for the object using reflection.
public static CalculateHash ( this obj ) : int
obj this The object.
리턴 int

NullSafeEquals() 공개 정적인 메소드

Determines if the two objects are equivalent in a way that will not throw if the current object is null.
public static NullSafeEquals ( this obj1, object obj2 ) : bool
obj1 this The current object.
obj2 object The object to compare.
리턴 bool

NullSafeHash() 공개 정적인 메소드

Calculates a hash for the object in a way that will not throw or influence the value if the current object is null.
public static NullSafeHash ( this obj, int seed ) : int
obj this The object.
seed int The seed.
리턴 int