from typing import Tuple
from typing import Optional


def parse_fully_qualified_name(fq_name: str) -> Tuple[Optional[str], str]:
    """
    Parse the given fully-quallified name (separated with dots) to a tuple of module and class names.

    :param fq_name: fully qualified name separated with dots
    :return: ``None`` instead of module if the given name contains no separators (dots).
    """
    last_dot = fq_name.rfind('.')
    if last_dot != -1:
        return fq_name[:last_dot], fq_name[last_dot + 1:]
    else:
        return None, fq_name