public PropertyCache(PropertyInfo property) { Property = property; getValue = new Lazy <Func <object, object> >(() => ReflectionExtensions.CreateGetValue(Property)); setValue = new Lazy <Action <object, object> >(() => ReflectionExtensions.CreateSetValue(Property, Property.PropertyType)); }
public FieldCache(FieldInfo field) { Field = field; getValue = new Lazy <Func <object, object> >(() => ReflectionExtensions.CreateGetValue(Field)); setValue = new Lazy <Action <object, object> >(() => ReflectionExtensions.CreateSetValue(Field, Field.FieldType)); }