Assim com o caminho certo do arquivo funciona
public static Properties getProp() throws IOException { Properties props = new Properties(); FileInputStream file = new FileInputStream( "D:/ide/workspace_luna/nfse/nfse-modelo/src/main/resources/APP_MSG.properties"); props.load(file); return props; }
Assim não funciona
public static Properties getProp() throws IOException { Properties props = new Properties(); FileInputStream file = new FileInputStream( "./nfse/nfse-modelo/src/main/resources/APP_MSG.properties"); props.load(file); return props; }
Assim não funciona
public static Properties getProp() throws IOException { Properties props = new Properties(); FileInputStream file = new FileInputStream( "./nfse-modelo/src/main/resources/APP_MSG.properties"); props.load(file); return props; }
Assim não funciona
public static Properties getProp() throws IOException { Properties props = new Properties(); FileInputStream file = new FileInputStream( "./src/main/resources/APP_MSG.properties"); props.load(file); return props; }
Como faço para buscar este arquivo.
Meu projeto tem vários subprojetos.
Utilizo Spring.