摘要:
namespace ConsoleApp5 { internal class Program { private static int index = 0; static void Main(string[] args) { Thread thread = new Thread(FuncThread 阅读全文
摘要:
C#官方源码参考 https://referencesource.microsoft.com/ C#官方源码参考 https://github.com/Unity-Technologies/UnityCsReference unity源码 阅读全文
摘要:
class Program { delegate void MyDelegate(string str); static void Main(string[] args) { //正常调用 MyDelegate myDelegate = new MyDelegate(CW); myDelegate( 阅读全文
摘要:
使用泛型可以定义接口,在接口中定义的方法可以带泛型参数。 《C#高级编程(第7版)》清华大学出版社 namespace Test { class Program { static void Main(string[] args) { TestClass testClass = new TestCla 阅读全文
摘要:
1. where T : struct 对于结构约束,类型T必须是值类型 2. where T : class 对于类约束,类型T必须是引用类型 3. where T : 接口名称IFoo 对于指定接口IFoo约束,类型T必须实现指定接口IFoo 4. where T : 类名Foo 对于指定类Fo 阅读全文
摘要:
Linux 命令 ls 查看当前文件夹下所有文件 Linux 命令 Tab 自动补全命令 阅读全文
摘要:
C#获取程序路径 string path1 = AppDomain.CurrentDomain.BaseDirectory; string path2 = Environment.CurrentDirectory; Console.WriteLine(path1); Console.WriteLin 阅读全文