human
Write me a the Python code you requested given the following:
Complete the below
def allitems(attr=None, doc=''):

    ''''Returns a property that fetches the given attributes from
    all items in a SearchIO container object.'
    '''
assistant
#Here is the Python code you requested.
    def getter(self):
        if (attr is None):
            return self._items
        return [getattr(frag, attr) for frag in self._items]
    return property(fget=getter, doc=doc)