C#: How to create “aliases” for classes

前端 未结 7 1656
你的背包
你的背包 2020-12-17 18:43

I don\'t even know if it\'s called an alias, but let me continue anyway.

You know how the System.String type in C# is sorta \"aliased\" with \"string\"? In Visual S

7条回答
  •  佛祖请我去吃肉
    2020-12-17 19:25

    You create an alias using:

    using alias = LongClassName;
    

    That alias is visible in the namespace where you declared it.

提交回复
热议问题