Create Declaration and Create Implementation (C++)
Go Up to Refactor Menu
Create Declaration
Refactor > Create Declaration
The Create Declaration feature creates a missing method declaration.
To use this feature, follow the steps below:
- Place the cursor in the name of the method for which you want to create its declaration.
- Go to the Refactor option of the main menu.
- Select Create Declaration.
For example, in a .cpp file, you could write a new method implementation:
String std::vector(int index) {
}
In the code editor, place your cursor in vector
(the text) and invoke Create Declaration. The class std
gets a new method vector
.
Create Implementation
Refactor > Create Implementation
The Create Implementation feature creates a missing method implementation.
To use this feature, follow the steps below:
- Place your cursor inside the method name in the class to create its implementation.
- Go to the Refactor option of the main menu.
- Select Create Implementation.
For example, in a class declaration, you can write a new method and create its implementation by placing your cursor inside the class and invoking Create Implementation.
In the animated GIF case, if you place your cursor in the Bar
method, you create an empty Foo::Bar
method, in the corresponding .cpp
file.