public static List<String> dumpResource(Class<?> forClass,String path) throws IOException {
  InputStream is=(forClass == null) ? ClassLoader.getSystemResourceAsStream(path) : forClass.getResourceAsStream(path);
  if (is == null) {
    throw new FileNotFoundException("For class " + forClass + ": "+ path);
  }
  return readStream(is);
}

public static List < String > dumpResource ( Class < ? > forClass , String path ) throws IOException { InputStream is = ( forClass == null ) ? ClassLoader . getSystemResourceAsStream ( path ) : forClass . getResourceAsStream ( path ) ; if ( is == null ) { throw new FileNotFoundException ( "For class " + forClass + ": " + path ) ; } return readStream ( is ) ; }
dumps the content of a resource into a list < string > , where each element is one line of the resource .
