简体   繁体   English

为Eclipse中的每个项目设置默认数据路径

[英]Set default data path for every project in Eclipse

Eclipse project/folder structure: Eclipse项目/文件夹结构:

 src
    java files
  bin
    class files
  resources
    data files

Is there a way to set the default data path to project/resources in Eclipse, such as setting a classpath variable as MY_DATA_PATH? 有没有办法在Eclipse中将默认数据路径设置为项目/资源,例如将类路径变量设置为MY_DATA_PATH?

Yes, create a library project and keep the content of the lib or any other project folder you want in this library project. 是的,创建一个库项目,并在该库项目中保留您想要的lib或任何其他项目文件夹的内容。

Reference this project in your other project. 在其他项目中引用该项目。 This will allow you to have a common path across all project for any project folder like lib, SRC, asset 这将使您可以跨所有项目使用任何项目文件夹(如lib,SRC,资产)的通用路径

Any content with same name and project folder in referencing project will over write that particular content of library project. 引用项目中具有相同名称和项目文件夹的任何内容都将覆盖库项目的特定内容。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM