'Execute the ``WRITE`` command of the ``SYNC`` API.
Arguments:
path(str): Path to the file to write
data(str): Data to write to the file
mode(int): File mode to set (e.g. ``0o755``)
timestamp(int): Unix timestamp to set the file date to
callback(callable): Callback function invoked as data
is written.  Arguments provided are:
- File path
- All data
- Expected size of all data
- Current chunk
- Expected size of chunk'

def write(self, path, data, mode=493, timestamp=None, callback=None):

    st = self.stat(path)
    if (st and stat.S_ISDIR(st['mode'])):
        log.error(('Cannot    write    to    %r:    Path    is    a    directory' % path))
    return self._write(path, data, mode=493, timestamp=None, callback=None)
