📄 intro.htm
字号:
EC++ CD: IntroductionIntroduction to the CDWelcome to the Effective C++ CD!I know you're in a hurry, so I'll get right to the point. Please read this entire document. It describes unique features (like the "" symbol and the "" symbol) and provides important tips (such as how to make bookmarking work). It also contains:Background information on why this CD exists. A summary of the C++ material on the CD. Navigational information. You're never more than two clicks from anywhere, but you need to know where to click. Strategies for searching.You can search the CD in three different ways. You need to understand the strengths and weaknesses of each. Instructions for setting your preferences. You have control over more things than you're used to. Link information. You need to be aware of the different types of links on the CD. You also need to know how to generate accurate bookmarks and to create links into the material on the CD. How you can approximate the ability to add annotations to the CD. Information on how to run the CD off a hard drive. Acknowledgments. Take a moment to read about the people who helped me create this product. A way to provide feedback. I know you'll think of things that would improve this CD. I want to hear about them.Reading about these topics won't take that long, and besides, you only need to do it once.BackgroundI've been interested in making my C++ books electronically available for many years, but it became practical only recently. The emergence of HTML as a standard for representing on-line information eliminated the problem of choosing a distribution format, and the dominance of web browsers from Netscape and Microsoft made it possible to restrict the platforms on which electronic documents had to be tested.1 In addition, the latest versions of these browsers support features that can lead to a truly compelling reading experience.Still, I'm from the Old School of publishing: I like printed books. I like being able to jot notes in the margins, I like being able to fold down the edges of important pages, and I especially like the look of text on paper. (Printed text may have a resolution of 2000 dpi or more, but computer monitors are lucky to muster a twentieth of that.) Most important of all, I like the fact that books stand by themselves; you don't need a computer to read them. Some people believe printed books will go the way of the dinosaur, but I'm not one of them.At the same time, printed books are limited in ways electronic books aren't. Printed books can be heavy and bulky, but a single CD can hold thousands of pages of text. It's hard to search printed books, but electronic books can be searched in many ways. It's difficult to link hardcopy books together, but books in HTML are designed to be linked together (both by their authors and by their readers). Most printed books are limited to a single ink color, but electronic books can use scores of colors as easily as they use one. Printed books are restricted to text and static images, but electronic books can add animations, movies, sounds, and programs. Printed books present the same interface to everybody, but electronic books can be tailored to the preferences of their readers.Hardcopy and electronic books are simply different. They don't compete with one another, they complement one another. I know from personal experience that sometimes I want a printed book, but other times I want an electronic version of the same information. As the author of Effective C++ and More Effective C++, I've had access to (and used) both forms for years. With this CD, I'm finally able to offer you the same flexibility I've enjoyed since 1991.Technical ContentThis CD features copies of both Effective C++, Second Edition, and More Effective C++, but that encompasses more material than you may think. Each book has always offered extensive internal cross references, but on this CD I was able to add dozens of cross references between the books. In Item 10 of Effective C++, for example, I explain how you might write a custom version of operator new, but I cover related memory management material in Item 8 of More Effective C++. There are now links between these Items, and I can't tell you how happy I was to be able to add them. I've wanted to put them there ever since I wrote More Effective C++, but I couldn't do it in the printed books, because I was unwilling to assume that a reader of one book had access to the other. With both books on this CD, that issue vanished, and I was thrilled to be able to add the many between-book links that have always existed in my mind.This CD also contains a comprehensive index of the material in Effective C++ and More Effective C++. Formed by merging the three independent indices found in the paper books, it provides an easy way to find material on any topic in either (or both) books. However, the index is only one way to find what you're looking for. We've gone to great lengths to facilitate searching the CD, so you're no longer constrained by what I decided was worth indexing. If a word or phrase appears anywhere on this CD (except as a stop word), you can find it.In addition to the books, I've included several magazine articles that build on material covered in Effective C++ or More Effective C++. I wrote or helped write some of the articles, but others notably those on exception handling were written by such luminaries as Tom Cargill, Jack Reeves, and Herb Sutter. I added links among these articles and my books, and I hope you'll agree that the result is greater than the sum of its parts.Finally, you'll find some links between material on this CD and related material on the Internet. In essence, this CD is a web site, and as such it's only natural that it contains links to other places in cyberspace. As John Donne might have put it, no web site is an island, entire of itself. This CD, though functionally self-contained, is no exception to that rule. (See below for information on how links to the Internet are handled.)Much to my regret, you won't find a copy of the official ISO/ANSI standard for C++ on this CD. I wanted to include a copy, but it turned out that the attendant licensing fees would have increased the price of the CD by 25%-30%, and I just didn't think it was worth it. Never fear, however. I've provided the following link to a web-hosted copy of the latest publicly available draft of the C++ standard. That's not as convenient as having the standard on this CD, of course, but it's almost as good, and it's a lot less expensive.Navigating the CDYou're never more than two clicks away from anything on this CD. Furthermore, you've always got immediate access to both books, the Books' Index, the collection of magazine articles, the comprehensive search engine (described below), control over the configuration of your viewing preferences (also described below), this Introduction, and the CD's Home Page.The key to this access is the column at the left of your browser window, the CD's Navigation Area. Regardless of where you are on the CD, clicking on the appropriate button in the Navigation Area always takes you to the Effective C++ Home Page, the More Effective C++ Home Page, or the Magazine Articles Home Page. Each of these pages displays the corresponding table of contents, so from there you can jump directly to any book Item or magazine article.For example, suppose you're somewhere anywhere on the CD and you're overcome with an urge to read Item 22 of Effective C++. No problem, just click on the Effective C++ button in the Navigation Area, then select Item 22 from the book's table of contents. Or suppose you just have to reread my magazine article on counting objects. Simply click on the Magazine Articles button in the Navigation Area, then choose that article from the list.If you don't know exactly where you want to go, you'll probably want to search for the information you desire. As you'll soon see, there are different ways to search, and you have constant access to all of them. The Navigation Area gives you direct access to the Books' Index and the search applet, and of course your browser's built-in search command is always available.If you have access to a printed copy of Effective C++ or More Effective C++, you may find it convenient to jump to particular book pages. That's easy to do. The Navigation Area for each book contains a field where you can enter the page number you want. Just type the number and hit Enter (or click on the "GO" button). Voil! You'll be there. (More or less. Remember that your browser determines line breaks on the fly.) To jump to page 99 of More Effective C++, for example, go to the Home Page for that book, type 99 in the "GO" field in the Navigation Area, and hit Enter. That's all there is to it.I've put thousands of links on this CD, so it's natural to worry that after jumping among book Items, magazine articles, bookmarks (see below), and various CD-related documents (such as this one), you'll lose track of where you are. Relax. The color of the Navigation Area changes depending on where you are, as does the image at the top of the Navigation Area and the caption below the image. You'll quickly learn to recognize your surroundings without even thinking about it.SearchingThere are three ways to search for information on this CD:Use the Books' Index. As the sole search mechanism put together by a human (me), it offers your only chance of finding information using terms not specifically located in the text. For example, Item 43 of Effective C++ discusses how the use of virtual inheritance can increase the size of objects, but it never uses the word "efficiency" in that discussion. Nevertheless, you'll find a link to that material in the index's entry under "efficiency."The primary drawback to the Books' Index is that it references only material in the books. If you're looking for something covered in a magazine article or in this Introduction to the CD, for example, the index won't help you.Getting to the Books' Index is always easy. Just click on "Index" in the CD's Navigation Area.Use your browser's search function. Your browser offers a search command for finding strings in the document it's currently displaying. It even knows how to do fancy things like let you search for "vector<int>" when the underlying HTML contains "vector<int>". ("<" and ">" are special characters in HTML, so they're encoded as "<" and ">", respectively.) More importantly, your browser will highlight the text it finds, something none of the other search mechanisms can do. Such highlighting makes it easy to see what you've found.The big drawback to browser-based searches is that they work on only the current file. It's not practical to put all the information on this CD in a single file, so there's a trade-off to be made. Bigger files support more complete browser-based searches, but the files take longer to load and demand more memory. Smaller files load faster and use less memory, but they yield more limited browser searches. To resolve this dilemma, I decided to let you make the call. This CD contains three copies of each book, each broken down into files of different sizes, and you choose the granularity you like best. For details, see the information below on configuring your preferences.Use the search applet. This CD includes a Java applet that's able to perform full-text searches of the entire disc. For all the details on using the search applet, take a look at its help page. (Please do read the help page. It contains information that will affect you. Honest.) To invoke the search applet, just click on "Search" in the CD's Navigation Area.Generally speaking, you should use the Books' Index if you want the benefits of a human-compiled index and you know that the information you're looking for is in Effective C++ or More Effective C++. Use a browser-based search if you know which file contains the information you're looking for and you have a specific string you want to find. Use the search applet if you need to search the entire CD.Setting Your Preferences
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -