SetterDelegate CreatePropertySetter(Type type, PropertyInfo property)
        {
            var setter = property.GetSetMethod();

            if (setter != null)
            {
                return(DynamicCode.CreateSetter(type, property));
            }
            return(null);
        }
 private GetterDelegate CreateGetter(Type type, PropertyInfo property)
 {
     return(DynamicCode.CreateGetter(type, property));
 }
 private GetterDelegate CreateGetter(Type type, FieldInfo field)
 {
     return(DynamicCode.CreateGetter(type, field));
 }