Programming Best Practices for Technical Writers – Abstraction

This is the third post in a series focused on the core principles of programming best practices for technical writers. The previous post covered inheritance and touched on abstract classes. In this one, we’ll dive deeper into the concept of abstraction.

Abstraction involves hiding the complex implementation details of a system and presenting only the essential features that are relevant to the user or other parts of the system. It allows programmers to simplify interactions by focusing on what objects do rather than how they work. By exposing only the necessary methods and attributes, abstraction helps create simple interfaces for complex systems. The user doesn’t need to know how the methods are implemented behind the scenes.

Common ways to implement abstraction include:

ConceptDescription
Abstract ClassesAbstract classes provide a base for other classes to inherit from but cannot be instantiated directly. They can include both fully implemented methods and abstract methods (methods without implementation) that must be defined by subclasses.
InterfacesAn interface defines a contract by specifying a set of methods that a class must implement. It does not provide any method implementations—just the method signatures—allowing different classes to share the same design.

    Example

    Think about driving a car. You don’t need to understand how the engine works, how fuel is ignited, or how the transmission operates. You only interact with the controls: the steering wheel, pedals, and gear shift. In this analogy, the controls are the abstract interface, while the engine and transmission are the hidden details.

    By mastering abstraction, technical writers can explain the “what” and “why” of a system without overwhelming readers with the “how.” This makes content more accessible, especially for non-technical audiences, and helps manage complexity by offering a clear and simplified way to understand a system.

    These are the basics of abstraction. In the next post, we’ll explore the topic of reusability.

    2 thoughts on “Programming Best Practices for Technical Writers – Abstraction

    Leave a comment