List of utility methods to do Properties Load from InputStream
Properties | loadProperties(Class> aClass, String aFileName, InputStream aResourceAsStream) load Properties try { try { Properties tProperties = new Properties(); tProperties.load(aResourceAsStream); return tProperties; } finally { aResourceAsStream.close(); } catch (IOException e) { throw new RuntimeException(e); |
Properties | loadProperties(final InputStream in) load Properties final Properties props = new Properties(); try { props.load(in); } finally { in.close(); return props; |
void | loadProperties(final InputStream io) Loads properties from input stream. if (null == io) { throw new IllegalArgumentException("Input stream cannot be null."); props = new Properties(); props.load(io); |
Properties | loadProperties(final Properties properies, final InputStream inputStream) load Properties try { properies.load(inputStream); return properies; } finally { inputStream.close(); |
Properties | loadProperties(InputStream input) load Properties InputStreamReader reader; Properties props = new Properties(); try { reader = new InputStreamReader(input, "utf8"); props.load(reader); } catch (Exception e) { e.printStackTrace(); return null; ... |
Properties | loadProperties(InputStream input) load Properties Properties props = new Properties(); props.load(input); return props; |
Properties | loadProperties(InputStream inputStream) load Properties Properties props = new Properties(); if (inputStream != null) { try { props.load(inputStream); } finally { inputStream.close(); return props; |
Properties | loadProperties(InputStream inputStream) Read Properties from an InputStream. if (inputStream == null) { return null; Properties properties = new Properties(); try { properties.load(inputStream); } catch (Exception e) { throw new RuntimeException("Error loading properties from stream", e); ... |
Properties | loadProperties(InputStream inputStream) load Properties Properties properties = new Properties(); BufferedReader in = new BufferedReader(new InputStreamReader(inputStream)); while (true) { String line = in.readLine(); if (line == null) return properties; if (line.length() > 0) { int len = line.length(); ... |
void | loadProperties(InputStream inputStream, Properties result) ADD THIS METHOD FOR TESTING WITH ECLIPSE 3.5 InputStream input = null; try { input = new BufferedInputStream(inputStream); result.load(input); } finally { if (input != null) { input.close(); input = null; ... |