'Execute the ``STAT`` command of the ``SYNC`` API.
Arguments:
path(str): Path to the file to stat.
Return:
On success, a dictionary mapping the values returned.
If the file cannot be ``stat()``ed, None is returned.
Example:
>>> expected = {\'mode\': 16749, \'size\': 0, \'time\': 0}
>>> pwnlib.protocols.adb.AdbClient().stat(\'/proc\')           == expected
True
>>> pwnlib.protocols.adb.AdbClient().stat(\'/does/not/exist\') == None
True'

@_with_transport
@_sync
def stat(self, path):

    self.c.flat32('STAT', len(path), path)
    if (self.c.recvn(4) != 'STAT'):
        self.error('An    error    occured    while    attempting    to    STAT    a    file.')
    mode = self.c.u32()
    size = self.c.u32()
    time = self.c.u32()
    if ((mode, size, time) == (0, 0, 0)):
        return None
    return {'mode': mode, 'size': size, 'time': time}
