internal EventRootResponse(HttpResponseMessage httpResponse, ValueRootAddedEventHandler <T> added, IRequestManager requestManager, string path) { _added = added; _requestManager = requestManager; _path = path; _cancel = new CancellationTokenSource(); _pollingTask = ReadLoop(httpResponse, _cancel.Token); }
public async Task <EventRootResponse <T> > OnChangeGetAsync <T>(string path, ValueRootAddedEventHandler <T> added = null) { return(new EventRootResponse <T>(await _requestManager.ListenAsync(path).ConfigureAwait(false), added, _requestManager, path)); }
public Task <EventRootResponse <T> > OnChange <T>(string path, ValueRootAddedEventHandler <T> added = null) { return(_firebaseClient.OnChangeGetAsync(path, added)); }