Build error in eclipse - eclipse

I am using eclipse HELIOS. I am getting the following error message whenever I build my project.
Has anyone else experienced such error? Is it a problem of eclipse or the project? It never occured to me before but for this project its happening. It says NullPointerException but that should not pop up such message.
Please help, its driving me nuts. I need to check in my codes but I cant test them due to this building error.
Let me know if more details is reqd.

I found the solution. It was a maven plugin issue. Cleaning up the repository solved it.

First try;
Clean your all project from under project menu and eclipse tries rebuild.
Second try;
Remove your project from eclipse
Delete all files(eclipse project
files like .project) except .java
files and other necessary code files
like .xml
And create a new project from
existing these source codes.
Otherwise you can check your java compiler or eclipse builder path or builder version.

Related

The project was not built due to "ProjectXX does not exist".

I am trying to set up a workspace in MyEclipse. And I am getting 20 errors with the same description as below.
Description Resource Path Location Type
The project was not built due to "ProjectXX does not exist". Fix the problem, then try refreshing this project and building it since it may be inconsistent ProjectXX Unknown Java Problem
Now I can see that this project, ProjectXX is clearly in my workspace and it is a EAR project. My team does not face this issue in their MyEclipse/PC.
I dont know why, but this resolved my issue. I selected the option to import existing Gradle project into workspace and then gave the exact root folder of the project and then the errors were gone.
I had the same problem and the solution was to deactivate the "Java Builder" property. To do it, just open the project properties with right click, go to "Builders" and deactivate "Java Builder". You can now delete the errors, validate the project and the problem is never seen again.
Thanks to #Tony Weddle for the hint "the EAR is not a Java Project".

Cannot create new php project in eclipse

I am using Zend Eclipse for PHP developers version 3.2.0.
I have just created a new workspace for an existing local project but Eclipse keeps coming up with an error when I try to create the project.
An error has occurred. See error log for more details.
org.eclipse.php.internal.server.core.manager.ServersManager.isEmptyServer(Lorg/eclipse/php/internal/server/core/Server;)Z
I have another workspace with a project on it which works fine, it just won't let me create a new project in a new workspace.
Anyone know what is going on?
Many thanks in advance.

Can´t run acceleo uml2java example

I´m beginning with Acceleo.
I installed eclipse-modeling-luna-M6-win32.
Then i installed acceleo by update on eclipse.
(is there any better option?)
Trying to use the uml2java example.
To run it i tried to run org.eclipse.acceleo.examples.uml2java.
It gave me:
Error
Couldn't load class org.eclipse.acceleo.examples.uml2java.main.Uml2java from project org.eclipse.acceleo.examples.uml2java
Couldn't load class org.eclipse.acceleo.examples.uml2java.main.Uml2java. Check that its containing package is exported.
I did not change the code.
I checked the MANIFEST and it has on the runtime: org.eclipse.acceleo.examples.uml2java.main
I also saw that there is an UI project that as i understand is a plugin but i don´t know what to do with it (so that it will create a new menu on eclipse).
Any help is appreciated!!
Thanks.
it worked using eclipse indigo with the latest acceleo. i don´t know if it´s possible to use a more recent eclipse version. also works with eclipse kepler.
This fixed the problem for me. Try adding the "bin/" directory to the Classpath in the Manifest file.
Right click the MANIFEST.MF file and "Open With >" "Plug-in Manifest Editor".
This gives some tabs at the bottom. Use the "Runtime" tab. On the bottom right of this screen there is a place to edit the classpath. Add "bin/".
I got this idea from Etienne's answer in: Can't generate java from UML using Acceleo in Eclipse

An internal error occurred during: "Updating Maven Project". Preference node "org.eclipse.wst.validation" has been removed

I'm trying to open my Maven project with Eclipse Juno, but I'm getting this error:
An internal error occurred during: "Updating Maven Project".
Preference node "org.eclipse.wst.validation" has been removed.
How is this caused and how can I solve it?
Same probleme here, there the solution I fix it
Open the .project file with your prefered text editor.
delete the node that is about "org.eclipse.wst.validation"
Close your project
Open your project
Launch Maven Update...
Should be good.
Another way to fix it, if you don't want to change your .project config
(or if you had several projects that must be fixed)
Close your workspace (or eclipse)
-move out <WorkspaceDir>\.metadata\.plugins\org.eclipse.core.resources\.projects from the workspace directory
-reopen you workspace
close it again
-move back the .projects dir (say yes to replace questions ? )
open you workspace
Launch Maven Update
Should be good
Simpler fix:
Close Project
Open Project
Project > Clean
Run Maven Update
I was using Eclipse Mars and in my case, just close and reopen my IDE did the work.
Dont know, if you still have this problem, but here is the solution worked for me:
It appears that deleting the file org.eclipse.wst.validation.prefs in
the directory .metadata/.plugins/org.eclipse.core.runtime/.settings
(default settings for workspace) or .settings in each individual
project will cause the settings for validation to be reset to their
original settings. You can then use validation without getting error
messages and try resetting the options from there. However, I'm not
sure what combination of settings would cause the problem to reappear.
However, if it does, you can repeat the process.
got this from here: https://bugs.eclipse.org/bugs/show_bug.cgi?id=355012
in my case i didnt have the mentioned file in this folder, but i had a bunch of other org.eclipse.wst.* files. deleting them all did the trick for me.
The problem is not related to the .projects folder as mentioned in another answer.
The solution is to add a file called org.eclipse.wst.validation.prefs in the .settings folder. This will restore the eclipse validation node.
The content of the file, depending on your eclipse version, might look like this:
disabled=06target
eclipse.preferences.version=1
Another Solution is too simple , deleting .project file then clean the project and maven update will success surely
I think this is one error that could be caused by multiple different sources. I just had the same error however, and just figured out why. In my situation, I just tried to force update some code by deleting a few temporary files. Turned out I accidentally deleted that file as well. I thankfully had it under source control, so I pulled the file back and updated the project with Maven. I also made sure any other errors were fixed so that the project would clean / update successfully.
I'm not sure if this will solve your problem, but I hope it helps! Good luck!

eclipse build problem

when I try to build my Eclipse project, I get the following error message:
The type org.eclipse.swt.widgets.Composite cannot be resolved. It is indirectly referenced from required .class files
Can anybody help me to solve this problem? The Java-Build-Path contains the Plug-in-Dependencies-Library and org.eclipse.swt... is listed there.
I didn't have the problem last week (though nothing should have changed in the meantime).
But it's not the first time that I get this typ of error...
Finally, I could solve the problem with creating a new workspace and importing my project.
I sometimes encounter this kind of stranges error and the only solutions I found to solve it are the following ones (no specific order and sometimes one is enough sometimes not):
Select the project and clean ONLY this project, then rebuild
Clean all the workspace
Restart the workbench
Disable "automatic build", clean all, the build only your project
Remove the project from the workspace WITHOUT removing it from Hard drive and then import it again
I think this is a PDE issue.
Hope this can help,
Manu