目录1. 使用ClassLoader.getResourceAsStream()方法2.使用 Class.getResourceAsStream() 方法3.使用ResourceLoader加载文件4.使用ResourceUtils加载文件5.使用ApplicphpationContext加载文件6.使用ServletContext加载
This question already has answers here: Getting the name of a variable as a string (31 answers) Closed 2 months ago.