def _non_blank_line_count(string):
    """
    Parameters
    ----------
    string : str or unicode
        String (potentially multi-line) to search in.

    Returns
    -------
    int
        Number of non-blank lines in string.
    """

    non_blank_counter = 0

    for line in string.splitlines():

        if line.strip():
            non_blank_counter += 1

    return non_blank_counter