- This topic has 16 replies, 2 voices, and was last updated 17 years, 7 months ago by Riyad Kalla.
-
AuthorPosts
-
kingcuMemberI got an exeption on renaming a class. The exception simply says “Class file name must end with .class”. I even tried with renaming local variables, and got the same exception. See below link for a screen shot:
http://new.photos.yahoo.com/wtatkfi/album/576460762396310787/photo/294928804311098548/0
And here is my configuration:
*** Date: Tue Apr 03 14:02:31 EDT 2007
*** Platform Details:
*** System properties:
GRE_HOME=C:\Program Files\MyEclipse 5.1.1 GA\myeclipse\eclipse\plugins\com.genuitec.javascript.debug.mozilla_5.1.1\XPCOM\os\win32\mozilla
awt.toolkit=sun.awt.windows.WToolkit
eclipse.buildId=M20060921-0945
eclipse.commands=-os
win32
-ws
win32
-arch
x86
-launcher
C:\Program Files\MyEclipse 5.1.1 GA\eclipse\eclipse.exe
-name
Eclipse
-showsplash
600
-exitdata
294_80
-vm
C:\Program Files\MyEclipse 5.1.1 GA\jre\bin\javaw.exe
eclipse.ee.install.verify=false
eclipse.product=com.genuitec.myeclipse.product.ide
eclipse.startTime=1175611009636
eclipse.vm=C:\Program Files\MyEclipse 5.1.1 GA\jre\bin\javaw.exe
eclipse.vmargs=-Xms128M
-Xmx512M
-XX:PermSize=64M
-XX:MaxPermSize=128M
-jar
C:\Program Files\MyEclipse 5.1.1 GA\eclipse\startup.jar
eof=eof
file.encoding=Cp1252
file.encoding.pkg=sun.io
file.separator=\
java.awt.graphicsenv=sun.awt.Win32GraphicsEnvironment
java.awt.printerjob=sun.awt.windows.WPrinterJob
java.class.path=C:\Program Files\MyEclipse 5.1.1 GA\eclipse\startup.jar
java.class.version=49.0
java.endorsed.dirs=C:\Program Files\MyEclipse 5.1.1 GA\jre\lib\endorsed
java.ext.dirs=C:\Program Files\MyEclipse 5.1.1 GA\jre\lib\ext
java.home=C:\Program Files\MyEclipse 5.1.1 GA\jre
java.io.tmpdir=C:\DOCUME~1\TONGWA~1\LOCALS~1\Temp\
java.library.path=C:\Program Files\MyEclipse 5.1.1SNIP, in the future please use MyEclipse > Installation Summary > Installation Details
Riyad KallaMemberThis can occur when you try and refactor a class name and include a dot in the new file name, it thinks your trying to rename the file.
To get your project into a good state, right-click on the root and do a Refresh. Then go to Project > Clean and rebuild the project in question. Now fix any build path or build issues you have in the problem view before refactoring. That should get you set.
kingcuMember@support-rkalla wrote:
This can occur when you try and refactor a class name and include a dot in the new file name, it thinks your trying to rename the file.
To get your project into a good state, right-click on the root and do a Refresh. Then go to Project > Clean and rebuild the project in question. Now fix any build path or build issues you have in the problem view before refactoring. That should get you set.
I tried what you said. I don’t have any errors, just warnings: because I use injection, so it’s complaining about those injected local variable never used. And I can’t even rename a class variable!
Riyad KallaMemberThat is really strange. What are you trying to rename the class to? What exactly do you type into the text field when you try and rename it?
If you create a new project and just copy the classes over… can you rename them then? I wonder if the project went squirrely… also try and restart the IDE, see if that helps.
kingcuMemberI recreated the project and was able to rename the class. However, the references are not updated even if I have “Update reference” checked.
Riyad KallaMemberJust to be clear, are you referring to references *only* in Java source classes, or are you referring to references in other files (like XML, properties, etc.)?
kingcuMemberIn Java files only. In the rename dialog, when I click on “Next >” instead of clicking “Finish” directly, in the changes to be performed list, only one thing shows up about renaming the compilation unit, it doesn’t mention about updating the references in other Java files. See below link for screen shot:
[URL]http://new.photos.yahoo.com/wtatkfi/photo/294928804311227315/0[/URL]
Riyad KallaMemberIs this project something you can share with me? I wonder what is going on here.
kingcuMemberI can zip up the workspace and … how do I get the file to you then?
Riyad KallaMemberPlease *export* just the project using File > Export > Archive, to a ZIP file and email it to support@genuitec.com ATTN Riyad with a link to this thread for reference.
Don’t zip up the workspace because it can contain 10s or 100s of megabytes of index and metadata.
kingcuMemberI’ve emailed you the project archive. Thank you for the help. Let me know if you need any other info.
Riyad KallaMemberI found the bug, it seems to be because you have a DOT in the project name. This is a very obscure bug, thank you for helping me find it.
kingcuMemberYes, I changed the DOT to UNDERSCORE and it worked. Thank you for the help.
kingcuMemberJust realized another problem: I have in my workspace a EAR, a JAR and a WAR project and organized in a .ear, .jar and .war folders respectively. And I use exploded mode at development time. If I change the name of the JAR project, the exploded directory name is also changing, which causes a problem at deployment time when it’s complaining can’t find the .jar folder (configured in the application.xml as an EJB module).
So, when can I expect this to be fixed?
Riyad KallaMemberI have in my workspace a EAR, a JAR and a WAR project and organized in a .ear, .jar and .war folders respectively
Do you mean organized into “projects” with those extensions on them?
If I change the name of the JAR project, the exploded directory name is also changing, which causes a problem at deployment time when it’s complaining can’t find the .jar folder (configured in the application.xml as an EJB module).
So when you remove the “.jar” from the project name, it’s getting deployed to a directory without a .JAR extension and your app server cannot find it? Is that the case?
What app server are you using?
-
AuthorPosts