Skip to content

Instantly share code, notes, and snippets.

@oshingc
Last active August 29, 2015 14:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oshingc/514a0a475355274107d0 to your computer and use it in GitHub Desktop.
Save oshingc/514a0a475355274107d0 to your computer and use it in GitHub Desktop.
Is a Java Thing
[How to load a file that is on the project]
1. Put the file at the path project/src/main/resources/myfolder/myfile.xls
2. Run this code:
import org.springframework.util.ResourceUtils;
File xls = ResourceUtils.getFile("classpath:myfolder/myfile.xls");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment