public void DataUpdateWithParam(int code = 0, object param = null) { //线程安全处理 DataUpateHandlerWithParam localUpdatedWithParam = handlListWithParam; if (localUpdatedWithParam != null) { foreach (DataUpateHandlerWithParam handler in localUpdatedWithParam.GetInvocationList()) { //事件处理 handler(this, code, param); } } }
public void DataUpdateWithParam(int code = 0, object param = null) { DataUpateHandlerWithParam dataUpateHandlerWithParam = this.handlListWithParam; if (dataUpateHandlerWithParam != null) { Delegate[] invocationList = dataUpateHandlerWithParam.GetInvocationList(); for (int i = 0; i < invocationList.Length; i++) { DataUpateHandlerWithParam dataUpateHandlerWithParam2 = (DataUpateHandlerWithParam)invocationList[i]; dataUpateHandlerWithParam2(this, code, param); } } }