Java Properties: Part 1

Printing

printProperties(System.getProperties());

private static void printProperties(Properties properties) {
  new TreeSet<>(properties.keySet()).forEach((k) -> {
    System.out.println(k + " : " + properties.get(k));
  });
}

 

Leave a Reply