C# Класс StatePrinting.FieldHarvesters.ToStringAwareHarvester

Harvest all fields, public and private. Or use the ToString() if such is implemented on the class. We ignore the types from the following namespaces System.Reflection System.Runtime System.Func
Наследование: IFieldHarvester
Показать файл Открыть проект

Открытые методы

Метод Описание
CanHandleType ( Type type ) : bool
GetFields ( Type type ) : List

We ignore all properties as they, in the end, will only point to some computed state or other fields. Hence they do not provide information about the actual state of the object.

ToStringAwareHarvester ( ) : System

Приватные методы

Метод Описание
GetMethodInfo ( Type type ) : MethodInfo

This more thorough way to avoid the "Ambiguous match found" exception while retrieving the ToString method Explained here http://stackoverflow.com/questions/11443707/getproperty-reflection-results-in-ambiguous-match-found-on-new-property

Описание методов

CanHandleType() публичный Метод

public CanHandleType ( Type type ) : bool
type System.Type
Результат bool

GetFields() публичный Метод

We ignore all properties as they, in the end, will only point to some computed state or other fields. Hence they do not provide information about the actual state of the object.
public GetFields ( Type type ) : List
type System.Type
Результат List

ToStringAwareHarvester() публичный Метод

public ToStringAwareHarvester ( ) : System
Результат System