框架设计(第三版)(英文影印版)
基本信息
- 原书名: CLR via C#
- 原出版社: Microsoft Press
- 作者: Jeffrey Richter
- 出版社:东南大学出版社
- ISBN:9787564124144
- 上架时间:2010-12-23
- 出版日期:2010 年10月
- 开本:12开
- 页码:873
- 版次:3-1
- 所属分类:
计算机 > 软件与程序设计 > 综合 > 综合
编辑推荐
自下而上地掌握clr和.net的开发的权威指南
Jeffrey Richter针对Visual Studio 2010、.NET 4.0、C# 4.0的集大成之作
全世界.NET开发人员的必读经典!
推荐阅读
内容简介回到顶部↑
书籍
计算机书籍
自下而上地掌握clr和.net的开发的权威指南
深度挖掘并掌握公共语言运行时、ccc和,net开发的错综复杂之处。作为编程专家和微软.net团队的长期顾问,jeffreyrichter将带领你获得务实的见解来创建健壮、可靠且反应迅速的应用程序与组件。更新.netframework4。0及多核编程部分之后,这本完美的经典指南可帮助开发者建立任何类型的应用程序,包括microsoft silverlight、asp.net、windows、presentation foundation、web services和控制台应用。
从本书理解以下内容:
建立、部署基于版本的应用程序、组件和共享程序集
在理解原语、数值和引用类型行为的基础上来定义并更高效地使用它们
使用泛型和接口定义可重用算法
有效地使用特殊的clr类型——委托、枚举、自定义属性、数组、字符串
理解垃圾收集器如何管理资源
使用线程池、任务、取消模式、定时器和异步i/o操作来设计灵活、可靠、可扩展的解决方案
使用异常处理以协助状态管理
使用clr托管、appdomain、程序集加载、反射和ccc动态类型来构建动态可扩展的应用程序
计算机书籍
自下而上地掌握clr和.net的开发的权威指南
深度挖掘并掌握公共语言运行时、ccc和,net开发的错综复杂之处。作为编程专家和微软.net团队的长期顾问,jeffreyrichter将带领你获得务实的见解来创建健壮、可靠且反应迅速的应用程序与组件。更新.netframework4。0及多核编程部分之后,这本完美的经典指南可帮助开发者建立任何类型的应用程序,包括microsoft silverlight、asp.net、windows、presentation foundation、web services和控制台应用。
从本书理解以下内容:
建立、部署基于版本的应用程序、组件和共享程序集
在理解原语、数值和引用类型行为的基础上来定义并更高效地使用它们
使用泛型和接口定义可重用算法
有效地使用特殊的clr类型——委托、枚举、自定义属性、数组、字符串
理解垃圾收集器如何管理资源
使用线程池、任务、取消模式、定时器和异步i/o操作来设计灵活、可靠、可扩展的解决方案
使用异常处理以协助状态管理
使用clr托管、appdomain、程序集加载、反射和ccc动态类型来构建动态可扩展的应用程序
作译者回到顶部↑
目录回到顶部↑
foreward
introduction
part iclr basics
1the clr's execution model
compiling source code into managed modules
combining managed modules into assemblies
loading the common language runtime
executing your assembly's code
il and verification
unsafe code
the native code generator tool: ngenexe
the framework class library
the common type system
the common language specification
interoperability with unmanaged code
2building, packaging, deploying, and administering applications and types
net framework deployment goals
building types into a module
response files
a brief look at metadata
introduction
part iclr basics
1the clr's execution model
compiling source code into managed modules
combining managed modules into assemblies
loading the common language runtime
executing your assembly's code
il and verification
unsafe code
the native code generator tool: ngenexe
the framework class library
the common type system
the common language specification
interoperability with unmanaged code
2building, packaging, deploying, and administering applications and types
net framework deployment goals
building types into a module
response files
a brief look at metadata
前言回到顶部↑
It was October 1999 when some people at Microsoft first demonstrated the Microsoft .NET Framework, the common language runtime (CLR), and the C# programming language to me. The moment I saw all of this, I was impressed and I knew that it was going to change the way I wrote software in a very significant way. I was asked to do some consulting for the team and immediately agreed. At first, I thought that the .NET Framework was an abstraction layer over the Win32 APl and COM As I invested more and more of my time into it, however, I realized that it was much bigger. In a way, it is its own operating system. It has its own memory man ager, its own security system, its own file loader, its own error handling mechanism, its own application isolation boundaries (AppDomains), its own threading models, and more. This book explains all these topics so that you can effectively design and implement software applications and components for this platform.
I have spent a good part of my life focusing on threading, concurrent execution, parallelism, synchronization, and so on. Today, with multicore computers becoming so prevalent, these subjects are becoming increasingly important. A few years ago, I decided to create a book dedicated to threading topics. However, one thing led to another and I never produced the book. When it came time to revise this book, I decided to incorporate all the threading information in here. So this book covers the .NET Framework's CLR and the C# programming language, and it also has my threading book embedded inside it (see Part V, "Threading").
It is October 2009 as I write this text, making it 10 years now that I've worked with the .NET Framework and C#. Over the 10 years, I have built all kinds of applications and, as a consul tant to Microsoft, have contributed quite a bit to the .NET Framework itself. As a partner in my own company, Wintellect (http://Wintellect. com), I have worked with numerous customers to help them design software, debug software, performance-tune software, and solve issues they have with the .NET Framework. All these experiences have really helped me learn the spots that people have trouble with when trying to be productive with the .NET Framework. I have tried to sprinkle knowledge from these experiences through all the topics presented in this book.
Who This Book Is For
The purpose of this book is to explain how to develop applications and reusable classes for the .NET Framework. Specifically, this means that I intend to explain how the CLR works and the facilities that it offers. I'll also discuss various parts of the Framework Class Library (FCL). No book could fully explain the FCL--it contains literally thousands of types now, and this number continues to grow at an alarming rate. Therefore, here I'm concentrating, on the core types that every developer needs to be aware of. And while this book isn't specifically about Windows Forms, Windows Presentation Foundation (WPF), Silverlight, XML Web services,Web Forms, and so on, the technologies presented in the book are applicable to all these application types.
The book addresses Microsoft Visual Studio 2010, .NET Framework version 4.0, and version 4.0 of the C# programming language. Since Microsoft tries to maintain a large degree of backward compatibility when releasing a new version of these technologies, many of the things I discuss in this book apply to earlier versions as well. All the code samples use the C# programming language as a way to demonstrate the behavior of the various facilities. But,since the CLR is usable by many programming languages, the book's content is still quite applicable for the non-C# programmer.
Today, Microsoft offers several versions of the CLR. There is the desktop/server version, which runs on 32-bit x86 versions of Microsoft Windows as well as 64-bit x64 and IA64 versions of Windows. There is the Silverlight version, which is produced from the same source code base as the desktop/server version of the .NET Framework's CLR. Therefore, everything in this book applies to building Silverlight applications, with the exception of Some differences in how Silverlight loads assemblies. There is also a "lite" version of the .NET Framework called the .NET Compact Framework, which is available for Windows Mobile phones and other devices running the Windows CE operating system. Much of the information presented in this book is applicable to developing applications for the .NET Compact Framework, but this platform is not the primary focus of this book.
On December 13, 2001, ECMA International (http://www. ecma-international, org/) accepted the C# programming language, portions of the CLR, and portions of the FCL as standards.The standards documents that resulted from this have allowed other organizations to build ECMA-compliant versions of these technologies for other CPU architectures, as well as other operating systems. In fact, Novell produces Moonlight (http://www. mono-project, com /Moonlight), an open-source implementation of Silverlight (http://Silverlight. net) that is primarily for Linux and other UNIX/X11-based operating systems. Moonlight is based on the ECMA specifications. Much of the content in this book is about these standards; therefore,many will find this book useful for working with any runtime/tibrary implementation that adheres to the ECMA standard.
Dedication
To Kristin Words cannot express how I feel about our life together. I cherish our family and all our adventures. I'm filled each day with love for you.
To Aidan (age 6) and Grant (age 2) You both have been an inspiration to me and have
taught me to play and have fun. Watching the two of you grow up has been so rewarding and enjoyable for me. I am lucky to be able to partake in your lives. I love and appreciate you more than you could ever know.
Acknowledgments
I couldn't have written this book without the help and technical assistance of many people. In particular, I'd like to thank my family. The amount of time and effort that goes into writing a book is hard to measure. All I know is that I could not have produced this book without the support of my wife, Kristin, and my two sons, Aidan and Grant. There were many times when we wanted to spend time together but were unable to due to book obligations. Now that the book project is completed, I really look forward to adventures we will all share together.
For this book revision, I truly had some fantastic people helping me. Christophe Nasarre, who I've worked with on several book projects, has done just a phenomenal job of verifying my work and making sure that I'd said everything the best way it could possibly be said. He has truly had a significant impact on the quality of this book. As always, the Microsoft Press editorial team is a pleasure to work with. I'd like to extend a special thank you to Ben Ryan, Valerie Woolley, and Devon Musgrave. Also, thanks to Jean Findley and Sue McClung for their editing and production support.
Support for This Book
Every effort has been made to ensure the accuracy of this book. As corrections or changes are collected, they witl be added to a Microsoft Knowledge Base article accessible via the Microsoft Help and Support site. Microsoft Press provides support for books, including instructions for finding Knowledge Base articles, at the following Web site:
http://www, rnicrosoft, com/learning/support/books/
If you have questions regarding the book that are not answered by visiting the site above or viewing a Knowledge Base article, send them to Microsoft Press via e-mail to mspinput@microsoft.com.
Please note that Microsoft software product support is not offered through these addresses.
I have spent a good part of my life focusing on threading, concurrent execution, parallelism, synchronization, and so on. Today, with multicore computers becoming so prevalent, these subjects are becoming increasingly important. A few years ago, I decided to create a book dedicated to threading topics. However, one thing led to another and I never produced the book. When it came time to revise this book, I decided to incorporate all the threading information in here. So this book covers the .NET Framework's CLR and the C# programming language, and it also has my threading book embedded inside it (see Part V, "Threading").
It is October 2009 as I write this text, making it 10 years now that I've worked with the .NET Framework and C#. Over the 10 years, I have built all kinds of applications and, as a consul tant to Microsoft, have contributed quite a bit to the .NET Framework itself. As a partner in my own company, Wintellect (http://Wintellect. com), I have worked with numerous customers to help them design software, debug software, performance-tune software, and solve issues they have with the .NET Framework. All these experiences have really helped me learn the spots that people have trouble with when trying to be productive with the .NET Framework. I have tried to sprinkle knowledge from these experiences through all the topics presented in this book.
Who This Book Is For
The purpose of this book is to explain how to develop applications and reusable classes for the .NET Framework. Specifically, this means that I intend to explain how the CLR works and the facilities that it offers. I'll also discuss various parts of the Framework Class Library (FCL). No book could fully explain the FCL--it contains literally thousands of types now, and this number continues to grow at an alarming rate. Therefore, here I'm concentrating, on the core types that every developer needs to be aware of. And while this book isn't specifically about Windows Forms, Windows Presentation Foundation (WPF), Silverlight, XML Web services,Web Forms, and so on, the technologies presented in the book are applicable to all these application types.
The book addresses Microsoft Visual Studio 2010, .NET Framework version 4.0, and version 4.0 of the C# programming language. Since Microsoft tries to maintain a large degree of backward compatibility when releasing a new version of these technologies, many of the things I discuss in this book apply to earlier versions as well. All the code samples use the C# programming language as a way to demonstrate the behavior of the various facilities. But,since the CLR is usable by many programming languages, the book's content is still quite applicable for the non-C# programmer.
Today, Microsoft offers several versions of the CLR. There is the desktop/server version, which runs on 32-bit x86 versions of Microsoft Windows as well as 64-bit x64 and IA64 versions of Windows. There is the Silverlight version, which is produced from the same source code base as the desktop/server version of the .NET Framework's CLR. Therefore, everything in this book applies to building Silverlight applications, with the exception of Some differences in how Silverlight loads assemblies. There is also a "lite" version of the .NET Framework called the .NET Compact Framework, which is available for Windows Mobile phones and other devices running the Windows CE operating system. Much of the information presented in this book is applicable to developing applications for the .NET Compact Framework, but this platform is not the primary focus of this book.
On December 13, 2001, ECMA International (http://www. ecma-international, org/) accepted the C# programming language, portions of the CLR, and portions of the FCL as standards.The standards documents that resulted from this have allowed other organizations to build ECMA-compliant versions of these technologies for other CPU architectures, as well as other operating systems. In fact, Novell produces Moonlight (http://www. mono-project, com /Moonlight), an open-source implementation of Silverlight (http://Silverlight. net) that is primarily for Linux and other UNIX/X11-based operating systems. Moonlight is based on the ECMA specifications. Much of the content in this book is about these standards; therefore,many will find this book useful for working with any runtime/tibrary implementation that adheres to the ECMA standard.
Dedication
To Kristin Words cannot express how I feel about our life together. I cherish our family and all our adventures. I'm filled each day with love for you.
To Aidan (age 6) and Grant (age 2) You both have been an inspiration to me and have
taught me to play and have fun. Watching the two of you grow up has been so rewarding and enjoyable for me. I am lucky to be able to partake in your lives. I love and appreciate you more than you could ever know.
Acknowledgments
I couldn't have written this book without the help and technical assistance of many people. In particular, I'd like to thank my family. The amount of time and effort that goes into writing a book is hard to measure. All I know is that I could not have produced this book without the support of my wife, Kristin, and my two sons, Aidan and Grant. There were many times when we wanted to spend time together but were unable to due to book obligations. Now that the book project is completed, I really look forward to adventures we will all share together.
For this book revision, I truly had some fantastic people helping me. Christophe Nasarre, who I've worked with on several book projects, has done just a phenomenal job of verifying my work and making sure that I'd said everything the best way it could possibly be said. He has truly had a significant impact on the quality of this book. As always, the Microsoft Press editorial team is a pleasure to work with. I'd like to extend a special thank you to Ben Ryan, Valerie Woolley, and Devon Musgrave. Also, thanks to Jean Findley and Sue McClung for their editing and production support.
Support for This Book
Every effort has been made to ensure the accuracy of this book. As corrections or changes are collected, they witl be added to a Microsoft Knowledge Base article accessible via the Microsoft Help and Support site. Microsoft Press provides support for books, including instructions for finding Knowledge Base articles, at the following Web site:
http://www, rnicrosoft, com/learning/support/books/
If you have questions regarding the book that are not answered by visiting the site above or viewing a Knowledge Base article, send them to Microsoft Press via e-mail to mspinput@microsoft.com.
Please note that Microsoft software product support is not offered through these addresses.
序言回到顶部↑
At first, when Jeff asked me to write the foreword for his book, I was so flattered! He must really respect me, I thought. Ladies, this is a common thought process error--trust me, he doesn't respect you. It turns out that I was about #14 on his list of potential foreword writers and he had to settle for me. Apparently, none of the other candidates (Bill Gates, Steve Ballmer, Catherine Zeta-Jones .... ) were that into him. At least he bought me dinner.
But no one can tell you more about this book than I can. I mean, Catherine could give you.a mobile makeover, but I know all kinds of stuff about reflection and exceptions and C# language updates because he has been talking on and on about it for years. This is standard dinner conversation in our house! Other people talk about the weather or stuff they heard at the water cooler, but we talk about .NET. Even Aidan, our six-year-old, asks questions about Jeff's book. Mostly about when he will be done writing it so they can play something "cool."Grant (age 2) doesn't talk yet, but his first word will probably be "Sequential."
In fact, if you want to know how this all started, it goes something like this. About 10 years ago, Jeff went to a "Secret Summit" at Microsoft. They pulled in a bunch of industry experts(Really, how do you get this title? Believe me, this isn't Jeff's college degree), and unveiled the new COM. Late that night in bed (in our house, this is what we discuss in bed), he talked about how COM is dead. And he was enchanted. Lovestruck, actually. In a matter of days he was hanging around the halls of Building 42 on Microsoft's Redmond campus, hoping to learn more about this wonderful .NET. The affair hasn't ended, and this book is what he has to show for it.
For years, Jeff has told me about threading. He really likes this topic. One time, in New Orleans, we went on a two-hour walk, alone, holding hands, and he spoke the whole time about how he had enough content for a threading book: he art of threading. How misunderstood threading in Windows is. It breaks his heart, all those threads out there. Where dothey all go? Why were they created if no one had a plan for them? These are the questions Of the universe to Jeff, the deeper meanings in life. Finally, in this book, he has written it down.It is all here. Believe me folks, if you want to know about threading, no one has thought about it more or worked with it more than Jeff has. And all those wasted hours of his life (he can't get them back) are here at your disposal. Please read it. Then send him an e-mail about how that information changed your life. Otherwise, he is just another tragic literary figure whose life ended without meaning or fulfillment. He will drink himself to death on diet soda.This edition of the book even includes a new chapter about the runtime seriatizer. Turns out,this is not a new breakfast food for kids. When I figured out it was more computer talk and not something to put on my grocery list, I tuned it out. So I don't know what it says, but it is in here and you should read it (with a glass of milk).
My hope is that now he is finished talking about garbage collection in theory and can get on with actually collecting our garbage and putting it on the curb. Seriously people, how hard is that?
Folks, here is the clincher--this is Jeffrey Richter's magnum opus. This is itl There will be no more books. Of course, we say this every time he finishes one, but this time we really mean it. So, 13 books (give or take) later, this is the best and the last. Get it fast, because there are only a limited number and once they are gone--poof. No more. Just like QVC or something.Back to real life for us, where we can discuss the important things, like what the kids broke today and whose turn is it to change the diapers.
Kristin Trace (Jeffrey's wife)
November 24, 2009
But no one can tell you more about this book than I can. I mean, Catherine could give you.a mobile makeover, but I know all kinds of stuff about reflection and exceptions and C# language updates because he has been talking on and on about it for years. This is standard dinner conversation in our house! Other people talk about the weather or stuff they heard at the water cooler, but we talk about .NET. Even Aidan, our six-year-old, asks questions about Jeff's book. Mostly about when he will be done writing it so they can play something "cool."Grant (age 2) doesn't talk yet, but his first word will probably be "Sequential."
In fact, if you want to know how this all started, it goes something like this. About 10 years ago, Jeff went to a "Secret Summit" at Microsoft. They pulled in a bunch of industry experts(Really, how do you get this title? Believe me, this isn't Jeff's college degree), and unveiled the new COM. Late that night in bed (in our house, this is what we discuss in bed), he talked about how COM is dead. And he was enchanted. Lovestruck, actually. In a matter of days he was hanging around the halls of Building 42 on Microsoft's Redmond campus, hoping to learn more about this wonderful .NET. The affair hasn't ended, and this book is what he has to show for it.
For years, Jeff has told me about threading. He really likes this topic. One time, in New Orleans, we went on a two-hour walk, alone, holding hands, and he spoke the whole time about how he had enough content for a threading book: he art of threading. How misunderstood threading in Windows is. It breaks his heart, all those threads out there. Where dothey all go? Why were they created if no one had a plan for them? These are the questions Of the universe to Jeff, the deeper meanings in life. Finally, in this book, he has written it down.It is all here. Believe me folks, if you want to know about threading, no one has thought about it more or worked with it more than Jeff has. And all those wasted hours of his life (he can't get them back) are here at your disposal. Please read it. Then send him an e-mail about how that information changed your life. Otherwise, he is just another tragic literary figure whose life ended without meaning or fulfillment. He will drink himself to death on diet soda.This edition of the book even includes a new chapter about the runtime seriatizer. Turns out,this is not a new breakfast food for kids. When I figured out it was more computer talk and not something to put on my grocery list, I tuned it out. So I don't know what it says, but it is in here and you should read it (with a glass of milk).
My hope is that now he is finished talking about garbage collection in theory and can get on with actually collecting our garbage and putting it on the curb. Seriously people, how hard is that?
Folks, here is the clincher--this is Jeffrey Richter's magnum opus. This is itl There will be no more books. Of course, we say this every time he finishes one, but this time we really mean it. So, 13 books (give or take) later, this is the best and the last. Get it fast, because there are only a limited number and once they are gone--poof. No more. Just like QVC or something.Back to real life for us, where we can discuss the important things, like what the kids broke today and whose turn is it to change the diapers.
Kristin Trace (Jeffrey's wife)
November 24, 2009







点击看大图







加载中...
