private void HandleOnStatus(object sender, GenericArgs <StreamStatus> e) { var session = (StreamSession <StreamResponse>)sender; OnStatus?.Invoke(this, new StatusArgs(session.Kind, e.Data)); if (e.Data == StreamStatus.WebError) { OnWebError?.Invoke(this, new WebErrorArgs(session.Kind, session.ErrorStatus.Value, session.ErrorMessage)); } }
public void Request(uint id, OnWebResponse onResponse, OnWebError onError) { UWebRequest request = GetRequest(id); if (request != null) { m_CustomArgs.Merge(request.args); routine.Post(request, m_CustomArgs, onResponse, onError, m_TimeOutInterval); } m_CustomArgs.Clear(); }
public void RequestByWRI(EWebRequestId id, OnWebResponse onResponse, OnWebError onError) { Request((uint)id, onResponse, onError); }