ATL Internals: Working with ATL 8 by Christopher Tavares, Kirk Fertitta, Brent E. Rector, Chris

By Christopher Tavares, Kirk Fertitta, Brent E. Rector, Chris Sells

The lively Template Library (ATL) is a suite of small, effective, and versatile sessions created through Microsoft that facilitate the construction of interoperable parts for constructing home windows purposes. the newest model of ATL is model eight, published with visible Studio 2005. whereas .NET has been getting all of the cognizance lately, there's nonetheless a massive base of put in COM/ATL code. Many programmers are facing tough concerns including new .NET code to that put in base. while there are lots of circumstances the place ATL remains to be some of the best selection for brand new purposes - functions that experience to run quick and successfully on home windows, the place the CPU does not have the reminiscence or bandwidth to run .NET. This booklet may be a godsend to builders in either one of these occasions. As one tech reviewer positioned it, "Any programmer desiring to transition ATL code to .NET will want this book." the 1st version used to be largely praised, and offered with regards to 20,000 devices. whereas ATL isn't any longer the innovative of Microsoft developer instruments, there may still be a robust marketplace for authoritative, entire, deep insurance of the latest model of this normal software.

Show description

Read or Download ATL Internals: Working with ATL 8 PDF

Best nonfiction_1 books

National Geographic (January 2006)

Grand Canyon. .Genocide Unearthed. .Return of the Lynx. .Aip united states: "Mockingbird", Alabama

Handbook of Ultraviolet Methods

It is a publication that I wrote for myself. It was once begun sixteen years in the past while my tasks started to contain the origina­ tion of ultraviolet spectrophotometric trying out equipment for items of in­ terest to my corporation. Painful and wasteful studies of rediscovering anyone else's ana­ lytical methods quickly resulted in my maintaining notebooks and card records of released UV tools.

Additional resources for ATL Internals: Working with ATL 8

Sample text

Com to register . it. Thanks wizard-generated skeleton, the {{Hello}} tag will be passed on to a handler class and replaced by the HTML produced from that class's replacement method. ATL Server uses several macros to map commands in the SRF file to handler classes in our application DLL. "; return HTTP_SUCCESS; } }; The CRequestHandlerT base class provides the implementation for a request-handler class. It uses theREPLACEMENT_METHOD_MAP to map the strings in replacements in the SRF file to the appropriate functions in the class.

It uses an instance of CHttpResponse declared as a member variable of the CRequestHandlerT to generate replacement text for the tag. Let's modify the wizard-generated code to display pi to the number of digits specified in the query string of the HTTP request. dll/Default }} PI = {{Pi}}
We then add a replacement method called OnPi to our existing handler class and apply the[tag_name] attribute to associate this method with the {{Pi}} replacement tag. In the implementation of theOnPi method, we retrieve the number of digits requested from the query string.

IConnectionPointContainerImpl provides the implementation I requested by checking the Support Connection Points check box. CProxy_ICalcPiEvents is part of the connection point implementation. IDispatchImpl provides the implementation of IDispatch needed for the object's dual interface. The other important thing to note here is the COM_MAP macros. This is an instance of an ATL map: a set of macros that generate code (typically to fill in a lookup table). The COM_MAP, in particular, is used to implement theQueryInterface method that all COM objects are required to support.

Download PDF sample

Rated 4.46 of 5 – based on 20 votes