Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » Missing java source files (Why and how does Eclipse hide files?)
Missing java source files [message #1271113] Fri, 14 March 2014 09:49 Go to next message
Goffredo Armida is currently offline Goffredo ArmidaFriend
Messages: 5
Registered: March 2014
Junior Member
Hi,

I started a new workspace, and a new project; I then imported a set of java example files into the source directory 'src', located under the project. ie examples->src-><bunch of java files here>. Next, I began to work with one of the example files, nothing special about that, I wasn't trying to do anything new. Then, not knowing quite what I had done (I must have done something), all of the .java files disappeared from view. And I haven't been able to restore them. I have no idea what switch or setting or what needs to be pressed or switched or removed or what in order to get Eclipse (Kepler) to show my source files again. I can't work with the files, I cannot compile them. Just a dead end. However the directory structure and the files still exist exactly where they should exist on my hard drive. If I try to re-import them I am told the files exist already. So ...

Yes I could start another workspace, and another project and import the files again, but that seems to miss the point. Eclipse should not be hiding source files at all imho (if people need to hide source files then they should do the appropriate refactoring on their project). And if Eclipse does want to hide source files, then it should be _easy_ to see what has been done, _easy_ to see why it has been done, and _easy_ to reverse. Simple things should be simple! They should not be impossible. May I suggest a 'Show ALL files' button, in red, on the main menu!

Thanks for help.
Regards
Goffredo







Re: Missing java source files [message #1271564 is a reply to message #1271113] Sat, 15 March 2014 14:06 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Goffredo,

Without knowing what you did, it's hard to tell you how to undo it. What
objects are showing as the root objects in your Package Explorer? Did
you look at all the menu items in the view menu of the package
explorer? If you right click on the perspective icon and invoke
"Reset" it might undo whatever you did to change how things are being
shown...

On 14/03/2014 2:49 AM, Goffredo Armida wrote:
> Hi,
> I started a new workspace, and a new project; I then imported a set of
> java example files into the source directory 'src', located under the
> project. ie examples->src-><bunch of java files here>. Next, I began
> to work with one of the example files, nothing special about that, I
> wasn't trying to do anything new. Then, not knowing quite what I had
> done (I must have done something), all of the .java files disappeared
> from view. And I haven't been able to restore them. I have no idea
> what switch or setting or what needs to be pressed or switched or
> removed or what in order to get Eclipse (Kepler) to show my source
> files again. I can't work with the files, I cannot compile them. Just
> a dead end. However the directory structure and the files still exist
> exactly where they should exist on my hard drive. If I try to
> re-import them I am told the files exist already. So ...
> Yes I could start another workspace, and another project and import
> the files again, but that seems to miss the point. Eclipse should not
> be hiding source files at all imho (if people need to hide source
> files then they should do the appropriate refactoring on their
> project). And if Eclipse does want to hide source files, then it
> should be _easy_ to see what has been done, _easy_ to see why it has
> been done, and _easy_ to reverse. Simple things should be simple! They
> should not be impossible. May I suggest a 'Show ALL files' button, in
> red, on the main menu!
> Thanks for help. Regards
> Goffredo
>
>
>
>
>
>
>
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Missing java source files [message #1271800 is a reply to message #1271564] Sun, 16 March 2014 07:26 Go to previous messageGo to next message
Goffredo Armida is currently offline Goffredo ArmidaFriend
Messages: 5
Registered: March 2014
Junior Member
Hi Ed, my package explorer goes like so:

Package Explorer
-> examples (which is my package)
-> src (which should contain my java files but does not)
-> resources
-> JRE System Library

And that is that. the 'src' show nothing else, and there is is no "default package" here either.
Your other suggestions provided no joy.
The perspective icon 'reset' also does nothing.

I still have no idea where to go next.

Thanks
Regards
Goffredo

Re: Missing java source files [message #1271801 is a reply to message #1271800] Sun, 16 March 2014 07:27 Go to previous messageGo to next message
Goffredo Armida is currently offline Goffredo ArmidaFriend
Messages: 5
Registered: March 2014
Junior Member
oops ... the 'src' and 'resources' directories are underneath the 'examples' directory, not at the same level.
Re: Missing java source files [message #1271923 is a reply to message #1271800] Sun, 16 March 2014 16:15 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Goffredo,

Comments below.

On 16/03/2014 12:26 AM, Goffredo Armida wrote:
> Hi Ed, my package explorer goes like so:
> Package Explorer
> -> examples (which is my package)
You mean your project?
> -> src (which should contain my java files but does not)
> -> resources -> JRE System Library
>
> And that is that.
What does the Navigator view show for this same project? Did you
change something with the Filters.. in the Package explorer? Have you
tried "Refresh"ing the project?

> the 'src' show nothing else, and there is is no "default package" here
> either. Your other suggestions provided no joy. The perspective icon
> 'reset' also does nothing.
> I still have no idea where to go next.
> Thanks
> Regards
> Goffredo
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Missing java source files [message #1271925 is a reply to message #1271801] Sun, 16 March 2014 16:23 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Goffredo,

Probably is you learned about Ctrl-Shift-T to open a Java class, you'd
have found the file easier than hunting for it in the nested structure.


On 16/03/2014 12:27 AM, Goffredo Armida wrote:
> oops ... the 'src' and 'resources' directories are underneath the
> 'examples' directory, not at the same level.
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Missing java source files [message #1271927 is a reply to message #1271801] Sun, 16 March 2014 16:25 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Goffredo,

Also, does this make you reconsider your original statements about all
the things that weren't easy enough?

On 16/03/2014 12:27 AM, Goffredo Armida wrote:
> oops ... the 'src' and 'resources' directories are underneath the
> 'examples' directory, not at the same level.
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:How to mark an ASTNode uniquely ? Even if I rebuild AST Tree the mark wouldn't change?
Next Topic:space-white in the path
Goto Forum:
  


Current Time: Wed Apr 24 19:09:23 GMT 2024

Powered by FUDForum. Page generated in 0.03526 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top