/// <summary>
        /// 初始化 Web 请求开始事件的新实例。
        /// </summary>
        /// <param name="e">内部事件。</param>
        public WebRequestStartEventArgs(GameFramework.WebRequest.WebRequestStartEventArgs e)
        {
            WWWFormInfo wwwFormInfo = e.UserData as WWWFormInfo;

            SerialId      = e.SerialId;
            WebRequestUri = e.WebRequestUri;
            UserData      = wwwFormInfo.UserData;
        }
        /// <summary>
        /// 创建 Web 请求开始事件。
        /// </summary>
        /// <param name="e">内部事件。</param>
        /// <returns>创建的 Web 请求开始事件。</returns>
        public static WebRequestStartEventArgs Create(GameFramework.WebRequest.WebRequestStartEventArgs e)
        {
            WWWFormInfo wwwFormInfo = (WWWFormInfo)e.UserData;
            WebRequestStartEventArgs webRequestStartEventArgs = ReferencePool.Acquire <WebRequestStartEventArgs>();

            webRequestStartEventArgs.SerialId      = e.SerialId;
            webRequestStartEventArgs.WebRequestUri = e.WebRequestUri;
            webRequestStartEventArgs.UserData      = wwwFormInfo.UserData;
            return(webRequestStartEventArgs);
        }
Exemple #3
0
        /// <summary>
        /// 填充 Web 请求开始事件。
        /// </summary>
        /// <param name="e">内部事件。</param>
        /// <returns>Web 请求开始事件。</returns>
        public WebRequestStartEventArgs Fill(GameFramework.WebRequest.WebRequestStartEventArgs e)
        {
            WWWFormInfo wwwFormInfo = (WWWFormInfo)e.UserData;

            SerialId      = e.SerialId;
            WebRequestUri = e.WebRequestUri;
            UserData      = wwwFormInfo.UserData;

            return(this);
        }