From: SourceForge.net <no...@so...> - 2004-06-28 21:17:37
|
Feature Requests item #981575, was opened at 2004-06-28 14:17 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=438938&aid=981575&group_id=44253 Category: Definitions (source editor) Group: Small (< 1 pair-week) Status: Open Priority: 5 Submitted By: Neal Horowitz (nrhorowitz) Assigned to: Nobody/Anonymous (nobody) Summary: enums and automatic file naming Initial Comment: Story: A user creates a new file, and types the following simple code into the definitions pane: public enum MyEnum { ..first, second, third } The user then choose the save command, and the file chooser appears with the name MyEnum already in the "File Name" field, as DrJava has inferred from the enum declaration that this filename is required for the file. I would say the simplest way to do this is to extend the "getFirstTopLevelClassname" logic in DefinitionsDocument, though this would have the disadvantage of ambiguating enum and regular class definitions. (Though, that might not really be a disadvantage, as enums are actually classes...) As a note, the current logic for inferring filename from class declarations does not care about public/non-public classes, so it's probably not very important for enums either -- see feature request #981571, which applies equally to enums as regular classes. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=438938&aid=981575&group_id=44253 |