|
|
Amazon Kindle - Jetzt internationaler Versand aus den USA
Entdecken Sie über 250.000 englischsprachige Bücher, Zeitungen und Zeitschriften. Mehr erfahren und bestellen bei Amazon.com in den USA. |
C++ Coding Standards: 101 Rules, Guidelines and Best Practices (C++ In-Depth) von Herb Sutter |
von Nicolai M. Josuttis
|
Exceptional C++: 47 Engineering Puzzles, Programming Problems, and Solutions, engl. Ed. von Herb Sutter |
von Scott Meyers
|
von Scott Meyers
|
Produktinformation
Möchten Sie die Produktinformationen aktualisieren oder Feedback zu den Produktabbildungen geben?
|
The second category consists of busy programmers who need to get the job done without undergoing a steep learning investment. They can skim the most intricate details of implementation and concentrate on using the provided library. Each chapter has an introductory explanation and ends with a Quick Facts section. Programmers will find these features a useful reference in understanding and using the components. The components can be understood in isolation, are very powerful yet safe, and are a joy to use.
You need to have a solid working experience with C++ and, above all, the desire to learn more. A degree of familiarity with templates and the Standard Template Library (STL) is desirable.
Having an acquaintance with design patterns (Gamma et al. 1995) is recommended but not mandatory. The patterns and idioms applied in the book are described in detail. However, this book is not a pattern book it does not attempt to treat patterns in full generality. Because patterns are presented from the pragmatic standpoint of a library writer, even readers interested mostly in patterns may find the perspective refreshing, if constrained.
Loki
The book describes an actual C++ library called Loki. Loki is the god of wit and mischief in Norse mythology, and the authors hope is that the library's originality and flexibility will remind readers of the playful Norse god. All the elements of the library live in the namespace Loki. The namespace is not mentioned in the coding examples because it would have unnecessarily increased indentation and the size of the examples. Loki is freely available to download.
Except for its threading part, Loki is written exclusively in standard C++. This, alas, means that many current compilers cannot cope with parts of it. I implemented and tested Loki using Metrowerks CodeWarrior Pro 6.0 and Comeau C++ 4.2.38, both on Windows. It is likely that KAI C++ wouldnt have any problem with the code, either. As vendors release new, better compiler versions, you will be able to exploit everything Loki has to offer.
Lokis code and the code samples presented throughout the book use a popular coding standard originated by Herb Sutter. Im sure you will pick it up easily. In a nutshell,
Classes, functions, and enumerated types look LikeThis.
Variables and enumerated values look likeThis.
Member variables look likeThis_.
Template parameters are declared with class if they can be only a user-defined type, and with typename if they can also be a primitive type.
Organization
The book consists of two major parts: techniques and components. Part I (Chapters 1 to 4) describes the C++ techniques that are used in generic programming and in particular in building generic components. A host of C++-specific features and techniques are presented: policy-based design, partial template specialization, typelists, local classes, and more. You may want to read this part sequentially and return to specific sections for reference.
Part II builds on the foundation established in Part I by implementing a number of generic components. These are not toy examples; they are components of industrial strength used in real-world applications. Recurring issues that C++ developers face in their day-to-day activity, such as smart pointers, object factories, and functor objects, are discussed in depth and implemented in a generic way. The text presents implementations starting from the needs, the fundamental problems. Instead of explaining what a body of code does, the approach of the book is to discuss problems, take design decisions, and implement those decisions gradually.
Chapter 1 presents policiesa C++ idiom that helps in creating flexible designs.
Chapter 2 discusses general C++ techniques related to generic programming.
Chapter 3 implements typelists, which are powerful type manipulation structures.
Chapter 4 introduces an important ancillary tool: a small-object allocator.
Chapter 5 introduces the concept of generalized functors, useful in designs that use the Command design pattern.
Chapter 6 describes Singleton objects.
Chapter 7 discusses and implements smart pointers.
Chapter 8 describes generic object factories.
Chapter 9 treats the Abstract Factory design pattern and provides implementations of it.
Chapter 10 implements several variations of the Visitor design pattern in a generic manner.
Chapter 11 implements several multimethod engines, solutions that foster various trade-offs.
The design themes cover many important situations that C++ programmers have to cope with on a regular basis. I personally consider object factories (Chapter 8) a cornerstone of virtually any quality polymorphic design. Also, smart pointers (Chapter 7) are an important component of many C++ applications, small and large. Generalized functors (Chapter 5) have an incredibly broad range of applications. Once you have generalized functors, many complicated design problems become very simple. The other, more specialized, generic components, such as Visitor (Chapter 10) or multimethods (Chapter 11) have important niche applications and stretch the boundaries of language support.
![]() |
63% kaufen den auf dieser Seite vorgestellten Artikel: Modern C++ Design, Generic Programming and Design Patterns Applied EUR 32,95 |
![]() |
13% kaufen C++ Coding Standards: 101 Rules, Guidelines and Best Practices (C++ In-Depth) EUR 25,95 |
![]() |
11% kaufen Effective C++: 55 Specific Ways to Improve Your Programs and Designs (Addison-Wesley Professional Computing) EUR 32,95 |
![]() |
7% kaufen C++ Templates: The Complete Guide EUR 40,95 |
Tags, die Kunden mit diesem Produkt verbinden(Was ist das?)Klicken Sie zum Suchen verwandter Artikel, Diskussionen oder Personen auf ein Tag.
|
|
Sagen Sie Ihre Meinung zu diesem Artikel:
|
||||||||||||||||||||||
Die hilfreichsten Kundenrezensionen
Sagen Sie Ihre Meinung zu diesem Artikel: Eigene Rezension erstellen
|
|
|
Das Forum zu diesem Produkt
Fragen stellen. Meinungen austauschen. Neues erfahren.Aktive Diskussionen in ähnlichen Foren
|
Ähnliche Foren
|
|||||||||||||||||||||||||||||||
|
|
|
Sobald Sie sich Produktseiten oder Suchergebnisse angesehen haben, finden Sie diese Seiten zu Ihrer Information hier aufgeführt. |