public static boolean isEmail(String input) {
        int atIndex = input.indexOf("@");
        if (atIndex == -1) {
            return false;
        }

        String namePart = input.substring(0, atIndex);
        if (!IndexOfFtw.validNamePart(namePart) || namePart.length() == 0) {
            return false;
        }

        String domainPart = input.substring(atIndex + 1);
        List<String> domainParts = IndexOfFtw.splitDots(domainPart);

        if (domainParts.size() < 2) {
            return false;
        }

        for (String part : domainParts) {
            if (!IndexOfFtw.validDomainPart(part) || part.length() == 0) {
                return false;
            }
        }

        return true;
    }