作者:empty 页数:218 出版社:empty |
When you reprogramming Ca 40 and need a title help, this tgh tlyfocused and practical book tells you exactly what you nced toknow-wt xeutkongintoduckrlscrskx Hed examples its idealas as ucx in ct quick reference or as a guice to gct you rapidly up tospeed if you already know Java, C++yoran carlier version of CaWritten by the authors of the acclaim etCm40ma Nutshell(OReilly) , this hook covers the entire .C* 40 language—withoutskimping on the details-including:w Features new to Ca 4.0, such as dynamic binding, optional andw Advanced top ks, including operator overloading, custom conversions,named parameters, and type parameter variancemAll of Crs fundamentalstype constraints, covariance and contra variance, lambda expressionsand closures, iterators, nullable types, and operator liftingm LINQ, starting with sequences, lazy execution, and standard queryoperators; finishing with a complete reference to query expressionsm Unsafe code and pointers, custom attributes, preprocessordirectives, and XML documentationJoe Alba hari is the author of LINQ Pad and other Cr tools.He has heendeveloping largescale enterprise applications for more than I 7 years.Ben Alba hari a former program manager at Microsof List he founderof Take On lt.a website for comparing the opinions of experts,leaders, and organizations on controversial io pies.oreilly.com
Joseph Alba hari and Ben Alba hariBeing·Cambi pe·fam ham·Koh-Seba stop el-Tape i-TokyoNovember 2002.First El ici on.CA40PedetRernc, Th dEst onby Joseph Alba han and Ben Alba hanCopy rghee2410JoaephAlahat and He nAla her all rg here seedPrinted in CanadaPub shed by OR ely Media.Inc, 1005GayensteinHghwayNorh, Seo'Rllyboosmarbepurchaeedfo red acac ional, bust bess, or sales promobon al use On a need to nfarealearadlbletorme states thr paI mysa fanbooksoniine.com) .Form of en formation, com act our corporate/in sLi tution asales departmen:8000998.9938orcopotategoresly.com.
Nun hel Handbook.the Nun hell Hand ba ok logo, and the OR ely logn areregler edtradkrksafORelyMeda, In.Cw.0PonketRelranc, theimage of an African cron med crane, and rela red trade dress are trademarksof O'Relly Media, IncMany of the deign at ins used by manufa turers and sll rs to d ingushde ag nations have been pnntedincapsorinirilcapsfor dam apes re suing from the use ot the informatin conca in ed hee
Contents
C#4.0 Pocket Reference
Using Code Examples
Howto Contact Us
Sa fan*Books Online
A First Ca Program
Compilation
Syntax
Identfier sand Keywords
Literals, Punct u ators, and Operators
Comments
Type Basis
Predefined Type Examples
Custom Type Examples
Conversions
Value Types Versus Reference Types
Pre de in ed Type Taxonomy
Numeric Types
Numeric Liter as
Numeric Conversions
Art hm etc Operators
Increment and De cement Operators
Special zed Integral Operations
8-and 16-Bit Integrals
Special Foat and Double Values
double Versus decimal
Real Number Rounding Errors
Boolean Type and Operators
Equality and Comparison Operators
Conditional Operators
Strng sand Characters
String ype
Arrays
Default Element Initialization
Multidimensional Arrays
Simpl fied Array Initialization Expressions
Van ables and Parameters
The Stack and the Heap
Definite Assignment
Default Values
Parameters
var—Impli ot ly Typed Local Variables
Expressions and Operators
Assignment Expressions
Operator Precedence and Associativity
Operator Table
Statements
Deda ration Statements
Expression Statements
Selection Statements
Iteration Statements
Jump Statements
Namespaces
The using Directive
Rules Within a Namespace
A lasing Types and Namespaces
Classes
Fields
Methods
Instance Constructors
Object In it alize rs
The this Reference
Properties
Indexers
Constants
Static Constructors
Static Classes
Finalizers
Partial Types and Methods
Inheritance
Polymorphism
Casting and Reference Conversions
Virtual Function Members
Abstract Classes and Abstract Members
Hiding Inherited Members
Sealing Functions and Classes
The base Keyword
Constructors and inheritance
Overloading and Resolu ion
The obj edt Type
Boxing and Unboxing
Static and Runt me TypeChecking
The GetType Method and type of Operator
Object Member Lit ng
Equ as, Reference Equ as, and GetHashCode
The ToString Method
Structs
Struct Construction Semantics
Access Modifiers
Friend Assemblies
Access i bit Capping
Interfaces
Extending an Interface
Explicit Interface Implementation
Implement ng Inter ace Members Vr tual y
Reimplementing an Interface in a Subd ass
Enums
Enum Conversions
Flags Enums
Enum Operators
Nested Types
Generics
Generic Types
Generic Methods
De daring Type Parameters
type of and Unbound Generic Types
The default Generic Value
Generic Constraints
Subd as sing Generic Types
Self Referencing Generic De dla rations
Static Data
Covariance{C¥4.0)
Contra variance{C#4.0)
Delegates
W rng Plug-in Methods wth Delegates
Multicast Delegates
Instance Versus Stat Method Targets
Generic Delegate Types
The Func and Acton Delegates
Delegate Compati bi ity
Events
Standard Event Pattern
Event Accessors
Lambda Expressions
Capturing Outer Var ables
Anonymous Methods
try Statements and Exceptions
The catch Clause
The finally Block
Throwing Exceptions
Key Properties of System.Exception
Common Exception Types
Enumeration and Iterators
Enumeration
Collection Initializers
Iterators
Iterator Semantics
Composing Sequences
Nullable Types
Nullable Basics
Operator L tng
bool wih&and|Operators
Null Coal esa ing Operator
Operator Overload ig
Operator Functions
Overloading Equat y and Comparison Operators
Custom Impl ict and Expl it Conversions
Extension Methods
Extension Method Chaining
Ambiguity and Resolution
Anonymous Types
LINQ
LINQ Fundamentals
Defer Ted Execution
Standard Query Operators
Chaning Query Operators
Query Expressions
The let Keyword
Query Continuations
Multiple Generators
Joining
Ordering
Grouping
Of Type and Cast
Dynamic Binding(CA 4.0)
Static Binding Versus Dynamic Binding
Custom Binding
Language Binding
Runtime Binder Exception
Runte Representation of dynamic
Dynamic Conversions
var Versus dynamic
Dynamic Expressions
Dynamic Member Overload Resolu on
Un callable Functions
Attributes
Attribute Classes
Named and Positional Attribute Parameters
Attr bute Targets
Specifying Multiple Ati but es
Writing Custom Attributes
Retrieving Att