getInvoke method
获取指定 propertyKey
对应异步请求属性的请求发起方法
propertyKey
对应属性必须为 AsyncBindableProperty 否则返回 null
resetOnBefore
指定发起请求之前是否重置属性值
当其值为 true
时, 发起请求之前属性值将先被重置为 AsyncSnapshot<TValue>.nothing()
调用其返回的方法将发起异步请求
Implementation
void Function()? getInvoke(Object propertyKey, {bool resetOnBefore = true}) {
var property = getPropertyOf<dynamic, AsyncBindableProperty>(propertyKey);
return property != null
? () => property.invoke(resetOnBefore: resetOnBefore)
: null;
}