摘要:
Toast var t = Windows.UI.Notifications.ToastTemplateType.ToastText02; //在模板添加xml要的标题 var content = Windows.UI.Notifications.ToastNotificationManager.G 阅读全文
摘要:
emaphore是System.Threading下的类,限制可同时访问某一资源或资源池的线程数。 常用构造方法 https://msdn.microsoft.com/zh-cn/library/e1hct27h(v=vs.110).aspx public Semaphore( int initia 阅读全文
摘要:
public class SharedData { public int Value { get; set; } } public class Test { async Task ModifyValueAsync(SharedData data) { Console.WriteLine("pre v 阅读全文
摘要:
要理解 C# 中的 volatile 关键字,就要先知道编译器背后的一个基本优化原理。比如对于下面这段代码: public class Example { public int x; public void DoWork() { x = 5; var y = x + 10; Debug.WriteL 阅读全文