解决MySql布尔型新旧版本兼容问题,采用枚举来表示布尔型的数据表。由正向工程赋值
大石头 authored at 2018-05-15 21:21:05
492.00 B
X
using System;
using System.Collections.Generic;

#if NET4
namespace System.Threading
{
	internal static class TimerManager
	{
		private static Dictionary<Timer, object> s_rootedTimers = new Dictionary<Timer, object>();

		public static void Add(Timer timer)
		{
			lock (s_rootedTimers)
			{
                s_rootedTimers.Add(timer, null);
			}
		}

		public static void Remove(Timer timer)
		{
			lock (s_rootedTimers)
			{
                s_rootedTimers.Remove(timer);
			}
		}
	}
}
#endif