PropertyAccessor

public sealed class PropertyAccessor
Access public properties of a specific type instance.

Constructors

PropertyAccessor

#
public PropertyAccessor(object instance, Func<PropertyInfo, bool> filter)
Load all public get/set properties of an instance that pass a filter.
instance (object)Instance to reflect.
filter (Func<PropertyInfo, bool>)Filter method.

PropertyAccessor

#
public PropertyAccessor(object instance, params Type[] allowedTypes)
Load all public get/set properties of an instance that wrap a specific set of types.
instance (object)Instance to reflect.
allowedTypes (params Type[])Collection of allowed types.

PropertyAccessor

#
public PropertyAccessor(object instance)
Load all public get/set properties of an instance.
instance (object)Instance to reflect.

Properties

Count

#
public int Count { get; }
Gets the number of associated properties.

Instance

#
public object Instance { get; }
Gets the instance this accessor is associated with.

Properties

#
public IEnumerable<TypeProperty> Properties { get; }
Enumerate over all properties.

Indexers

this[]

#
public TypeProperty this[int index] { get; }
Gets the type property at the given index.
index (int)Index of property to retrieve.