public void writeToFileInDirectory(File directory,String fileName,String content){
  try {
    Files.write(content,new File(directory,fileName),StandardCharsets.UTF_8);
  }
 catch (  IOException ioe) {
    throw new RuntimeException(ioe);
  }
}

public void writeToFileInDirectory ( File directory , String fileName , String content ) { try { Files . write ( content , new File ( directory , fileName ) , StandardCharsets . UTF_8 ) ; } catch ( IOException ioe ) { throw new RuntimeException ( ioe ) ; } }
writes the given content into a file in given directory .
