<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def time_entries(self, start_date=None, end_date=None):
        '''Array of all time entries'''
        if self.cache['time_entries']: return self.cache['time_entries']
        if not start_date:
            start_date = datetime.date(1900, 1, 1)
        if not end_date:
            end_date = datetime.date.today()
        time_entry_xml = self.bc.list_time_entries(self.id, start_date, end_date)
        time_entries = []
        for entry in ET.fromstring(time_entry_xml).findall("time-entry"):
            time_entries.append(TimeEntry(entry))
        self.cache['time_entries'] = time_entries
        return self.cache['time_entries']