Implement an Interface

How to implement unexported interfaces.

GoLand offers the option to quickly implement an interface using the Implement methods action. Starting with GoLand 2023.1, this action works with exported and unexported interfaces.

Click the type and press ^I (macOS) / Ctrl+I (Windows/Linux). In the search field, type a name of the interface that you want to implement.


Related Resources

Create a Function in Another Package
Create a Function in Another Package
Type a non-existing function name and generate its implementation in a package of your choice.
Empower your `Printf`-like functions with coding assistance
Empower your `Printf`-like functions with coding assistance
Provide hints and highlights for message formats in custom `Printf`-like functions.
Check for Vulnerabilities
Check for Vulnerabilities
Analyze your codebase and highlight known vulnerabilities in go.mod