| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"> |
| <html> |
| <head> |
| <meta name="copyright" content="Copyright (c) IBM Corporation and others 2000, 2005. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." > |
| <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> |
| <meta http-equiv="Content-Style-Type" content="text/css"> |
| <meta name="GENERATOR" content="Mozilla/4.75 [en] (Windows NT 5.0; U) [Netscape]"> |
| <title> |
| Creating a top-level interface |
| </title> |
| <link rel="stylesheet" href="../book.css" charset="ISO-8859-1" type="text/css"> |
| <script language="JavaScript" src="PLUGINS_ROOT/org.eclipse.help/livehelp.js"> </script> |
| </head> |
| <body> |
| <h1> |
| Creating a top-level interface |
| </h1> |
| <p> |
| You can create interfaces that are not enclosed in other types. |
| </p> |
| <ol> |
| <li> |
| Open the |
| <a class="command-link" href='javascript:executeCommand("org.eclipse.ui.newWizard(newWizardId=org.eclipse.jdt.ui.wizards.NewInterfaceCreationWizard)")'> |
| <img src="PLUGINS_ROOT/org.eclipse.help/command_link.png"> |
| <strong>New Java Interface</strong></a> wizard. |
| </li> |
| <li> |
| Edit the <strong>Source Folder</strong> field as needed to indicate in which folder you want the new interface to reside. You can either type a path |
| or click the <strong>Browse</strong> button to find the folder. If a folder is found for the current selection, that folder appears in |
| the <strong>Source Folder</strong> field as the container for the new interface. |
| </li> |
| <li> |
| In the <strong>Package</strong> field, type a name or click <strong>Browse</strong> to select the package where you want the |
| new interface to reside. If you want the new interface to be created in the default package, leave this field empty. |
| </li> |
| <li> |
| Clear the <strong>Enclosing type</strong> checkbox. |
| </li> |
| <li> |
| In the <strong>Name</strong> field, type a name for the new interface. |
| (Optionally, in a 5.0 project, add type parameters enclosed in <strong><</strong> and <strong>></strong>). |
| </li> |
| <li> |
| Select the <strong>public</strong> or <strong>default</strong> access modifier using the <strong>Modifiers</strong> radio buttons. |
| </li> |
| <li> |
| Click the <strong>Add</strong> button to add interfaces for the new interface to extend. |
| (Optionally, in a 5.0 project, add type arguments enclosed in <strong><</strong> and <strong>></strong>). |
| </li> |
| <li> |
| Click <strong>Finish</strong>. |
| </li> |
| </ol> |
| <p> |
| <img src="../images/ngrelc.png" alt="Related concepts" border="0" > |
| </p> |
| <p> |
| <a href="../concepts/concepts-3.htm">Java projects</a> |
| </p> |
| <p> |
| <img src="../images/ngrelt.png" alt="Related tasks" border="0" > |
| </p> |
| <p> |
| <a href="tasks-21.htm">Creating a new Java interface</a><br> |
| <a href="tasks-24.htm">Creating a nested interface</a><br> |
| <a href="tasks-25.htm">Creating a new interface in a compilation unit</a><br> |
| <a href="tasks-94.htm">Renaming a type</a> |
| </p> |
| <p> |
| <img src="../images/ngrelr.png" alt="Related reference" border="0" > |
| </p> |
| <p> |
| <a href="../reference/ref-127.htm">New Java Interface wizard</a><br> |
| <a href="../reference/ref-3.htm">Java Toolbar actions</a><br> |
| <a href="../reference/ref-view-package-explorer.htm">Package Explorer</a> |
| </p> |
| |
| </body> |
| </html> |
| |