TOC PREV NEXT INDEX



The Sourcerer's Apprentice


The Sourcerer's Apprentice lets the user quickly view and select from the available methods and fields in a class. This feature is invoked from the menubar or popup-menu, or by pressing Ctrl-Space or F1. When this is done, the Sourcerer's Apprentice takes the Java identifier to the left of the cursor and determines its class. It then displays a dialog showing all the methods and fields in that class. The user can select a method or field which will then be displayed at the bottom of the dialog. If a method is selected, default arguments will be provided. The user can edit this code if they wish. When the OK button is pressed, this code will be inserted in the editor at the cursor's position. The Cancel button dismisses the dialog without making any changes to the code.

For example, if a section of code has a String object named 'str', typing str and then pressing Ctrl-Space will launch the Sourcerer's Apprentice. See Figure 2.

If the Sourcerer's Apprentice is invoked next to something which is not an instance of class, it will beep, but not display a dialog box.


Data Representations, Inc.
http://www.datarepresentations.com
support@datarepresentations.com
sales@datarepresentations.com
TOC PREV NEXT INDEX