@staticmethod
def append_url_with_query_parameters(url, parameters):
    """Appends the given set of parameters to the given query string.

        Args:
            url (str): The query url string to append the parameters.
            parameters (dict): The parameters to append.

        Returns:
            str: Url with appended query parameters.

        """
    if url is None:
        raise ValueError('url is null')
    if parameters is None:
        return url
    has_params = '?' in url
    for key in parameters:
        element = parameters[key]
        if element is None:
            continue
        separator = '&' if has_params else '?'
        if isinstance(element, list):
            url = url + '{0}{1}[]={2}'.format(separator, key, '&{0}[]='.
                format(key).join(element))
        else:
            url = url + '{0}{1}={2}'.format(separator, key, str(parameters[
                key]))
        has_params = True
    return url
