write
Write content to the file:
Delete the file if it exists.
Create a new file.
Write content to file.
Throws
if file does not exist after creation.
Write content to the file:
Delete the file if it exists.
Create a new file.
Write content to file.
if file does not exist after creation.