Introduce several books of COM (Han Shaoong) (next)

zhaozj2021-02-08  534

Introduce a book of several com (below)

Han Shaoong

Americans write books, I like to write some background culture, Shao Yong is very appreciated. For example, in this book, "COM's lifestyle", it is realistic, and the spirit is one of them. DON BOX is a character of a COM field. It often meets his masterpiece in MSDN. The "COM lifestyle" is actually different from COM programming and traditional C program development and in software Engineering changes.

The book is as follows:

"Strongly, you start all programming work with IDL, don't use IDL only to generate a proxy and placeholder module of the local server. It is like Don Box once said, 'The true COM programmer starts working with IDL'.

Although Shao Yong is very respectful to the master, it is still considered that this is too absolute and extreme. Because Don Box is actually an ideal software development method, we can't encounter. According to DON BOX theory, if we develop a project, all of which use COM components, then you should design all interfaces before starting programming, because the interface is invariant, it should not change, so it should be from IDL Start all the work. Back in reality, our programmers are in the same product, generally construct a program framework, and the component is just some basic functions, not all of the project, and the master's remark is not suitable for us.

Many people think that "in software, the United States is our tomorrow", so they have used Americans to read them as Bible. But Shao Yong said: "If you learn from, you have to choose, think about it, see it is not in line with China's national conditions."

The last chapter of the book uses the previously described content to create an example of a real distributed application. It is recommended that the reader carefully studied (including other procedures in this book), be brave enough to eat crabs. Otherwise, even if you have a little bit of oil, tell you how delicious crabs, there may be no more people.

Highly recommended! COM's "Collection of Collection" --- "COM Principles and Applications"

Title: "COM principle and application"

Author: Pan Aimin

Tsinghua University Press November 1999

Pricing: 39.00 yuan

The simple appearance of the simple appearance, a strange name, the price of almost white delivery is the first feeling of Shao Yong's first book. But opened this book, after browsing, Le Shao Yong suddenly "Heartbeat accelerated, headed up", smashed his eyes, there is a joy of gold. So one chapter, one chapter, the more you look at it, the more you read more, you can't help but exclaim: "This book is a collection of COM!"!

Le Shao Yong believes that this book has four characteristics of "systemic, rigorous, in-depth, practicality". "Systemic" is to say that the knowledge discussed in this book involves all aspects of the COM area, not only comprehensive, and the system. Looking at the end of Pan Aimin's skills, he can do it, but he will not only study COM, but also to C 's understanding is also a fire pure (the author translated "Visual C technology insider" [fourth edition] Therefore, therefore, it is clear, and there is a confirmed system. It is like the water of the Yangtze River, which makes people feel refreshed and linger. "Strictness" is that the phrase wording in the book is quite paying attention to the scrutiny. In some places, it seems that there is a suspect, but the product is carefully discovered, but she has not understood so deeply before. "In-depth" is that this book is not a general book, and many of the discussing discussions are superb, giving people a new feeling, which is a masterpiece. Since the author's skill is deep, the combination of theory and practice can be described as "seamless", so "practicality" is also a major characteristic of this book.

The book is divided into three parts, and the first part includes the top five chapters, telling the principle of COM. Le Shao Yong believes that if several show is the same topic, it is easy to see the level of the level. Regarding the most basic concepts such as components, interfaces, DLLs, and cross-trip calls may be speaking on COM books, but they are different. In this book, the author not only tells the basic theory, but also has a collection, processing, and many places have made a summary, and it is very organized to say "one, two, three" to the reader. With many people now take the English information to fight together, you can "pile" and a book, the author's practice is really difficult. The fourth chapter tells the transparency of the client program to create a COM object. Everyone knows that whether it is the process within the process or the processes, the client can create a COM object with a consistent way. For components within the process, whether it is creation process, or the calling process of the interface function, we can understand the interaction between components and customers in accordance with the general same process internal function calls; but for process external components, actual situation Most of the complicated, because component programs and client have different process space, so all interactions between them involve communication between processes.

Although client programs and objects are in different process spaces, all the calls of the interface are indirect, the client call interface member function is the same as the function in this process, which is the transparent effect of COM.

In this section, the author not only introduces the memory model of the component process and the customer process, but also discusses a detailed discussion on the column call process in the interface call, and gives a standard column for customizing the interface. The process of the assembly program will be described in example with example explanation of the implementation process of the process external component custom interface.

Shao Yong believes that this part of the discussion is not in-depth, and it is very standard. Take the column process of the class factory as an example, there is a discussion in the book:

"(1), first determine the CLSID of the proxy object provided by the registration object (ie, the class object), if the registration object cannot provide the CLSID of the agent object, use the standard column agent object. Then the CoregisterClassObject function requires the registration object to provide columns The packet is actually a byte stream that contains the information necessary for a proxy object and component objects. If the registration object does not provide such a packet, use the standard column packet provided by COM. .

(2), COM transmits the CLSID and column packets of the agent object to the customer process, and the CogetherClassObject function is waiting for this data.

(3) In the customer process, COM creates a proxy object based on the transferred CLSID and passes the column packet to the agent object. Because the column set packet contains the connection information of the proxy object and component object, the proxy object uses the packet to establish a connection to the component. "

The discussion of this summary is almost all the chapters of the book. It is very difficult to do this, but the author does not have a pen, he also introduces the Imarshal interface in detail, and gives the implementation of custom columns. As such knowledge, you may not find it in other books.

Chapter 5, "Developing COM App Use with Visual C " mainly discusses two aspects, one is MFC, one is ATL. Due to the accusations of the author in Visual C , this part can be first none in the same kind of books in the similar books in this section. I said that when the general book is talking about it, the mechanism to implement the COM interface with MFC often has some involvement, but most of the discussion is not enough, long-term, Shao Yong has a feeling of "walking out of the restaurant but not eating". It is inevitable to regret. But this book is done, by in-depth profiling of Declare_Interface_map (), begin_interface_map, end_interface_map, interface_part, init_interface_part, so that the reader can implement the MFC to implement the COM interface, how to define an interface mapping table has a comprehensive understanding. If you need to use MFC to write COM components, I believe you will definitely benefit shallow. Next, the discussion of ATL is slightly thin, but the content is essential, with a high reference value. Le Shao Yong believes that today, today, today, the market is still lacking a system to tell ATL books, but I don't know which "heroes" have mood to fill this lack. The second part of the book is six to ten chapters, which tell some of the contents of the COM specification, including connectable object communication mechanisms, structural storage technologies, COM object name object technology, unified transport mechanism, and DCOM. If the reader should comprehensively understand COM, this part of the content provides you with the details of these technologies. Previously, very few books can be so systematically introduced these technologies, even if there are occasional books involved in one or two, they are not very deep. And this part of the knowledge involves many practical problems in COM applications, such as OLE, although it has been born for many years, most people are still a semi-solving, master is not enough. Although you can find many information from a variety of media, it is not more common to organize these information. Throughout these chapters, it can be seen that the author must seriously study the COM architecture and Many internal information and source code of OLE, and make these original brackets and difficult materials through their own processes. " meal". "It's rare, rare," Shao Yong finished these chapters, could not help but praise, "I also have a big year!" (In fact, there is a lot of feelings that you have to share with you, but unfortunately Limit, you can only take the most exciting part of the introduction, want to know more, or buy a home and slowly look at it.)

DCOM has to be said, it is inevitable from the COM from the desktop environment to the distributed network environment. From COM, it has gradually reached DCOM. This part is a model of "in-depth light", not only detail the principles and characteristics of DCOM, but how users create DCOM components, but also discussion on connection management, concurrency management. Remember that I spent the last few chapters when I commented on the "COM technology insider"? So, the books of Mr. Pan Aimin make up for your shortcomings.

In the second part, my last topic is about security, because it is too important for a distributed system. "COM principle and application" discusses security in two places, the first time in Chapter 4, it is mentioned that activation security and call security. Here, COM security is described here from the perspective of COM characteristics, focusing on the security model structure. The second time is in Chapter 10, mentioned access security and excitation security, focusing on the configuration of the security model in the distributed environment, emphasizes practicality. At this point, some readers may feel that these four "security" mix together, bumps, stir mix, but it is a good dish, but unfortunately don't understand. Le Shao Yong believes that this is just because there are too many nouns in the COM, and it is very confusing, and Microsoft is not yet. Therefore, this is really difficult for those who write books. So some authors have adopted a policies that activate security and call security, without accessing security and stimulating security, and if access security and excitation security are only word for security and call security. Not mentioned. Think although it is difficult to solve it, it is not conducive to readers to build a complete concept. "COM principle and application" did not avoid difficulties, and its "in-depth" has also been reflected again. It can be seen, when writing this part, the author also got a job, he made a level of COM safety with a different point of view, I think it is valuable to have two: one, The information of COM is very difficult. About the safety materials are less, it is not easy to collect the information of the comparative system; second, there is basically no authoritative discussion before this part of the knowledge, the people who write books Enconscent, this requires the author to have a good skill and understand, of course, has also had a hard effort. To be honest, this part of the book is less than a few times, and there is a lot of knowledge. My suggestion is that when reading this section, I remember to be meticulous but don't drill the horns, otherwise it may really come around for a while. Also, because the security of DCOM is based on NT security, many places involve the security policy of distributed systems, so you'd better have the basics of this aspect, if not, don't understand is normal Do things. Through the study of the top two parts of this book, you have a relatively comprehensive understanding of the basic principles and extensions of COM, just like covering a house, you have already made a solid foundation and start the wall, it is really a welcome A congratulations! But this is not enough, because we learn how to use it well. Therefore, the third part must be conducted, where you will learn from both COM advantages and practical technology, the author will teach you how to cover the roof of the house.

The eleventh chapter of the book tells the automation object. The concept of automation appears in OLE2 at the time, called OLE Automation. Later, this concept was absorbed by COM, called automation. Automated concepts are introduced in a wide variety of Control, Word and Execl also support automation. This is often the case, the more it is, the brighter, the brighter it is, the next one is just right. Automation is, this is, and various data is always can't catch the focus. "Inside COM" discussion about automation is also very satisfactory, and "COM principle and application" is compensated for this shortage.

We know that COM substantially defines a communication method for customers and servers, and this communication is done through an interface. When we use C to write a client program, everything is so beautiful, and a interface pointer will be obtained through CocreateInstance and QueryInterface, and the corresponding function can be called through this interface pointer. Please note that all this is made through a pointer. But when we write a customer program with Visual Basic, the situation is not so beautiful, only one: Visual Basic is a weak type programming language, which is very limited in the data type. Therefore, we must propose a scheme that allows interpretative languages ​​to access components, this program is called automation. An automation server is actually a COM component that implements the IDispatch interface, and an automation controller is a COM customer that communicates with the IdisPatch interface with the automation server. In this chapter, the author has a detailed discussion and a good example of the programming of the IDSPATCH interface and related data type, the implementation, dual interface, and late binding and early binding, and the programming of the automation objects. Another flash point.

Chapter 12 tells ActiveX control. In this chapter, the author not only detailed the basic theory of ActiveX control, but also discussed in depth on how to apply ActiveX control in the Internet environment. Therefore, this chapter is an unsatisfactory information that has some readers with some basic knowledge of this area. Since the authors have made some extravagance in order to save space, some places may have certain jumping sense, but there are many ways to introduce the ActiveX foundation. Since the author is very familiar with MFC, the example of this chapter still uses MFC to prepare and conducts in-depth analysis, which is a good opportunity for C enthusiasts.

As a software model, CoM not only provides standards between procedures and procedures, but also changing traditional programming methods. Therefore, the main contribution of COM is to change the programming method. Chapter 13 of the book tells the COM-based programming. In this chapter, the author has analyzed the object-oriented programming method and compared with the component chemical design, and discusses MTS, and The layer application software structure and COM-based web application have been introduced to enable readers to create a comprehensive understanding of the component.

Although MTS has been introduced for a while, there are not many people who are truly used. Many explorations only stay in theory, which makes the advantages of MTS have not been known by the vast number of Windows programmers. However, with the release of Windows2000 and the release of COM , this situation will change soon. COM is integrated with COM, DCOM, MTS, which enhances component software to the application layer through various support of the operating system, and all underlying details are left to the operating system. The last chapter of the book introduces COM , which is very important in understanding the services provided by Windows2000.

"COM principle and application" is the power of Mr. Pan Aimin, I think it is two: one, this book is very good at the consistency and noun before and after, readers get "authentic" COM Chinese books It is significantly different from the translation work. Second, the domestic writer can write such a works such as (or even the writer of the United States). For us, it is indeed a rejoicant thing, but it will be in the near future, such books will be increasingly more.

Of course, "COM principle and application" is not perfect. For the knowledge involved, some partial discussions are slightly thin, especially the analysis of the examples of the examples, perhaps the author considers the cause of the compression level. Le Shao Yong believes that not all people can digest "concentrated" knowledge. Through the above discussion, I believe that you have a certain understanding of these COM books, you can choose to read according to your own actual situation.

New millennium, new weather, Leng Gong special written a connection, with everyone:

Shanglian: New Millennium View Sun Moon Huiye

Downlink: tens of thousands of drainage points

Horizontal batch: Zhi is present

转载请注明原文地址:https://www.9cbs.com/read-217.html

New Post(0)