Eclipse creates Java interface
Open the New Java Interface Wizard
The New Java Interface Wizard can create a new Java interface. The ways to open the wizard are:
Click the File menu and select New > Interface
Right-click the mouse in the Package Explorer window and select New > Interface
In the drop-down box button on the toolbar () select ()
Open Create Before entering the Java Interface Wizard, it is best to select the package name to which the Java interface belongs, so that the package name field will be automatically populated when creating the Java interface.
Use the New Java Interface Wizard
In the pop-up window of the Java Interface Wizard, you can perform the following operations:
Confirm the folder name ( Source Folder) and package name (Package) are correct
Enter the interface name
Click the Add button and select the interface to be The interface will be inherited
Select whether to automatically generate comments
Click the Finish button
View the new java interface
We can see the new interface in the Package Explorer view, and we can modify the interface code through the Java editor on the right.