In Eclipse IDE, how do I link a Java project to a folder full of Java source code files? Or how do I link a folder full of Java source code files to my Java project?
Read on to see the solution.
Solution
Let's say that the project's name is MultiMediaPlayer.
Open your Eclipse workspace and navigate to the following location in MultiMediaPlayer:
Java Build Path -> Source -> Link Source -> Browse
Select the folder that you want to link to. Let's say the folder is C:\Users\michael.wen\git\base\core\java.
Once you are done you'll see that under MultiMediaPlayer there is a java folder. In this folder you will see source code files that are identical to C:\Users\michael.wen\git\base\core\java. They actually mirror each other and any update you make to one file is immediately reflected in the other counterpart.
Note that the java folder is just a view you see in Eclipse so you know that MultiMediaPlayer is linked to this source code folder. Such folder does not exist on the disk.
Related Articles
Fixing Java No Class Def Found Error and Class Not Found Exception in MINUTES!
How Does Java Know Where to Find Core Libraries?
Solving Java JDOM Jar Cannot Find Symbol Errors!
Eclipse: How to Make a Project a Java Project?
Fixing Java No Class Def Found Error and Class Not Found Exception in MINUTES!
How Does Java Know Where to Find Core Libraries?
Solving Java JDOM Jar Cannot Find Symbol Errors!
Eclipse: How to Make a Project a Java Project?
Questions? Let me know!