“Interface Design for Modern C++” is a two-day training course with programming examples taught by Bob Steagall. It is offered at the Meydenbauer Conference Center from 9AM to 5PM on Saturday and Sunday, September 22nd and 23rd (immediately prior to the conference). Lunch is included.
Let’s face it: writing an elegant, reusable C++ API can be a daunting task. There’s an overwhelming amount of instructional material that describes how to use individual language and library features, but not nearly as much explaining how to craft effective interfaces. You recognize that APIs are a critical aspect of your code, and you’d like to provide your users with a great experience, but how?
Interface Design for Modern C++ will provide practical tips and guidance for achieving this goal. This course is designed for advanced beginners and intermediate-level C++ programmers who have a solid grasp of language and library fundamentals, and now want take their skills to the next level and create interfaces for others.
We’ll learn about desirable API characteristics to pursue, and common mistakes to avoid. We’ll study which language features to use, and how to use them, in order to create C++ interfaces that are elegant, easy to learn, robust, and reusable. Along the way we’ll review examples of a few good and not-so-good interfaces, and practice designing some APIs of our own.
Join us for two days of stepping back from the language feature trees, and thinking about the API forest!
Participants should have advanced beginner to intermediate knowledge of C++14 and the standard library, including a good understanding of copy semantics, move semantics, inheritance, virtual functions, exceptions, lambdas, and some experience with templates. Experience with multi-threading is a plus, but not required.
There will be several API development exercises, so participants should bring a laptop with their favorite C++ IDE or editor, as well as a C++14 or C++17 compiler.
- The business case for a well-designed API
- Characterizing a good API
- Recognizing a bad API – anti-patterns,
- A taxonomy of API styles
- A process for API design
- Principles of type design
- Key C++ idioms and patterns to know, and anti-patterns to avoid
- Choosing the right C++ language and library features for your API
- Designing for extensibility
- Performance considerations
- Versioning considerations
- Documentation and testing practices
- Deliverables and release models
- Case studies of good, bad, and questionable C++ APIs
- API design exercises
Bob Steagall has been working primarily in C++ for the last 25 years. The majority of his career has been spent in medical imaging, where he led teams building applications for functional MRI and CT-based cardiac visualization. After a brief detour through the worlds of DNS and analytics, he’s now working in the area of distributed stream processing. Bob is an active member of the C++ Standardization Committee, and recently launched a blog to write about C++ and related topics. He holds BS and MS degrees in Physics, and is an avid cyclist when weather permits.