Implement Pure Virtuals
What: Generate the code required to implement all pure virtual methods in a class.
When: You want to inherit from a class with pure virtual functions.
Why: You could manually implement all pure virtual functions one-by-one, however this feature will generate all method signatures automatically.
How:
Place your text or mouse cursor over the class in which you want to implement the pure virtual functions of the base class.
Next, do one of the following:
- Keyboard
- Press Ctrl+. to trigger the Quick Actions and Refactorings menu and select Implement all Pure Virtuals for class 'ClassName' from the context menu, where ClassName is the name of the selected class.
- Mouse
- Right-click and select the Quick Actions and Refactorings menu and select Implement all Pure Virtuals for class 'ClassName' from the context menu, where ClassName is the name of the selected class.
- Keyboard
The pure virtual method signatures will be created automatically, ready to be implemented.