Ejemplo n.º 1
0
        /// <summary>
        /// 给出某种时间片的处理信息
        /// </summary>
        /// <returns></returns>
        /// <param name="name"></param>
        public static TimerProfile GetProfile(string name)
        {
            if (string.IsNullOrEmpty(name))
            {
                name = "null";
            }

            TimerProfile timerProfile;

            s_Profiles.TryGetValue(name, out timerProfile);
            if (timerProfile == null)
            {
                timerProfile = new TimerProfile();
                s_Profiles.Add(name, timerProfile);
            }

            return(timerProfile);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 给出某种时间片的处理信息
        /// </summary>
        /// <returns></returns>
        /// <param name="name"></param>
        public static TimerProfile GetProfile(string name)
        {
            if (string.IsNullOrEmpty(name))
                name = "null";

            TimerProfile timerProfile;
            s_Profiles.TryGetValue(name, out timerProfile);
            if (timerProfile == null)
            {
                timerProfile = new TimerProfile();
                s_Profiles.Add(name, timerProfile);
            }

            return timerProfile;
        }