<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def status(self, record=None):
 """Extract status from the retrieved data and save it as a property of an object. If record with data is not specified then the status of previous operation is returned. status - dictionary with data source, string with request and status type, code and message. status['StatusType']: 'Connected' - the data is fine 'Stale' - the source is unavailable. It may be worthwhile to try again later 'Failure' - data could not be obtained (e.g. the instrument is incorrect) 'Pending' - for internal use only status['StatusCode']: 0 - 'No Error' 1 - 'Disconnected' 2 - 'Source Fault' 3 - 'Network Fault' 4 - 'Access Denied' (user does not have permissions) 5 - 'No Such Item' (no instrument with given name) 11 - 'Blocking Timeout' 12 - 'Internal' """

        if record is not None:
            self.last_status = {'Source': ustr(record['Source']),
                                'StatusType': ustr(record['StatusType']),
                                'StatusCode': record['StatusCode'],
                                'StatusMessage': ustr(record['StatusMessage']),
                                'Request': ustr(record['Instrument'])}
        return self.last_status