GoF + идиомы C++GoF + C++ idioms

Паттерны проектированияDesign patterns

23 классических паттерна Gang of Four (Creational/Structural/Behavioral) плюс отдельная категория C++-специфичных идиом (RAII, PImpl, CRTP и другие), которых у GoF не было, но которые реально спрашивают на C++ собеседованиях. Каркас: 4 категории, 30 паттернов, страницы фич ещё не написаны.The 23 classic Gang of Four patterns (Creational/Structural/Behavioral) plus a separate category of C++-specific idioms (RAII, PImpl, CRTP, and others) that GoF never had but that genuinely come up in C++ interviews. Skeleton: 4 categories, 30 patterns, feature pages not yet written.

ПорождающиеCreational

как создаются объектыhow objects get created

СтруктурныеStructural

как объекты и классы компонуютсяhow objects and classes compose

ПоведенческиеBehavioral

как объекты взаимодействуют и распределяют ответственностьhow objects interact and distribute responsibility
Chain of Responsibilityпередача запроса по цепочке обработчиковpassing a request along a chain of handlers Commandинкапсуляция запроса как объекта (undo, очередь задач)encapsulating a request as an object (undo, task queues)interview Interpreterпредставление грамматики языка как иерархии классовrepresenting a language's grammar as a class hierarchy Iteratorпоследовательный доступ к элементам без раскрытия структурыsequential access to elements without exposing the structureinterview Mediatorинкапсуляция взаимодействия объектов в отдельном посредникеencapsulating object interaction in a separate mediator Mementoсохранение и восстановление внутреннего состояния объектаcapturing and restoring an object's internal state Observerуведомление зависимых объектов об изменении состоянияnotifying dependents when state changesinterview Stateизменение поведения объекта при смене внутреннего состоянияchanging an object's behavior when its internal state changesinterview Strategyвзаимозаменяемые алгоритмы за общим интерфейсомinterchangeable algorithms behind a common interfaceinterview Template Methodскелет алгоритма в базовом классе, шаги — в подклассахan algorithm's skeleton in a base class, steps in subclassesinterview Visitorновая операция над структурой объектов без изменения их классовa new operation over an object structure with no class changes

Идиомы C++C++ idioms

того, чего не было у GoF, но реально спрашиваютnot in GoF, but genuinely asked about

статусstatus

Это каркас: 4 категории и 30 паттернов зафиксированы, страницы фич ещё не написаны. Метка interview отмечает паттерны, которые чаще всего встречаются на технических собеседованиях. Идиомы C++ логично читать после освоения смежных тем из stl/ — RAII после cpp11/unique-ptr.html, CRTP до или вместе с cpp23/deducing-this.html (deducing this во многом снимает часть болей, которые раньше решались через CRTP).This is a skeleton: 4 categories and 30 patterns are locked in, feature pages not yet written. The interview tag marks the patterns that come up most often in technical interviews. The C++ idioms are naturally read after the related topics in stl/ — RAII after cpp11/unique-ptr.html, CRTP before or alongside cpp23/deducing-this.html (deducing this relieves much of the pain CRTP used to solve).