def find_list_string(name, str_list, case_sensitive=True, as_prefix=False, first_matched=False):
    """
    Find `name` in the string list.
    
    Comparison parameters are defined in :func:`string_equal`.
    If ``first_matched==True``, stop at the first match; otherwise if multiple occurrences happen, raise :exc:`ValueError`.
    
    Returns:
        tuple ``(index, value)``.
    """
    if not case_sensitive:
        lookup_name=name.lower()
    else:
        lookup_name=name
    found_name=None
    for i,s in enumerate(str_list):
        if not case_sensitive:
            lookup_s=s.lower()
        else:
            lookup_s=s
        if as_prefix:
            sat=lookup_s.startswith(lookup_name)
        else:
            sat=(lookup_s==lookup_name)
        if sat:
            if found_name is None:
                found_name=(i,s)
                if first_matched:
                    break
            else:
                raise ValueError("{0} and {1} both satisfy name {2}".format(found_name[1],s,name))
    if found_name is None:
        raise KeyError("can't find name in the container: {0}".format(name))
    return found_name