private static IDictionary <string, string> ConvertSetLoadBalancerPoliciesOfListener(SetLoadBalancerPoliciesOfListenerRequest request) { IDictionary <string, string> dictionary = new Dictionary <string, string>(); dictionary["Action"] = "SetLoadBalancerPoliciesOfListener"; if (request.IsSetLoadBalancerName()) { dictionary["LoadBalancerName"] = request.LoadBalancerName; } if (request.IsSetLoadBalancerPort()) { dictionary["LoadBalancerPort"] = request.LoadBalancerPort.ToString(); } List <string> policyNames = request.PolicyNames; int num = 1; foreach (string str in policyNames) { dictionary["PolicyNames" + ".member." + num] = str; num++; } return(dictionary); }
/** * Convert SetLoadBalancerPoliciesOfListenerRequest to name value pairs */ private static IDictionary <string, string> ConvertSetLoadBalancerPoliciesOfListener(SetLoadBalancerPoliciesOfListenerRequest request) { IDictionary <string, string> parameters = new Dictionary <string, string>(); parameters["Action"] = "SetLoadBalancerPoliciesOfListener"; if (request.IsSetLoadBalancerName()) { parameters["LoadBalancerName"] = request.LoadBalancerName; } if (request.IsSetLoadBalancerPort()) { parameters["LoadBalancerPort"] = request.LoadBalancerPort.ToString(); } List <string> setLoadBalancerPoliciesOfListenerRequestPolicyNamesList = request.PolicyNames; int setLoadBalancerPoliciesOfListenerRequestPolicyNamesListIndex = 1; foreach (string setLoadBalancerPoliciesOfListenerRequestPolicyNames in setLoadBalancerPoliciesOfListenerRequestPolicyNamesList) { parameters[String.Concat("PolicyNames", ".member.", setLoadBalancerPoliciesOfListenerRequestPolicyNamesListIndex)] = setLoadBalancerPoliciesOfListenerRequestPolicyNames; setLoadBalancerPoliciesOfListenerRequestPolicyNamesListIndex++; } return(parameters); }