class ZMSUtils {

    public static String lowerDomainInResource(String resource) {
        if (resource == null) {
            return null;
        }

        int delimiterIndex = resource.indexOf(":");
        if (delimiterIndex == -1) {
            return resource;
        }

        String lowerCasedDomain = resource.substring(0, delimiterIndex).toLowerCase();
        return lowerCasedDomain + resource.substring(delimiterIndex);
    }

}