C# Class ObjectPrinter.TypeInspectors.InspectAllTypeInspector

Inspects all Fields and Properties, and any method definitions when IncludeMethods is true.
Inheritance: ITypeInspector
Afficher le fichier Open project: drewburlingame/ObjectPrinter Class Usage Examples

Méthodes publiques

Méthode Description
GetMemberList ( object objectToInspect, Type typeOfObjectToInspect ) : IEnumerable

InspectAllTypeInspector ( ) : System

ShouldInspect ( object objectToInspect, Type typeOfObjectToInspect ) : bool

If ShouldInspect returns true, this type inspector will be used to inspect the type

Méthodes protégées

Méthode Description
ParseFieldInfo ( object objectToInspect, FieldInfo fieldInfo ) : object

returns fieldInfo.GetValue(objectToInspect)

ParseMethodInfo ( object objectToInspect, MethodInfo methodInfo ) : object

returns methodInfo.ToString()

ParsePropertyInfo ( object instance, PropertyInfo property ) : object

returns property.GetValue(instance, null)

ShouldEvaluate ( object instance, MemberInfo member ) : bool

If ShouldEvaluate returns true, the value will be evaluated for the member

ShouldInclude ( object instance, ObjectInfo info ) : bool

If ShouldInclude returns true (after member is evaluated), the member will be printed out

Private Methods

Méthode Description
ParseObjectValue ( Func func ) : object
ResetCache ( ) : void
ToObjectInfo ( object objectToInspect, MemberInfo memberInfo, object value ) : ObjectInfo

Method Details

GetMemberList() public méthode

public GetMemberList ( object objectToInspect, Type typeOfObjectToInspect ) : IEnumerable
objectToInspect object
typeOfObjectToInspect System.Type
Résultat IEnumerable

InspectAllTypeInspector() public méthode

public InspectAllTypeInspector ( ) : System
Résultat System

ParseFieldInfo() protected méthode

returns fieldInfo.GetValue(objectToInspect)
protected ParseFieldInfo ( object objectToInspect, FieldInfo fieldInfo ) : object
objectToInspect object
fieldInfo System.Reflection.FieldInfo
Résultat object

ParseMethodInfo() protected méthode

returns methodInfo.ToString()
protected ParseMethodInfo ( object objectToInspect, MethodInfo methodInfo ) : object
objectToInspect object
methodInfo System.Reflection.MethodInfo
Résultat object

ParsePropertyInfo() protected méthode

returns property.GetValue(instance, null)
protected ParsePropertyInfo ( object instance, PropertyInfo property ) : object
instance object
property System.Reflection.PropertyInfo
Résultat object

ShouldEvaluate() protected méthode

If ShouldEvaluate returns true, the value will be evaluated for the member
protected ShouldEvaluate ( object instance, MemberInfo member ) : bool
instance object
member System.Reflection.MemberInfo
Résultat bool

ShouldInclude() protected méthode

If ShouldInclude returns true (after member is evaluated), the member will be printed out
protected ShouldInclude ( object instance, ObjectInfo info ) : bool
instance object
info ObjectInfo
Résultat bool

ShouldInspect() public méthode

If ShouldInspect returns true, this type inspector will be used to inspect the type
public ShouldInspect ( object objectToInspect, Type typeOfObjectToInspect ) : bool
objectToInspect object
typeOfObjectToInspect System.Type
Résultat bool