|
1 of 1 people found the following review helpful:
5.0 out of 5 stars
Great introduction to COM/DCOM., 3 Jan 2000
By A Customer
This book is for C++ programmers who want to learn how to build their own COM and DCOM componets. COM/DCOM programming is a complex subject and therefore this book can only be recommended to the more experienced C++ programmers who have not tackled COM programming before. In order to use the book you will need the following: * Windows 95 OSR2, Windows 98, or Windows NT 4. * Visual C++ 6 Professional or Enterprise edition. * MFC version 6 (comes with Visual C++ 6). I have had this book for a few months now and I have read it from front to back, most chapters more than once. All the examples worked. When I decided to build the example projects by typing them in, I had some linking problems but I overcame them by loading the sample project files and comparing the various build options to mine. I added what was missing and everything worked. It starts from the ground up and it does not assume any prior knowledge of COM. It does not use any of the Visual C++ wizards in order to build any of the examples. This means that building the examples is not as quick as it could have been. The enclosed CD icludes all the examples with their project files. On the plus side, not using the wizards gives the newcomer a better understanding about the basics. The book examines COM/DCOM in general and it does not focus into any particular area. For example, chapter 4 shows how to build a COM componet in raw C++, but chapters 5, 6 and 7 use MFC. From chapter 8 onwards ATL is used for all examples to the end of the book. Before reading this book I had a little knowledge of COM but I did not know why we need it or how all its parts fit together. I was also confused on how to approach COM developement, should I use MFC or this 'new' library called ATL? I have been programming with MFC for over 12 months and since I was familiar with it I was not keen on ATL but this book tought me that for distributed components, ATL is the way to go. The 'fog' that engulfed COM, has now cleared. This is the book's main strength, it explains to COM beginners what it is all about. It also shows how to build a 'real' distributed application which demonstrates the various 'hurdles' that the programmer needs to tackle but are not strictly speaking part of COM. This is a great book and it is highly recommended. You will need another book in order to focus into your field of interest (I use 'Creating Lightweight Components with ATL'). The contents of the book, copied from its introductory chapter follow: Chapter 1: An Overview of Microsoft's Object Technoogies. This chapter explains the following topics: COM, OLE, ActiveX and the evolution of Microsoft's object technologies. Chapter 2: The Object Revolution. This chapter explores what might be called the object revolution and introduces you to basic object-oriented concepts such as encapsulation, inheritance, and polymorphism. You will find out that there are two types of inheritance and which type COM supports. Finally, you learn the basics of the component object model by first looking at what COM is and why its mastery is so important. You delve into the notion of interfaces and mapping the IUknown. Chapter 3: Building COM Objects and Interfaces. In this chapter you learn how to start building component-based programs using COM. COM is the precursor to DCOM, and the two technologies are intrinsically linked. Learning about DCOM means learning about COM first. Chapter 4: Implementing a COM Client and Server. You will implement your first COM client and COM server. You learn issues regarding the layout and architecture of your components, as well as registering them in the Registry. Additionally, you learn Unicode and internationalizing your components. Chapter 5: COM Programming with MFC. This chapter finds you exploring COM programming with MFC. You will discover the clever way in which the MFC development team used interface maps to enable you to create light and fast COM components quickly. Chapter 6: Using Aggregation to Simulate Inheritance. In this chapter you examine aggregation and discover that it's the primary mechanism used by COM objects for code reuse. Aggregation will help resolve the problems associated with new versions of your components. Chapter 7: Breaking the Process Boundry Using Local Servers. Armed with the knowledge you have aquired so far, you will explore developing componets that step across boundries on a single machine. These components are local servers, and Chapter 7 shows how easy it is to create local servers. Chapter 8: Building COM Objects Using the ActiveX Template Library. You will learn how to build COM objects using the ActiveX Template Library. This chapter shows you how the clever use of C++ templates can simplify and enhace your ability to build COM objects. Chapter 9: A Distributed Objects Overview. Now you really start to learn how Microsoft has taken COM technology and extended it to include the network. This first chapter gives you a high-level picture of what programming with DCOM entails. Chapter 10: Security. This chapter demonstrates DCOM security. You will find that the new security enhancements are not just for DCOM; they affect nondistributed COM as well. You also learn Win32 security, including user profiles and access tokens. You will look at restricting access to running objects and at configuring a class to always run in the security context of a user. Finally, you learn how to assure message integrity, as well as integrating DCOM interfaces with the new Cryptography API. Chapter 11: Using Different COM Threading Models. In this chapter you learn the principles of how to build an NT service. You will delve into how to wrap a COM interface into a service, and you will address the life-cycle concerns of your COM objects. Chapter 12: Automation Unveiled. In this chapter, you will learn how to make your distributed objects thread-safe by exploring the two types of threading models: the free threading model and the apartment threading model. Chapter 13: Using Distributed Objects. This chapter consolidates everything you have learned and puts it to work building a true distributed object application.
|