dev@glassfish.java.net

Re: java.* - import first or last?

From: Santiago Pericas-Geertsen <Santiago.PericasGeertsen_at_oracle.com>
Date: Thu, 9 Dec 2010 15:41:22 -0500

On Dec 9, 2010, at 3:21 PM, Bill Shannon wrote:

> Santiago Pericas-Geertsen wrote on 12/09/2010 06:52 AM:
>>
>> On Dec 9, 2010, at 1:13 AM, Bill Shannon wrote:
>>
>>> But I see a bunch of code that imports the java.* classes last.
>>>
>>> Why?
>>
>> The "fix imports" option in NB sorts these alphabetically, resulting in com.*, then java.* and then org.*. That may be one of the reasons. Eclipse does a better job, and I think someone wrote a NB plugin for this. I like java.* first too.
>
> Got a pointer to the NB plugin?
>
> I've been sorting by java.*, org.*, com.sun.*.

http://netbeans.dzone.com/import-statement-organizer

-- Santiago