Resource resource = appContext.getResource("classpath:data.xml");
Properties properties = new Properties();
try (InputStream is = resource.getInputStream()) {
properties.loadFromXML(is);
} catch (IOException e) {
e.printStackTrace();
}
1 min read
Resource resource = appContext.getResource("classpath:data.xml");
Properties properties = new Properties();
try (InputStream is = resource.getInputStream()) {
properties.loadFromXML(is);
} catch (IOException e) {
e.printStackTrace();
}