Telerik® JustCode™ by Progress

The Extract Interface refactoring allows you to define a new interface from selected class or interface members. It also allows you to select already inherited interfaces and effectively make the new interface inherit from them.

Executing the refactoring results in a new interface been created by Telerik® JustCode™ containing the selected members from the target class. There is an option to create a file for the new interface with the name of the file.

You can use the refactoring to define an empty interface by not selecting any member. It is allowed to select members regarding their visibility and any not public members will automatically have their visibility converted to public after the refactoring completes.


Language Support

Supported: C#, VB.NET

Not supported: JavaScript

Not relevant: ASP.NET, XAML, HTML


The command is not available for static and generic types.

To extract an interface

  1. Select the class or interface identifier you want to extract.

    Extract Interface.Select.Class
  2. Press Alt+Insert. From the pop-up menu select Extract Interface.

  3. Enter a name for the new interface.

  4. Choose if the interface will be created in a new file.

  5. Select a one or more members to be extracted or leave empty for a new empty interface.

    Extract Interface.Select.Members
  6. Press Enter to finish or Esc to abort the operation.
  7. The result is

    Extract Interface.Result

To extract a interface you can also navigate on the main menu. Choose JustCode | Refactor | Extract Interface, or through Visual aids menu.

See Also