path of installation
I have a problem. Im doing an installer for my program, but how I tell to class which is the path of installation
new FileInputStream("pathInstallation/DESTest.txt")
开发者_Python百科Greetings
how I stick the path on the classpath?
Use Class.getResource
or Class.getResourceAsStream
methods.
The resource is any file which is located next to your compiled .class file. Pass the name of the file (without the path) to one of these methods and read its content.
精彩评论