def METHOD_NAME(self, source, recurse=True, flat=False):
    """
    Iterate over the cases.
    Parameters
    ----------
    source : 'problem', 'driver', component pathname, solver pathname, case_name
        Identifies which cases to return.
    recurse : bool, optional
        If True, will enable iterating over all successors in case hierarchy.
    flat : bool, optional
        If False and there are child cases, then a nested ordered dictionary
        is returned rather than an iterator.
    Returns
    -------
    list or dict
        The cases identified by source.
    """
    pass