This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Within one of my programs I have both "javax.swing.text.Style" and "com.shadowcraft.eggshell.Style" defined. Now, since the source-code in question resides within com.shadowcraft.eggshell, I don't need to import com.shadowcraft.eggshell.Style to use it. There is an instance where I specifically refer to javax.swing.text.Style but the import manager removes it (reduces it to "Style") because it sees an import statement exists for javax.swing.text.Style. The import manager should be smart enough to see a FQN is required and not bother adding an import statement for javax.swing.text.Style either.
Import management tool comes from java module.
Another related issue.. 1) originally the code contains: import java.awt.Color; import java.awt.Container; 2) You run IMPORT MANAGER on the current class, contained within package "com.company.project" 3) com.company.project.Color exists, which is why the original code explicitly mentioned "import java.awt.Color" to override the Color found in the current package. 4) After running IMPORT MANAGER, the imports are collapsed into "import.awt.*" which results in com.company.project.Color overriding java.awt.Color This is undesired behavior.
This issue causes code corruption. Upgrading to P2.
You can always use Undo to return to the previous state. In general IMT is not capable to prevent creating of non-compilable code. Lowering priority to P3 - there is easy workaround and the issue itself is corner case. It cannot be easily fixed with current infrastructure, setting Target Milestone to 4.0
Grr.. this issue is getting annoying :) I run into it quite frequently. Specifically, I am implementing javax.sound.sampled.spi.AudioFileReader, my code is called com.shadowcraft.spi.sampled.mod.AudioFileReader The package name is obviously different but I mirror the actual class name after the class I am implementing. In the aforementioned example, I am implementing an AudioFileReader for the MOD audio format. Are we sure we can't get a fix in before 4.0? Is this issue really that difficult to fix?
I am sorry, but this issue will not be fixed in 3.5
Fixed in Nevada Patch 1 and in Arrow.
Tomas, Antonin, Can you please merge the fix from "Nevada Patch 1 and Arrow" into the main dev branch. I can still reproduce the problem as of dev build 200311301900 and as I mentioned before I'd appreciate a quick fix for this issue as I run into it frequently.
Honzo, please merge the fix from "Nevada Patch 1 and Arrow" into trunk. Thanks.
Closing, Import Management Tool was replaced by Fix Import functionality.
Instead of closing as WON'T FIX, you should have redirected all IMT issues to the new FIX IMPORT tool where they could be closed if necessary.