private void BeginGetResponseCallback(IAsyncResult asyncResult)
        {
            WebResponse webResponse             = null;
            Stream      responseStream          = null;
            HttpWebRequestAsyncState asyncState = null;

            try
            {
                asyncState     = (HttpWebRequestAsyncState)asyncResult.AsyncState;
                webResponse    = asyncState.HttpWebRequest.EndGetResponse(asyncResult);
                responseStream = webResponse.GetResponseStream();
                var webRequestCallbackState = new HttpWebRequestCallbackState(responseStream, asyncState.State);
                asyncState.ResponseCallback(webRequestCallbackState);
                responseStream.Close();
                responseStream = null;
                webResponse.Close();
                webResponse = null;
            }
            catch (Exception ex)
            {
                if (asyncState != null)
                {
                    asyncState.ResponseCallback(new HttpWebRequestCallbackState(ex));
                }
                else
                {
                    throw;
                }
            }
            finally
            {
                if (responseStream != null)
                {
                    responseStream.Close();
                }
                if (webResponse != null)
                {
                    webResponse.Close();
                }
            }
        }
        public virtual void GetTokenResponseCallback(HttpWebRequestCallbackState state)
        {
            if (state.Exception != null)
            {
                if (m_requestCanceled && ((WebException)state.Exception).Status == WebExceptionStatus.RequestCanceled)
                {
                    return;
                }

                if (m_requestTimedOut)
                {
                    OnTimeout(state.Exception);
                }
                OnError(state.Exception);
            }

            OnResponseReceived(state.ResponseStream);

            //else
            //{
            //    var token = DeSerializeToJson<AdmAccessToken>(state.ResponseStream);
            //    OnTokenArrived(token);
            //}
        }