Essential Guide to Managed Extensions for C++

Siva Challa, Artur Laksberg

  • 出版商: Apress
  • 出版日期: 2002-01-29
  • 售價: $1,430
  • 貴賓價: 9.5$1,359
  • 語言: 英文
  • 頁數: 384
  • 裝訂: Paperback
  • ISBN: 1893115283
  • ISBN-13: 9781893115286
  • 相關分類: C++ 程式語言
  • 下單後立即進貨 (約1週~2週)



  • Features how to write .NET applications using C++ and mix unmanaged C++ and managed C++ code in the same application
  • Shows when and why to use unmanaged code in .NET development
  • All chapters include code samples with detailed explanations

The Essential Guide to Managed Extensions for C++ provides a comprehensive guide for programmers writing code in Managed Extensions for C++ (MC++). The information in this book comes straight from the horse’s mouth—both authors have been key members of the Visual C++ .NET compiler development team and have spent most of their time implementing the language and educating others about managed C++. Managed Extensions for C++ are extensions added to the Visual C++ .NET compiler to allow developers access to the functionality provided by the .NET Framework. Visual C++ .NET is the only .NET language that can generate both native and managed code, and it has a rich set of features to let you write managed applications for the .NET platform.

The book is divided into two parts. Part One covers the basics of MC++. It starts with an introduction to MC++. Then it gives a brief introduction to the .NET Framework. Next, it goes directly into the various features of MC++, including managed classes, interfaces, value types, properties, enumerations, pointers, arrays, operators, delegates, attributes, events, and exceptions.

Part Two of the book is devoted to the transition between the managed and unmanaged worlds. It starts with a general introduction to interoperability between managed and unmanaged code. The following chapters describe the Platform Invoke service, interoperability between COM and .NET, and various data marshaling techniques. The last chapter of Part Two shows how MC++ can be used to write interoperability layers over existing components with minimal overhead.


  • Introduction
  • Chapter 1: Hello, World!
  • Chapter 2: .NET Framework
  • Chapter 3: Managed Classes
  • Chapter 4: Interfaces
  • Chapter 5: Value Types
  • Chapter 6: Pointers, References, and Conversions
  • Chapter 7: Arrays
  • Chapter 8: Enumerators
  • Chapter 9: Properties
  • Chapter 10: Operators
  • Chapter 11: Attributes
  • Chapter 12: Delegates
  • Chapter 13: Events
  • Chapter 14: Exceptions
  • Chapter 15: Transition From Native to Managed Code
  • Chapter 16: Platform Invocation Service
  • Chapter 17: Accessing COM Components from .NET
  • Chapter 18: Accessing .NET Components from COM
  • Chapter 19: Data Marshaling between COM and .NET
  • Chapter 20: Managed Wrappers for Native Types
  • Appendix A: Compiling the Code
  • Appendix B: Metadata
  • Appendix C: Assemblies