Abstract class
An abstract class is a class intended as a base for subclasses, often not directly instantiable, that can provide shared implementation and declare operations subclasses must implement.
.NET in Action, Second Edition
An abstract class is a C# class that may contain incomplete implementations and cannot be instantiated directly.
- How it is used
- Contrasts abstract classes with interfaces when explaining reusable object-oriented designs and inheritance constraints.
- How deep it goes
- Defines incomplete implementations and instantiation constraints, but stops short of a worked abstract-class implementation.
- What you can do after
- Evaluate whether a shared base class or multiple interfaces better fits an object-oriented design.
Read how .NET in Action, Second Edition explains abstract class →
Practices of the Python Pro
An abstract base class is a class intended to define a common interface or behavior for subclasses and that may prevent direct instantiation until required methods are implemented.
- How it is used
- Defines interface-like contracts that make inheritance and composition more robust.
- How deep it goes
- Explains declaration, enforcement, examples, and signature concerns, but leaves decorators and runtime signature checking largely unexplained.
- Examples
- Uses Predator subclasses and a Command hierarchy to demonstrate required methods and consistent execute signatures.
- What you can do after
- Build it from scratch with Python's abc module, require subclass methods, and refactor command classes around a shared interface.
Read how Practices of the Python Pro explains abstract class →
The Well-Grounded Python Developer: How the pros use Python and Flask
An abstract class is a class intended to define shared structure or behavior without being instantiated directly.
- How it is used
- Structures related classes around shared behavior while supporting specialized child implementations.
- How deep it goes
- Explains inheritance relationships and progressive shape examples, but does not detail abstract-class enforcement mechanisms.
- Examples
- Uses ParentClass and ChildClass listings, then develops Shape, Rectangle, Square, and Circle drawing classes.
- What you can do after
- Apply it via Python inheritance to organize shared attributes and behavior across related classes.
100 C++ Mistakes and How to Avoid Them
An abstract base class is a C++ base class intended to define behavior for derived classes and not to be instantiated directly.
- How it is used
- Uses an abstract interface to organize substitutable shape types and prevent misleading inheritance chosen merely for code reuse.
- How deep it goes
- Explains pure virtual behavior, class invariants, and substitutability through contrasting C++ designs.
- Examples
- Uses Shape, Rectangle, and Square, contrasting a valid sibling hierarchy with improper Rectangle–Square inheritance.
- What you can do after
- Evaluate inheritance designs by testing substitutability, defining shared behavior, and preserving each derived class's constraints.
Read how 100 C++ Mistakes and How to Avoid Them explains abstract class →
Software Design for Python Programmers
An abstract superclass is a superclass intended to define shared structure or required behavior without being instantiated directly.
- How it is used
- Defines shared behavior and required subclass responsibilities while preventing incomplete superclass instances.
- How deep it goes
- Explains Python implementation, instantiation rules, inheritance, overrides, and a Template Method application.
- Examples
- Uses MotorVehicle with Car and Truck, plus GameReport with baseball and volleyball report subclasses.
- What you can do after
- Build abstract Python hierarchies that share implementation while enforcing subclass-specific methods.
Read how Software Design for Python Programmers explains abstract class →
Essential TypeScript 5, Third Edition
An abstract class is a class that can define shared members while preventing direct instantiation and requiring derived classes to implement designated abstract members.
- How it is used
- Structures shared class behavior while enforcing subclass-specific implementations.
- How deep it goes
- Explains declarations, inheritance, type usage, type guarding, interface reuse, generics, and the compile-time-only runtime restriction.
- Examples
- Uses Person, Employee, Customer, Supplier, AbstractDogOwner, and generic collection subclasses as implementation examples.
- What you can do after
- Build it from scratch by defining shared implementations and abstract requirements for concrete TypeScript subclasses.
Read how Essential TypeScript 5, Third Edition explains abstract class →
Related concepts
- contractincludes · An API contract is a specification of the operations, data, and behavioral expectations that govern interactions between software components.
- classkind of · A class is a programming-language construct that defines a type’s structure or behavior and provides a basis for creating or representing objects.
- interfacecontrasts with · A software interface is a contract or boundary that specifies the operations, properties, or capabilities through which types or components interact, without requiring a particular implementation.
- abstractmethodconfigured by · abstractmethod is a decorator from Python's abc module that marks a method as abstract and requires concrete subclasses to implement it.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.





