Using alias directives C# with Example



Using alias directives C# with Example

You can use using in order to set an alias for a namespace or type. More detail can be found in here. 
Syntax: 
using  = ; 
Example: 
using NewType = Dictionary>; 
NewType multiDictionary = new NewType(); 
//Use instances as you are using the original one 
multiDictionary.Add("test", new Dictionary()); 

0 Comment's

Comment Form

Submit Comment