BD Software delivers on-site C++ training, Unix training and Java training.

BD Software delivers on-site training seminars for programmers in C, C++, Java, Perl and Unix

On-Site Training Seminar:

 

Advanced C++ Programming

Details of this C++ Training

Standard modules:
I (Recent Language and Library Additions),
II (Template Mechanics),
III (Standard Template Library)
IV (Exception Handling)


Elective modules:
V-X, as selected by client


 

Course Outline:

 

I. Recent Language and Library Additions

    • New-style casts

    • RTTI

    • Namespaces

    • Library Organization

    • Coding for TR1-Compatibility Using Boost

II. Template Mechanics

 

·       Class templates

o      Class template specialization

o      Template implementation

o      Member function templates

·       Function templates

o      Function templates and conversions

o      Overloading function templates    

o      Mixing template and non-templates

·       Implicit template requirements and the role of convention

·       Function template argument deduction and overloading

o      Argument deduction

o      Function template explicit arguments

·       Class template specialization

o      Explicit specialization

o      Partial specialization

o      Member function explicit specialization

·       Non-type template arguments

·       Template template parameters

·       SFINAE and INCINI

·       Explicit instantiation

 

 

III. The Standard Template Library

 

1. Introduction 

·       Purpose and structure of the STL: containers, algorithms, and iterators

·       Review: class and function templates

·       Container classification, characteristics, and content

·       Iterator classification and behavior

·       Generic algorithms and iterators

·       Design of generic algorithms and performance guarantees

·       iostream iterators

2. Generic Algorithms

·       Review: generic algorithms and helper templates

·       Interaction between algorithms and iterators

·       Generic algorithm goals, documentation, and design

·       Sequences, subsequences, and sequence errors

·       Descriptions of STL algorithms

3. Containers

·       Properties, insertion and deletion effects, specific functionality

·       vectors

·       lists

·       maps

·       Containers and exceptions

·       Choosing an appropriate container

·       Container adapters

4. Function Objects

·       Functions and generic algorithms

·       Function objects and generic algorithms

·       Algorithm families

·       Function objects and containers, strict weak ordering

·       Standard function objects

 

IV. Exception Handling

·       The purpose of exception handling

·       Syntax and mechanics of the exception handling mechanism

·       Throwing exceptions

o      throw expressions

·       Handling exceptions

o      try blocks and handlers

o      catch clauses

·       Exception specifications

o      Exceptions and inheritance

o      MI for exception types

o      RAII

o      Hierarchical exceptions

·       Designing exception types

·        Designing for exceptions

o       Catch by reference

o       Exception safety

o       Levels of exception safety

o       auto_ptr

o      Plugging resource leaks

o      Partially constructed objects

o      Resource leaks in constructors

o      Function try blocks

o      Copy assignment idioms

·       More Exception Features

o      terminate and set_terminate

o      unexpected and set_unexpected

o      Mapping exceptions

 

V. Memory Management


·       new and delete operators

·       New handlers

·       Exceptions and memory management

·       Placement new and explicit destruction

·       Member operator new and operator delete

·       Array new and delete operators

 

VI.  Copying, Conversions and Temporaries

    • Assignment and initialization

    • Copy operations and class mechanism

      • Deep vs. shallow copy

      • Compiler-supplied default copy semantics

    • Copying problems

      • Compiler-supplied copy operations

    • Implementing copy operations

      • Bitwise copy

      • Coding copy constructors

      • Assignment in a hierarchy

    • User-defined conversions

    • Unintended conversions and explicit

    • Conversions, temporaries, and efficiency

      • Computational constructors

    • Temporaries and copy construction

      • Direct vs. copy initialization

    • Return value optimizations

    • Conversions, temporaries, and references

    • Temporary lifetime and correctness



VII. C++ Pointers


·       References

o      References are aliases, not pointers

o      Reference initialization

o      Pass by reference

o      References and casting

·       const and pointers

o      Safe and unsafe conversions

o      Const formal parameters

·       const member functions

o      Physical vs. logical constness

o      mutable data members

o      volatile          

o      Casting away const

o      Overloading on const

·       const and references

·       Multilevel pointers and references to pointers

·       Arrays

o      Pointer/array duality

o      References to arrays

o      Arrays of class objects

·       typedef and type sinks

·       The meaning of pointer comparison

·       void * and casting

·       Smart pointers

o      auto_ptr

o      scoped_ptr

o      scoped_array

o      Reference-counting smart pointers

 


VIII. Callable Entities

·       What’s a “C++ Callable Entity”?

·       Pointers to functions

o      Function addresses and void *

o      Pointers to inline functions

o      Pointers to overloaded functions

o      Pointers to function templates

o      Callbacks

·       Function objects

o      Pointers vs. pointers-to-members

·       Function object hierarchies

o      Integrable function objects

·       Helper functions

·       Pointers to member functions

·       Wrapping pointers to member functions

·       tr1::function and tr1::bind

 

 

IX. Advanced Template Programming Techniques

 
    • Template member functions

    • Helping the compiler to parse template code

    • Templated copy-like operation idiom

      • Templated construction and assignment

    • Making new friends idiom

      • Non-template operators

    • The Curiously-Recurring Template Pattern

    • Generic algorithms and abstraction

    • Parameterizing with C++ callable entities

    • Helper function idiom

    • Overloading and specializing function templates

      • Function template partial specialization

    • Nested type information and traits

    • Policy-based design

    • Type algebras and compile time type manipulation

    • Introduction to type lists

    • Introduction to expression templates

 

 

X: Hierarchy Design Idioms

 

    • Data abstraction

      • The Template Method Pattern

      • The Non-Virtual Interface (NVI) idiom

    • Base class member roles

    • Overloading, overriding, and hiding

      • Abstract and concrete classes

    • Hierarchies and polymorphism

      • Static and dynamic binding

    • Conditional code

      • Cosmic hierarchies

      • Hierarchies and reuse

    • Substitutability

    • Totalitarianism, tough love, and reuse

      • Contracts and leveraging generic code

      • Interfaces

      • dynamic_cast

      • Capability queries

    • Degenerate hierarchies

      • Inheritance for code reuse

    • Design for repair

    • Composition of simple hierarchies

    • Abstract bases, slicing, and copying

 

 

 

 

 


Home | Courses | Tools | Resources
Clients | Successes | Contact | Site Map | Links | About Us

All text and images on this website are Copyright © 2001-2003 BD Software.
All rights reserved.


Courses:

C and C++ Seminars

Java Seminars

Unix-Related Seminars


Clients:

Otis Elevator

Lucent

Danzas AEI

(See full
client list)


BD Software delivers on-site training seminars for programmers in C, C++, Java, Perl and Unix