摘要:
public static void Main() { // Create a Timer object that knows to call our TimerCallback // method once every 2000 milliseconds. Timer t = new Timer(TimerCallback, null, 0, 2000); // Wait for the user to hit <Enter> Console.ReadLine(); } private static void TimerCallback(Object o) { // Displa 阅读全文
posted @ 2012-05-31 18:57
狩猪逮兔
阅读(220)
评论(0)
推荐(0)
摘要:
private static void Demo1() { try { Console.WriteLine("In try"); } finally { // Type1!ˉs static constructor is implicitly called in her Type1.M(); } } private sealed class Type1 { static Type1() { // if this throws an exception, M won!ˉt get calle Console.WriteLine("Type1's static 阅读全文
posted @ 2012-05-31 16:01
狩猪逮兔
阅读(425)
评论(0)
推荐(0)