How do relative file paths work in Eclipse?

前端 未结 6 1351
后悔当初
后悔当初 2020-11-29 01:10

So my 2009 new years resolution is to learn Java. I recently acquired \"Java for Dummies\" and have been following along with the demo code in the book by re-writing it usi

6条回答
  •  臣服心动
    2020-11-29 01:31

    You can always get your runtime path by using:

     String path = new File(".").getCanonicalPath();
    

    This provides valuable information about where to put files and resources.

提交回复
热议问题