US / UK-EMEA / Contact Ask DevelopMentor a Question800.699.1932

Designing and Implementing Effective C++ Classes Training

(FW296) 1 Day Course, $995
 
Upcoming Classes:

What You Will Learn

Course Highlights

Course Details

Dates & Locations

This seminar, based on Scott's award-winning Effective C++, covers the most important material that every professional C++ developer needs to know to be truly effective with the language.

What You Will Learn

Course Highlights

Course Details

Dates & Locations

Participants will gain:
  • Mastery of the crucial member functions applicable to every class.
  • Understanding of the resource acquisition is initialization (RAII) technique for managing resources.
  • Insights into the differences among member functions, non-member functions, virtual functions, and non-virtual functions.
  • Knowledge of the rules of thumb applied by expert programmers as they design and implement software systems in C++.

Format: Lecture and question/answer. There are no hands-on exercises, but participants are welcome to use their computers to experiment with the course material as it is presented.

What You Will Learn

Course Highlights

Course Details

Dates & Locations

  • Fundamental Concepts and Functions:
    • Use objects to manage resources
      • Resource acquisition is initialization (RAII)
      • std::auto_ptr
      • std::tr1::shared_ptr
    • TR1 and Boost
    • Think carefully about copying behavior in resource-managing classes
    • Know what functions C++ silently writes and calls
    • Explicitly disallow use of implicitly generated member functions you don't want:
      • Declaring functions private
      • Inheriting from a base class declaring them private
    • Handle copying in classes with pointers:
      • Handling the functions yourself
      • Using resource-managing objects
    • Make destructors virtual in base classes
      • Virtual functions and object layout
    • Strive for exception-safe code
      • Definition of "exception-safe"
      • The basic, strong, and nothrow guarantees
        • Exception specifications and exception-safety guarantees
      • Approaches to the strong guarantee
        • Careful statement ordering
        • Copy and swap
      • Dependencies among exception-safety guarantees
  • Overloading Operators:
    • Handle assignment to self in operator=:
      • The problem of aliasing
      • Checking for assignment to self
      • Using resource-managing objects
      • Self-assignment and exception-safety
        • Copy and swap again
    • Assign to all data members in operator=:
      • Partial assignments
      • The problem of inheritance
        • The copy construction analogue
  • Inheritance and Object-Oriented Design:
    • Make sure public inheritance models "isa"
      • Inheritance and intuition
      • Runtime vs. compile-time error detection
      • Inheritance and substitutability
    • Differentiate between inheritance of interface and inheritance of implementation:
      • The meaning of pure virtual functions
      • The meaning of "impure" virtual functions
      • The meaning of nonvirtual functions
        • Never redefine an inherited nonvirtual function
    • Model "has-a" or "is-implemented-in-terms-of" through containment
  • Sources for Additional Information

What You Will Learn

Course Highlights

Course Details

Dates & Locations

Upcoming Dates & Locations

There are no upcoming scheduled engagments of this course. We can schedule an on-site event at your convenience.
Ready?
Connect
Signup for our Free Newsletter!
Latest news
Twitter Feed MORE
Got an email from a developer in Holland about my Onion Architecture blog post http://t.co/Z5DTvJob Nice to have a worldwide audience! #dm
1 day ago (details)
There is something to this statement: Why Quit? Because They Have Bigger Monitors http://t.co/9FrGETG5 #dm (via @mkennedy)
2 days ago (details)
Testimonials
  • Llewellyn Falco’s visit was nothing short of magnificent. His expertise has me tracking much straighter now - doing things faster than I dreamed possible. Phil H.