• Increase font size
  • Default font size
  • Decrease font size

Class & API Design

by martin on April 29th, 2011

Michael DeHann wrote a blog article relating some of the things he’s learned about good API design. This includes advice such as programming with a view to the outsider, naming classes appropriately, figuring out how to make your code better through experiencing bad code, provide documentation that obviates the need for users to ask you how your code works, avoid redundant code, avoid extraneous conversions where possible, keep logic with the class that owns it, avoid adding complexity to your code through many options, and finally test your code but focus on functional end-to-end tests.

Many of these design tips are not new, but Michael provides a fresh perspective on them that I think is worth reading. Check out his post at:

From → Design

Comments are closed.


An Application Programming Interface (API) provides a logical interface to a piece of software and hides its internal details. This website is dedicated to a book on designing APIs for C++ and includes articles and links on API development.


The book is accompanied by a source code package that contains many of the examples in the text. Download it for free.


Dr. Reddy has also published a computer graphics book called Level of Detail for 3D Graphics. Check it out too!.
Copyright (c) 2024 Martin Reddy. All rights reserved. Login