Write a fast 5 years of code, has been the use of other people invented the language, others invented the framework for rapid development, but never really deep learning the bottom of some things, so this year I intend to read the "CLR Via C #" This book, to understand the C # of the bottom, I think this book at least for the future of Code tuning useful, The following reading notes only record the points that I see in the course of reading that are useful and usually not easily noticed. Record in sequence, until the day the book is fully read, the article will be sorted.
Fourth-type Basics
If (O is String)//First check
{
String B = (string) o;//second time
}
For this reason, the. Net invented as simplifies this process
String a = O as String;
if (A! = NULL) {//Although there is still a 2nd judgment here, it is faster to judge whether the null pointer speed is more than the type judgment
//...
}
If a class with the same name exists under more than one namespace, you must write the fully qualified name to the new object in the code. You can use aliases to define these fully qualified names, such as
Using A;
Using B;
Using Testa = A.widget;
So in the original code you might want to write A.widget = new A.widget ();
With an alias you just write Testa = new Testa ();
"CLR Via C #" Reading notes, continuous update ...