How to make Eclipse show packages? - eclipse

I recently upgraded my Eclipse and the workspace stopped working.
So I made a new one, copied all my projects over to it, then imported them.
However, now it shows them as folders instead of the actual packages like it used to:
How can I get the packages back?

Are you sure, you are using the Eclipse perspective Java or Java EE and within one of those perspectives, are using the view Package Explorer ?
Most of the times this happening because the Eclipse view Navigator is used, as show here.

Related

Convert project in existing workspace from ADT to Andmore

I have just updated from Eclipse Luna to Eclipse Oxygen and installed Andmore. I have a bunch of project workspaces which were created with Eclipse Luna and ADT.
Eclipse automatically upgrades workspaces to the newer version on import, but it doesn’t convert from ADT to Andmore (which, although sharing much of the same code, is a different plugin).
Is there a way I can migrate an existing Eclipse workspace from ADT to Andmore without having to delete and re-import every single Android project?
There is an official way, see here. This needs to be done for each project in the workspace (also for library projects, if any):
Right-click the project, then select Configure > Convert to Andmore Project (wording of the last menu item may differ slightly).
In my case I had to restart Eclipse before it would pick up everything.
You may also need to clean your project.
If you had any tabs with ADT-specific views open (which includes all ADT files and potentially anything which is not a Java source file), you will need to close and reopen them, as they still refer to ADT components which are no longer available. Closing and reopening them will bring up the corresponding Andmore view.
I still get an error message when I try to build the app, but that may be unrelated. The first build failed with an error but that was due to a separate, unrelated issue.

PyDev Package Explorer doesn't retain directories expanded states between sessions

For Eclipse Neon 4.6.1 and PyDev 5.3.1.201610311318 (i.e. everything fully updated as of today).
Is there a way to help PyDev Package Explorer remember the state of expanded directories between sessions?
This problem began only after I upgraded to Neon. Eclipse Mars and PyDev retained folder states between sessions.
My PyDev project contains a nested directories structure. No level is deeper than four levels below the project's root.
I expand one or another portions of that dirs structure as I work. After I close and restart Eclipse, all the project directories and files are present and accessible but the Package Explorer hasn't retained the dirs' expanded state from the previous session.
Sometimes some dirs may be expanded to two of four levels, but sometimes not at all.
Eclipse Neon remembers all other view settings. The size of the Eclipse window, the workspace's tools, and the files that were open in the editor are all where they were at the end of the preceding session.
Not sure it's pertinent, but because Eclipse Neon implements a different projects structure than preceding versions, when I upgraded from Mars to Neon I made a full copy of my Mars project (in case I needed to revert), then pointed Neon to that copy. I then archived my Mars project so that I'm certain I'm not accidentally accessing two different Python projects.
When I created the copy of the project might I have left something behind that affects the PyDev Package Explorer's ability to remember project directory settings between sessions?
I believe I've fixed my own problem.
As mentioned, the problem arose after I upgraded from Eclipse Mars to Eclipse Neon. As part of doing that I tried to re-use my Mars-level projects. When I did, Neon told me it needed to "upgrade" those projects to the newer Neon format. But that process evidently brings a lot of problems along with it.
So I did the following:
I of course had all my Mars projects' source files backed up.
I completely deleted my new Neon installation and reinstalled from scratch: No Mars projects, no inherited settings, no anything else.
In Eclipse Neon, I created new, empty projects (Python, Java, and Java EE).
I copied ONLY my Mars projects' source files -- and nothing else -- into the clean Neon installation's new project directories.
Because the Neon-level projects now contained only source files and nothing else, Neon no longer perceived a need to "upgrade" those projects. Now when I re-open a "Neon-pure" project, that project's folders have retained the expansion levels they had when I closed that project.
Another pleasant by-product of performing the preceding steps was that I also fixed a problem wherein Window -> Show View -> Other displayed a long list of red icons under org.eclipse.e4.secondaryDataStack:
Those red icons no longer appear.
Hope this helps...

Why can't I find my new classes in Project Explorer?

I created new classes by right clicking on a package. The package seems correct in the actual code in the classes, but the new classes can't be seen in the package in the Project Explorer.
What's going on?
Right click on the project name in the Project Explorer and hit 'refresh'. I had this problem before too.
Yes, the problem was that some processes, needed for updating the project explorer, in Eclipse were frozen and even quitting Eclipse wasn't possible without using Task Manager to destroy the Eclipse-process. Only after restarting my Windows 8 system I was able to continue using Eclipse normally.

Eclipse doesn't show classes within packages

After months of using Eclipse (latest Kepler release) on Ubuntu (13.10), after rebooting from to a sudden loss of power on my laptop, now Eclipse won't let me access java classes within their packages. It simply just shows the packages names but when I click on these the java classes are not showing.
Please note that even though I have several Maven projects working, this happens only on one specific project.
Steps so far:
1) I checked the permissions of all the java files and the directories.
2) Tried updating the project but no luck, also reverted back to my an earlier version (SVN) but didn't help either.
3) I tried deleting .eclipse and re-installing Eclipse and importing my projects, but unfortunately it didn't resolve the issue.
4) I have checked the .classpath file which seems ok.
5) Recursively 'touch' all the files, but still nothing.
I believe that this is a Maven + Eclipse related issue but I have ran out of options here, so I am open to suggestions. Thanks...
Probably it is not a problem of the project but of the workspace metadata. Please create a new workspace and important the project there. Are you able to browser the package explorer there?
Those are empty packages as you know. we need to right click on those packages and create class then you would probably see classes.
In case u still can't see classes then Go to Window->show view->Package explorer
you will be able to see packages along with classes tagged. if you have created any.
click here to see Image view of above settings

Change in perspective name not appearing

I have a plugin in which I have created a perspective. Now I changed the name of the perspective in plugin.xml. It is working fine if I am running from sources. The name of the perspective still the older one when I export the plugin. I am using eclipse juno 4.2
I am completely lost no clue whatsoever. I checked the plugin.xml file in the exported plugin it is having the new name. What is the mistake I am making???
My problem was adding perspectives and views using the plugin.XML, changes didn't take effect because when running plugin projects in development environment eclipse creates a "runtime-(pluginProjectName).application" folder in the parent of the workspace directory.
If you delete this folder eclipse should run with the new changes made to Views and Perspectives structure.
Best of luck.
http://www.eclipsezone.com/eclipse/forums/t61566.html This link helped me in solving it. I should have searched in this line earlier itself. I hope this helps for someone else. Do clean your eclipse in case of these kind of problems