private static List<Command> loadRewrites(ContentResolver contentResolver,Uri uri) throws IOException {
  InputStream inputStream=contentResolver.openInputStream(uri);
  List<Command> commands=new ArrayList<>();
  if (inputStream != null) {
    BufferedReader reader=new BufferedReader(new InputStreamReader(inputStream));
    String line;
    while ((line=reader.readLine()) != null) {
      addLine(commands,line);
    }
    inputStream.close();
  }
  return commands;
}

private static List < Command > loadRewrites ( ContentResolver contentResolver , Uri uri ) throws IOException { InputStream inputStream = contentResolver . openInputStream ( uri ) ; List < Command > commands = new ArrayList < > ( ) ; if ( inputStream != null ) { BufferedReader reader = new BufferedReader ( new InputStreamReader ( inputStream ) ) ; String line ; while ( ( line = reader . readLine ( ) ) != null ) { addLine ( commands , line ) ; } inputStream . close ( ) ; } return commands ; }
loads the rewrites from an uri using a contentresolver .
