Wiley.com
Print this page Share

C# 2005 Programmer's Reference

ISBN: 978-0-470-04641-8
386 pages
November 2006
C# 2005 Programmer

Description

As one of the hottest programming languages in use today, C# enables you to build a wide range of secure and robust enterprise applications that run on the .NET Framework, including XML Web services, client-server applications, database applications, and more. Now with the release of C# 2005, you'll find a complex array of new language options and parameters to create even more powerful applications if you know how to utilize them. This book will show you how.

Combining a comprehensive tutorial and reference, this book breaks down the latest features while exploring the language from the ground up. The first section provides you with a detailed understanding of basic programming concepts and helps you gain the skills to write your own applications. The second section presents detailed information on specific features of the language so you can immediately take advantage of all the tools available.

What you will learn from this book

  • A complete understanding of C# and its language structure
  • The best methods for mastering the new features of C# 2005
  • Techniques for building cutting-edge applications for the .NET Framework
  • How to use powerful options such as enumerations and delegates
  • Ways to increase safety and performance using generic methods and types
  • Steps for incorporating expressions and statements
  • The proper way to use namespaces, classes, structures, and arrays

Who this book is for

This book is an excellent resource for experienced C# developers as well as those who are new to the language. It shows you how to easily develop applications using C# but can also be used as a professional reference.

Wrox Programmer's References are designed to give the experienced developer straight facts on a new technology, without hype or unnecessary explanations. They deliver hard information with plenty of practical examples to help you apply new tools to your development projects today.

See More

Table of Contents

Acknowledgments.

Introduction.

How This Book Is Different.

Who This Book Is For.

How This Book Is Structured.

How to Tackle the Chapters.

A Few Tips.

Conventions.

Source Code.

Errata.

p2p.wrox.com.

Chapter 1: What is C#?

The Name.

C# Overview.

Sample C# Code.

The Benefits of Learning C#.

Chapter 2: Getting Started with C#.

Getting Into C# is Cheaper Than You Think!

One Cheap Utility That Makes Life Easier!

Alternative Text Editors and C# Tools.

Enterprise Tools - Visual Studio and Visual C#.

Chapter 3: Overview of C#.

C#.

C# Basics.

Examining the C# Source Code.

Types.

Variables and Parameters.

Expressions.

Statements.

Classes.

Structs.

Interfaces.

Delegates.

Enums.

Generics.

Iterators.

Nullable Types.

Chapter 4: C# Language Structure.

C# Programs.

Grammars.

Chapter 5: C# Concepts.

Application Startup.

Application Termination.

C# Declarations.

Members.

Member Access.

Signatures.

Scope.

Namespace and Type Names.

Memory Management in C#.

Chapter 6: Types.

Three Types of Types.

The C# Type System.

Value Types.

Reference Types.

Chapter 7: Variables.

What are Variables?

Categories of Variables.

Default Values.

Definite Assignment.

Chapter 8: Conversions.

Implicit Conversions.

Explicit Conversions.

Standard Conversions.

Anonymous Method Conversions.

Method Group Conversions.

Null Type Conversions.

Chapter 9: Expressions.

Classifications of Expressions.

Expression Values.

Expressions and Operators.

Member Lookup.

Function Members.

Primary Expressions.

Unary Expressions.

Cast Expressions.

Arithmetic Operators.

Shift Operators.

Relational/Type Testing Operators.

Logical Operators.

Conditional Logical Operators.

Null Coalescing Operator.

Assignment Operators.

Expression.

Constant Expressions.

Boolean Expressions.

Chapter 10: Statements.

What are Statements?

C# Statements.

Code Blocks.

Empty Statements.

Labeled Statements.

Declaration Statements.

Expression Statements.

Chapter 11: Namespaces.

What are Namespaces?

Compilation Units.

Namespace Declarations.

Extern Alias Directives.

Using Directives.

Chapter 12: Classes.

What are Classes?

Class Declarations.

Class Members.

Fields.

Methods.

Properties.

Events.

Indexers.

Operators.

Instance Constructors.

Static Constructors.

Finalizers.

Chapter 13: Structs.

What are Structs?

Struct Declarations.

Differences Between Class and Struct.

When to Use Structs.

Chapter 14: Arrays.

What is an Array?

Array Types.

Creating Arrays.

Chapter 15: Interfaces.

What is an Interface?

Defining an Interface.

Interface Declarations.

Chapter 16: Enums.

Enum Declarations.

Enum Modifiers.

Enum Members.

Beware Circular References.

System.Enum.

Chapter 17: Delegates.

Delegates in Action.

Delegate Declarations.

Chapter 18: Exceptions.

Throwing Exceptions.

System.Exception.

Common Exception Classes.

Handling Exceptions.

Chapter 19: Attributes.

Introduction to Attributes.

Attribute Classes.

Attribute Specification.

Attribute Instances.

Reserved Attributes.

Chapter 20: Generics.

C# Generics vs. C++ Templates.

Generic Class Declarations.

Generic Struct Declarations.

Generic Interface Declarations.

Explicit Interface Member Implementations.

Generic Delegate Declarations.

Constructed Types.

Where Generics Aren’t Used.

Constraints.

Chapter 21: Iterators.

Iterator Block.

Enumerator Objects.

Enumerable Objects.

Chapter 22: Unsafe Code.

What is Unsafe Code?

Advantages and Disadvantages of Unsafe Code.

Unsafe Code Contexts.

Pointer Basics.

Unsafe in Action.

sizeof Operator.

Using stackalloc.

Compiling Unsafe Code.

Appendix A: C# Grammar.

Appendix B: Naming Conventions.

Appendix C: Standard Library.

Appendix D: Portability.

Appendix E: XML Documentation Comments.

Index.

See More

Author Information

Adrian Kingsley-Hughes and Kathie Kingsley-Hughes (UK) have authored and co-authored several successful technical/PC books on a variety of subjects for a range of publishers including Wiley/Wrox Pressand Sybex.  They have also developed numerous successful training manuals and Internet-based courses for nearly a decade.  They run a UK company specializing in application/internet development and security, and they teach online courses for several training providers.  Adrian has developed several highly successful courses for Barnes and Noble University where he teaches professional skills to students ranging from complete beginners to experts. The two have produced courses and training materials that have been used extensively by many Fortune 50, Fortune 100 and Fortune 500 companies, as well as many leading universities in the US and abroad. Adrian and Kathie also run several high-profile and successful websites, including "The PC Doctor" (http://www.pcdoctor-guide.com) "Kingsley-Hughes.com"(http://www.kingsley-hughes.com).
See More

Errata

Do you think you've discovered an error in this book? Please check the list of errata below to see if we've already addressed the error. If not, please submit the error via our Errata Form. We will attempt to verify your error; if you're right, we will post a correction below.

ChapterPageDetailsDatePrint Run
360 Typo
list of other languages ("Interoperability with Legacy Code"):
Pearl

should be:
Perl
05/21/07
See More

Related Titles

Back to Top