private void RequestElement(OperationAggregation.SyncElement element) { if (element.serviceID == null) { this.service.RequestOperation(element.serviceClass, element.syncOperation); return; } this.service.RequestOperation(element.serviceID.Value, element.syncOperation); }
public void AddElement(string serviceClass, int?serviceID, Operation syncOperation) { OperationAggregation.SyncElement newElement = new OperationAggregation.SyncElement(serviceClass, serviceID, syncOperation); this.operationCompleteStatus[newElement] = false; syncOperation.OnComplete += delegate(Operation op) { this.operationCompleteStatus[newElement] = true; this.CheckComplete(); }; syncOperation.OnFail += delegate(Operation op) { this.operationCompleteStatus[newElement] = true; this.result = false; this.CheckComplete(); }; }