Apress.Pro.C.Sharp.2010.and.The.Dot.NET.4.Platform.5th.Edition.2010.RETAiL-rebOOk.pdf

(18204 KB) Pobierz
686882859 UNPDF
THE EXPERT’S VOICE ®  IN .NET
C# 2010
and
the
.NET 4 Platform
Exploring the .NET universe using
curly brackets
FIFTH EDITION
Andrew Troelsen
Pro
686882859.044.png 686882859.052.png 686882859.061.png 686882859.071.png 686882859.001.png
 
686882859.013.png 686882859.014.png 686882859.015.png 686882859.016.png 686882859.017.png 686882859.018.png 686882859.019.png 686882859.020.png 686882859.021.png 686882859.022.png 686882859.023.png 686882859.024.png 686882859.025.png 686882859.026.png 686882859.027.png 686882859.028.png 686882859.029.png 686882859.030.png 686882859.031.png 686882859.032.png 686882859.033.png 686882859.034.png 686882859.035.png
 
 
686882859.036.png 686882859.037.png 686882859.038.png 686882859.039.png 686882859.040.png 686882859.041.png 686882859.042.png 686882859.043.png 686882859.045.png 686882859.046.png 686882859.047.png 686882859.048.png
 
686882859.049.png
 
686882859.050.png
 
686882859.051.png
 
686882859.053.png
 
686882859.054.png 686882859.055.png 686882859.056.png 686882859.057.png 686882859.058.png 686882859.059.png 686882859.060.png 686882859.062.png 686882859.063.png 686882859.064.png 686882859.065.png
 
686882859.066.png 686882859.067.png 686882859.068.png 686882859.069.png 686882859.070.png 686882859.072.png 686882859.073.png 686882859.074.png 686882859.075.png 686882859.076.png 686882859.077.png 686882859.078.png 686882859.079.png 686882859.080.png 686882859.081.png 686882859.002.png 686882859.003.png 686882859.004.png 686882859.005.png 686882859.006.png 686882859.007.png 686882859.008.png 686882859.009.png
 
Pro C# 2010 and
the .NET 4 Platform
Fifth Edition
■ ■ ■
Andrew Troelsen
686882859.010.png
Pro C# 2010 and the .NET 4 Platform, Fifth Edition
Copyright © 2010 by Andrew Troelsen
All rights reserved. No part of this work may be reproduced or transmitted in any form or by any means,
electronic or mechanical, including photocopying, recording, or by any information storage or retrieval
system, without the prior written permission of the copyright owner and the publisher.
ISBN-13 (pbk): 978-1-4302-2549-2
ISBN-13 (electronic): 978-1-4302-2550-8
Printed and bound in the United States of America 9 8 7 6 5 4 3 2 1
Trademarked names may appear in this book. Rather than use a trademark symbol with every
occurrence of a trademarked name, we use the names only in an editorial fashion and to the benefit of
the trademark owner, with no intention of infringement of the trademark.
President and Publisher: Paul Manning
Lead Editor: Ewan Buckingham
Technical Reviewer: Andy Olsen
Editorial Board: Clay Andres, Steve Anglin, Mark Beckner, Ewan Buckingham, Gary Cornell,
Jonathan Gennick, Jonathan Hassell, Michelle Lowman, Matthew Moodie, Duncan Parkes,
Jeffrey Pepper, Frank Pohlmann, Douglas Pundick, Ben Renow-Clarke, Dominic Shakeshaft,
Matt Wade, Tom Welsh
Coordinating Editor: Debra Kelly
Copy Editors: Patrick Meader, Katie Stence, and Sharon Terdeman
Compositor: folio 2
Indexer: Potomac Indexers
Artist: April Milne
Cover Designer: Anna Ishchenko
Distributed to the book trade worldwide by Springer-Verlag New York, Inc., 233 Spring Street, 6th Floor,
New York, NY 10013. Phone 1-800-SPRINGER, fax 201-348-4505, e-mail orders- ny@springer-sbm.com , or
For information on translations, please e-mail rights@apress.com , or visit www.apress.com .
Apress and friends of ED books may be purchased in bulk for academic, corporate, or promotional use.
eBook versions and licenses are also available for most titles. For more information, reference our
Special Bulk Sales–eBook Licensing web page at www.apress.com/info/bulksales .
The information in this book is distributed on an “as is” basis, without warranty. Although every
precaution has been taken in the preparation of this work, neither the author(s) nor Apress shall have
any liability to any person or entity with respect to any loss or damage caused or alleged to be caused
directly or indirectly by the information contained in this work.
The source code for this book is available to readers at www.apress.com .
Contents at a Glance
Contents................................................................................................................... viii
About the Author..................................................................................................... xxv
About the Technical Reviewer ............................................................................... xxvi
Acknowledgments ................................................................................................ xxvii
Introduction ......................................................................................................... xxviii
■ ■ ■
Part 1: Introducing C# and the .NET Platform................................................. 1
Chapter 1: The Philosophy of .NET.......................................................................... 3
Chapter 2: Building C# Applications ..................................................................... 41
■ ■ ■
Part 2: Core C# Programming Constructs .................................................... 71
Chapter 3: Core C# Programming Constructs, Part I ............................................ 73
Chapter 4: Core C# Programming Constructs, Part II ......................................... 125
Chapter 5: Defining Encapsulated Class Types................................................... 167
Chapter 6: Understanding Inheritance and Polymorphism................................. 219
Chapter 7: Understanding Structured Exception Handling ................................. 259
Chapter 8: Understanding Object Lifetime .......................................................... 289
■ ■ ■
Part 3: Advanced C# Programming Constructs .......................................... 319
Chapter 9: Working with Interfaces.................................................................... 321
Chapter 10: Understanding Generics .................................................................. 361
v
686882859.011.png
CONTENTS AT A GLANCE
Chapter 11: Delegates, Events, and Lambdas..................................................... 397
Chapter 12: Advanced C# Language Features .................................................... 439
Chapter 13: LINQ to Objects ................................................................................ 489
■ ■ ■
Part 4: Programming with .NET Assemblies............................................... 523
Chapter 14: Configuring .NET Assemblies .......................................................... 525
Chapter 15: Type Reflection, Late Binding, and Attribute-Based Programming...... 581
Chapter 16: Processes, AppDomains, and Object Contexts................................ 625
Chapter 17: Understanding CIL and the Role of Dynamic Assemblies................ 653
Chapter 18: Dynamic Types and the Dynamic Language Runtime ..................... 701
■ ■ ■ Part 5: Introducing the .NET Base Class Libraries ...................................... 725
Chapter 19: Multithreaded and Parallel Programming....................................... 727
Chapter 20: File I/O and Object Serialization...................................................... 775
Chapter 21: ADO.NET Part I: The Connected Layer.............................................. 825
Chapter 22: ADO.NET Part II: The Disconnected Layer........................................ 885
Chapter 23: ADO.NET Part III: The Entity Framework ......................................... 951
Chapter 24: Introducing LINQ to XML ................................................................. 993
Chapter 25: Introducing Windows Communication Foundation ....................... 1013
Chapter 26: Introducing Windows Workflow Foundation 4.0 ........................... 1077
■ ■ ■
Part 6: Building Desktop User Interfaces with WPF ................................. 1115
Chapter 27: Introducing Windows Presentation Foundation and XAML ........... 1117
Chapter 28: Programming with WPF Controls .................................................. 1179
Chapter 29: WPF Graphics Rendering Services ................................................ 1245
Chapter 30: WPF Resources, Animations, and Styles....................................... 1285
Chapter 31: WPF Control Templates and UserControls..................................... 1325
686882859.012.png
Zgłoś jeśli naruszono regulamin