def build_redirect_action_dict(self, redirect_url, enable_ssl):
    '\n        This method returns a redirect action dict\n        :param redirect_url: redirect url\n        :param enable_ssl: flag for ssl enable\n        :return:\n        '
    redirect_url = self.parse_url(redirect_url)
    protocol = str(redirect_url.scheme).upper()
    hostname = str(redirect_url.hostname)
    pathstring = str(redirect_url.path)
    querystring = str(redirect_url.query)
    full_path = (('%s?%s' % (pathstring, querystring)) if (pathstring and querystring) else pathstring)
    protocol = (((enable_ssl and 'HTTPS') or 'HTTP') if (not protocol) else protocol)
    action = {'protocol': protocol}
    if hostname:
        action.update({'host': {'type': 'URI_PARAM_TYPE_TOKENIZED', 'tokens': [{'type': 'URI_TOKEN_TYPE_STRING', 'str_value': hostname, 'start_index': '0', 'end_index': '65535'}]}})
    if full_path:
        action.update({'path': {'type': 'URI_PARAM_TYPE_TOKENIZED', 'tokens': [{'type': 'URI_TOKEN_TYPE_STRING', 'str_value': full_path, 'start_index': '0', 'end_index': '65535'}]}})
    return action
This method returns a redirect action dict
:param redirect_url: redirect url
:param enable_ssl: flag for ssl enable
:return:
def build_redirect_action_dict(self, redirect_url, enable_ssl):
    '\n        This method returns a redirect action dict\n        :param redirect_url: redirect url\n        :param enable_ssl: flag for ssl enable\n        :return:\n        '
    redirect_url = self.parse_url(redirect_url)
    protocol = str(redirect_url.scheme).upper()
    hostname = str(redirect_url.hostname)
    pathstring = str(redirect_url.path)
    querystring = str(redirect_url.query)
    full_path = (('%s?%s' % (pathstring, querystring)) if (pathstring and querystring) else pathstring)
    protocol = (((enable_ssl and 'HTTPS') or 'HTTP') if (not protocol) else protocol)
    action = {'protocol': protocol}
    if hostname:
        action.update({'host': {'type': 'URI_PARAM_TYPE_TOKENIZED', 'tokens': [{'type': 'URI_TOKEN_TYPE_STRING', 'str_value': hostname, 'start_index': '0', 'end_index': '65535'}]}})
    if full_path:
        action.update({'path': {'type': 'URI_PARAM_TYPE_TOKENIZED', 'tokens': [{'type': 'URI_TOKEN_TYPE_STRING', 'str_value': full_path, 'start_index': '0', 'end_index': '65535'}]}})
    return action