public void SubscribeValueChanged() { ICalcServiceEvents subscriber = OperationContext.Current.GetCallbackChannel <ICalcServiceEvents>(); m_Event3 += subscriber.ValueChanged; }
public void SubscribeCalculationFinishedEvent() { ICalcServiceEvents subscriber = OperationContext.Current.GetCallbackChannel <ICalcServiceEvents>(); m_Event2 += subscriber.CalculationFinished; }
//[WebInvoke(Method = "GET", // ResponseFormat = WebMessageFormat.Json, // UriTemplate = "data/{id}")] //public Person GetData(string id) //{ // return new Person() // { // id = Convert.ToInt32(id), // name = "wocao" // }; //} public void SubscribeSentEvent() { ICalcServiceEvents subscriber = OperationContext.Current.GetCallbackChannel <ICalcServiceEvents>(); m_Event1 += subscriber.Sent; }
public void SubscribeUpdateFinishedEvent() { ICalcServiceEvents subscriber = OperationContext.Current.GetCallbackChannel <ICalcServiceEvents>(); eventUpdate += subscriber.UpdateFinished; }
public void SubscribeDecrEvent() { ICalcServiceEvents subscriber = OperationContext.Current.GetCallbackChannel <ICalcServiceEvents>(); eventDecr += subscriber.DecrOp; }