Added writeFile() and readFile()