public static ConnectionDetails fromAddress(String fullAddress) {
        ConnectionDetails cd = new ConnectionDetails();

        if (fullAddress != null) {
            if ( fullAddress.matches(".+:\\d{3,}$") ) {
                int upto = fullAddress.lastIndexOf(":");
                cd.address = fullAddress.substring(0, upto);
                cd.port = Integer.parseInt( fullAddress.substring(upto + 1) );
            } else {
                cd.address = fullAddress;
            }
        }

        return cd;
    }