Bug 20253

Summary: Extend Code Formatter to sort methods
Product: [Eclipse Project] JDT Reporter: Gunnar Wagenknecht <gunnar>
Component: CoreAssignee: Philipe Mulet <philippe_mulet>
Status: RESOLVED DUPLICATE QA Contact:
Severity: enhancement    
Priority: P3    
Version: 2.0   
Target Milestone: 2.1 M5   
Hardware: All   
OS: All   
Whiteboard:

Description Gunnar Wagenknecht CLA 2002-06-13 14:15:34 EDT
Hi!

Maybe you can add a sort feature for methods/variables of a class in code 
formatter? OK, is not possible for 2.0, but I'd like to have it in 2.1 :)

My Suggestion: code formatter should be sort class things (methods, vars) like 
in outline view. I like this sorting (static vars first then static methods, 
then vars and then methods, each group alphabeticaly).

Cu, Gunnar
Comment 1 Dirk Baeumer CLA 2002-06-14 05:12:31 EDT
Nice idea but as you already said this will not make it inot 2.0

Deferrring...
Comment 2 Dirk Baeumer CLA 2002-07-17 11:52:38 EDT
Reopen bug and moving to JDT Core since they own the formatter
Comment 3 Philipe Mulet CLA 2002-07-17 16:52:20 EDT
Unsure this belongs to formatting, as it may change the source in a non-
compatible way. Think of innerclasses which are numbered in declaration order 
X$1, X$2, ... 

Formatting is not changing the semantics of a program, simply the layout.

Would rather need to be a separate operation, which can easily be achieved in 
term of JavaModel APIs.
Comment 4 Philipe Mulet CLA 2002-07-25 08:20:04 EDT

*** This bug has been marked as a duplicate of 14597 ***