Java Reference
In-Depth Information
Figure 5.20 The Run/Debug Configuration drop-down selector on
the main toolbar lets you choose a configuration and then run or
debug it. The selector also contains an entry that lets you edit
those configurations.
If you've created a Run/Debug configuration for the file you're currently
editing, you can also right-click in the editor and select
Run
from the
context menu to execute it.
TIP
Using temporary configuration profiles
Occasionally, you'll want to run or debug a class without having to bother with
defining a new configuration profile for it in your project. You may do this for
infrequently run applications or while testing new code that you don't intend to
run again. You do so by right-clicking inside the editor or on a file in the
Project
window and selecting the
Run
(or
Debug
) option. This action adds a temporary
configuration profile to the project, using the default application settings, and
immediately executes it.
Temporary configuration profiles appear with a ghosted icon and lighter
color font in the
Run/Debug
drop-down list on the main toolbar and in the
Run/
Debug Configurations
dialog. They work the same as any other configuration
profiles. If you need to change arguments or settings, you can do so through the
Run/Debug Configurations
dialog.
To convert a temporary configuration profile to a permanent one, you can use
any of these three methods:
Select the
Save <<
Class Name
>>
option at the bottom of the
Run/Debug
drop-down list on the tool bar.
■
Click the
Save Configuration
button in the
Run/Debug Configurations
dialog.
■
Select the
Save <<
Class Name
>>.main()
option in the context menu
when the class is opened in the main editor window.
■