C# 클래스 Prototype.Tests.ObjectComparer

Originally from: http://cyotek.com/article/display/comparing-the-properties-of-two-objects-via-reflection
파일 보기 프로젝트 열기: paralect/prototype

공개 메소드들

메소드 설명
AreObjectsEqual ( object objectA, object objectB, IgnoreList ignoreList = null ) : bool

Compares the properties of two objects of the same type and returns if all properties are equal.

비공개 메소드들

메소드 설명
AreValuesEqual ( object valueA, object valueB ) : bool

Compares two values and returns if they are the same.

CanDirectlyCompare ( Type type ) : bool

Determines whether value instances of the specified type can be directly compared.

IsPresentInIgnoreList ( IgnoreList ignoreList, Type type, PropertyInfo propertyInfo ) : bool

메소드 상세

AreObjectsEqual() 공개 정적인 메소드

Compares the properties of two objects of the same type and returns if all properties are equal.
public static AreObjectsEqual ( object objectA, object objectB, IgnoreList ignoreList = null ) : bool
objectA object The first object to compare.
objectB object The second object to compre.
ignoreList IgnoreList A Dictionary to ignore from the comparison where keys is type and vae is list of property names
리턴 bool