/// <summary> /// 获取当前可用的异步触发器,提供触发类型 /// </summary> /// <param name="ud"></param> /// <returns></returns> public static UserDelegateTriggle GetTriggle(UserDelegateFun ud, params object[] args) { UserDelegateTriggle triggle; if (mTrigglePools.Count > 0) { triggle = mTrigglePools.Dequeue(); triggle.SetDelegateFun(ud); triggle.SetContext(args); } else { triggle = new UserDelegateTriggle(); triggle.SetDelegateFun(ud); triggle.SetContext(args); } return(triggle); }
/// <summary> /// 清空触发器的所有信息 /// </summary> public void Clear() { mactionud = null; mactionud = null; mTriggleLinker = null; }
public void SetDelegateFun(UserDelegateFun ud) { mactionud = ud; }