Optimize Imports

Optimize Imports is a coding enhancement that makes managing your code easier. When creating an application, you add and remove classes from your code resulting in a list of used and unused import statements at the top of your class. The Optimize Imports capability of JBuilder removes unused imports from your class and rewrites the import sections based on customizable settings.

Listing 7.6 shows a class with imports.

Listing 7.6. Imports in FrameRefactor.java
import java.awt.*; 
import java.awt.event.*; 
import javax.swing.*; 
import com.borland.jbcl.layout.*; 
import jbbook.ch07.move.*; 
import jbbook.ch007.*; 

From the context-sensitive pop-up menu, select Optimize Imports. JBuilder evaluates your class and optimizes the import ...

Get Borland® JBuilder™ Developer’s Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.