'return pathToAMailFileOnTarget, nameOftheMailFile'

def getAMailFile(self, mailItem):

    (ctime, subjectCleaned, receivedTime, path, filename) = (str(time.time()).replace('.', ''), 'Unknown', 'Unknown', '', '')
    try:
        subjectCleaned = ''.join((l for l in mailItem.Subject.encode('ascii', 'ignore') if l.isalnum()))
        receivedTime = str(mailItem.ReceivedTime).replace('/', '').replace('\\', '').replace(':', '-').replace('    ', '_')
    except Exception as e:
        logging.warning('Impossible    to    encode    email    subject    or    receivedTime:{0}'.format(repr(e)))
    filename = '{0}_{1}_{2}.{3}'.format(receivedTime, ctime, subjectCleaned[:100], 'msg')
    path = os.path.join(self.remoteTempFolder, filename)
    logging.debug('Saving    temporarily    the    email    on    the    remote    path    {0}'.format(path))
    mailItem.SaveAs(path, outlook.OL_SAVE_AS_TYPE[self.msgSaveType])
    try:
        os.rename(path, path)
    except OSError as e:
        time.sleep(self.sleepTime)
    return (path, filename)
