public T GetMsg <T>() where T : XMessage, new() { var obj = XObjectPool.Alloc <T>(); obj.SetName(typeof(T).Name); return(obj); }
protected void _AddRequest(UnityWebRequest webRequest, string encrypt, Action <string, string> strResponse, Action <string, byte[]> binResponse, Action <float> onProgress) { var request = XObjectPool.Alloc <XWebRequest>(); request.async = webRequest.SendWebRequest(); request.encrypt = encrypt; request.strResponse = strResponse; request.binResponse = binResponse; request.onProgress = onProgress; m_requests.Add(request); }