private Amazon.AppMesh.Model.CreateGatewayRouteResponse CallAWSServiceOperation(IAmazonAppMesh client, Amazon.AppMesh.Model.CreateGatewayRouteRequest request)
 {
     Utils.Common.WriteVerboseEndpointMessage(this, client.Config, "AWS App Mesh", "CreateGatewayRoute");
     try
     {
         #if DESKTOP
         return(client.CreateGatewayRoute(request));
         #elif CORECLR
         return(client.CreateGatewayRouteAsync(request).GetAwaiter().GetResult());
         #else
                 #error "Unknown build edition"
         #endif
     }
     catch (AmazonServiceException exc)
     {
         var webException = exc.InnerException as System.Net.WebException;
         if (webException != null)
         {
             throw new Exception(Utils.Common.FormatNameResolutionFailureMessage(client.Config, webException.Message), webException);
         }
         throw;
     }
 }
        public object Execute(ExecutorContext context)
        {
            var cmdletContext = context as CmdletContext;
            // create request
            var request = new Amazon.AppMesh.Model.CreateGatewayRouteRequest();

            if (cmdletContext.ClientToken != null)
            {
                request.ClientToken = cmdletContext.ClientToken;
            }
            if (cmdletContext.GatewayRouteName != null)
            {
                request.GatewayRouteName = cmdletContext.GatewayRouteName;
            }
            if (cmdletContext.MeshName != null)
            {
                request.MeshName = cmdletContext.MeshName;
            }
            if (cmdletContext.MeshOwner != null)
            {
                request.MeshOwner = cmdletContext.MeshOwner;
            }

            // populate Spec
            var requestSpecIsNull = true;

            request.Spec = new Amazon.AppMesh.Model.GatewayRouteSpec();
            Amazon.AppMesh.Model.GrpcGatewayRoute requestSpec_spec_GrpcRoute = null;

            // populate GrpcRoute
            var requestSpec_spec_GrpcRouteIsNull = true;

            requestSpec_spec_GrpcRoute = new Amazon.AppMesh.Model.GrpcGatewayRoute();
            Amazon.AppMesh.Model.GrpcGatewayRouteAction requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action = null;

            // populate Action
            var requestSpec_spec_GrpcRoute_spec_GrpcRoute_ActionIsNull = true;

            requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action = new Amazon.AppMesh.Model.GrpcGatewayRouteAction();
            Amazon.AppMesh.Model.GatewayRouteTarget requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target = null;

            // populate Target
            var requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_TargetIsNull = true;

            requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target = new Amazon.AppMesh.Model.GatewayRouteTarget();
            Amazon.AppMesh.Model.GatewayRouteVirtualService requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService = null;

            // populate VirtualService
            var requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualServiceIsNull = true;

            requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService = new Amazon.AppMesh.Model.GatewayRouteVirtualService();
            System.String requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService_spec_GrpcRoute_Action_Target_VirtualService = null;
            if (cmdletContext.Spec_GrpcRoute_Action_Target_VirtualService != null)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService_spec_GrpcRoute_Action_Target_VirtualService = cmdletContext.Spec_GrpcRoute_Action_Target_VirtualService;
            }
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService_spec_GrpcRoute_Action_Target_VirtualService != null)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService.VirtualServiceName = requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService_spec_GrpcRoute_Action_Target_VirtualService;
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualServiceIsNull = false;
            }
            // determine if requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService should be set to null
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualServiceIsNull)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService = null;
            }
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService != null)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target.VirtualService = requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target_spec_GrpcRoute_Action_Target_VirtualService;
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_TargetIsNull          = false;
            }
            // determine if requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target should be set to null
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_TargetIsNull)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target = null;
            }
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target != null)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action.Target = requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action_spec_GrpcRoute_Action_Target;
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_ActionIsNull  = false;
            }
            // determine if requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action should be set to null
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_ActionIsNull)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action = null;
            }
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action != null)
            {
                requestSpec_spec_GrpcRoute.Action = requestSpec_spec_GrpcRoute_spec_GrpcRoute_Action;
                requestSpec_spec_GrpcRouteIsNull  = false;
            }
            Amazon.AppMesh.Model.GrpcGatewayRouteMatch requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match = null;

            // populate Match
            var requestSpec_spec_GrpcRoute_spec_GrpcRoute_MatchIsNull = true;

            requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match = new Amazon.AppMesh.Model.GrpcGatewayRouteMatch();
            System.String requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match_spec_GrpcRoute_Match_ServiceName = null;
            if (cmdletContext.Spec_GrpcRoute_Match_ServiceName != null)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match_spec_GrpcRoute_Match_ServiceName = cmdletContext.Spec_GrpcRoute_Match_ServiceName;
            }
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match_spec_GrpcRoute_Match_ServiceName != null)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match.ServiceName = requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match_spec_GrpcRoute_Match_ServiceName;
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_MatchIsNull       = false;
            }
            // determine if requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match should be set to null
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_MatchIsNull)
            {
                requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match = null;
            }
            if (requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match != null)
            {
                requestSpec_spec_GrpcRoute.Match = requestSpec_spec_GrpcRoute_spec_GrpcRoute_Match;
                requestSpec_spec_GrpcRouteIsNull = false;
            }
            // determine if requestSpec_spec_GrpcRoute should be set to null
            if (requestSpec_spec_GrpcRouteIsNull)
            {
                requestSpec_spec_GrpcRoute = null;
            }
            if (requestSpec_spec_GrpcRoute != null)
            {
                request.Spec.GrpcRoute = requestSpec_spec_GrpcRoute;
                requestSpecIsNull      = false;
            }
            Amazon.AppMesh.Model.HttpGatewayRoute requestSpec_spec_Http2Route = null;

            // populate Http2Route
            var requestSpec_spec_Http2RouteIsNull = true;

            requestSpec_spec_Http2Route = new Amazon.AppMesh.Model.HttpGatewayRoute();
            Amazon.AppMesh.Model.HttpGatewayRouteAction requestSpec_spec_Http2Route_spec_Http2Route_Action = null;

            // populate Action
            var requestSpec_spec_Http2Route_spec_Http2Route_ActionIsNull = true;

            requestSpec_spec_Http2Route_spec_Http2Route_Action = new Amazon.AppMesh.Model.HttpGatewayRouteAction();
            Amazon.AppMesh.Model.GatewayRouteTarget requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target = null;

            // populate Target
            var requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_TargetIsNull = true;

            requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target = new Amazon.AppMesh.Model.GatewayRouteTarget();
            Amazon.AppMesh.Model.GatewayRouteVirtualService requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService = null;

            // populate VirtualService
            var requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualServiceIsNull = true;

            requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService = new Amazon.AppMesh.Model.GatewayRouteVirtualService();
            System.String requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService_spec_Http2Route_Action_Target_VirtualService = null;
            if (cmdletContext.Spec_Http2Route_Action_Target_VirtualService != null)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService_spec_Http2Route_Action_Target_VirtualService = cmdletContext.Spec_Http2Route_Action_Target_VirtualService;
            }
            if (requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService_spec_Http2Route_Action_Target_VirtualService != null)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService.VirtualServiceName = requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService_spec_Http2Route_Action_Target_VirtualService;
                requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualServiceIsNull = false;
            }
            // determine if requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService should be set to null
            if (requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualServiceIsNull)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService = null;
            }
            if (requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService != null)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target.VirtualService = requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target_spec_Http2Route_Action_Target_VirtualService;
                requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_TargetIsNull          = false;
            }
            // determine if requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target should be set to null
            if (requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_TargetIsNull)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target = null;
            }
            if (requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target != null)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Action.Target = requestSpec_spec_Http2Route_spec_Http2Route_Action_spec_Http2Route_Action_Target;
                requestSpec_spec_Http2Route_spec_Http2Route_ActionIsNull  = false;
            }
            // determine if requestSpec_spec_Http2Route_spec_Http2Route_Action should be set to null
            if (requestSpec_spec_Http2Route_spec_Http2Route_ActionIsNull)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Action = null;
            }
            if (requestSpec_spec_Http2Route_spec_Http2Route_Action != null)
            {
                requestSpec_spec_Http2Route.Action = requestSpec_spec_Http2Route_spec_Http2Route_Action;
                requestSpec_spec_Http2RouteIsNull  = false;
            }
            Amazon.AppMesh.Model.HttpGatewayRouteMatch requestSpec_spec_Http2Route_spec_Http2Route_Match = null;

            // populate Match
            var requestSpec_spec_Http2Route_spec_Http2Route_MatchIsNull = true;

            requestSpec_spec_Http2Route_spec_Http2Route_Match = new Amazon.AppMesh.Model.HttpGatewayRouteMatch();
            System.String requestSpec_spec_Http2Route_spec_Http2Route_Match_spec_Http2Route_Match_Prefix = null;
            if (cmdletContext.Spec_Http2Route_Match_Prefix != null)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Match_spec_Http2Route_Match_Prefix = cmdletContext.Spec_Http2Route_Match_Prefix;
            }
            if (requestSpec_spec_Http2Route_spec_Http2Route_Match_spec_Http2Route_Match_Prefix != null)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Match.Prefix = requestSpec_spec_Http2Route_spec_Http2Route_Match_spec_Http2Route_Match_Prefix;
                requestSpec_spec_Http2Route_spec_Http2Route_MatchIsNull  = false;
            }
            // determine if requestSpec_spec_Http2Route_spec_Http2Route_Match should be set to null
            if (requestSpec_spec_Http2Route_spec_Http2Route_MatchIsNull)
            {
                requestSpec_spec_Http2Route_spec_Http2Route_Match = null;
            }
            if (requestSpec_spec_Http2Route_spec_Http2Route_Match != null)
            {
                requestSpec_spec_Http2Route.Match = requestSpec_spec_Http2Route_spec_Http2Route_Match;
                requestSpec_spec_Http2RouteIsNull = false;
            }
            // determine if requestSpec_spec_Http2Route should be set to null
            if (requestSpec_spec_Http2RouteIsNull)
            {
                requestSpec_spec_Http2Route = null;
            }
            if (requestSpec_spec_Http2Route != null)
            {
                request.Spec.Http2Route = requestSpec_spec_Http2Route;
                requestSpecIsNull       = false;
            }
            Amazon.AppMesh.Model.HttpGatewayRoute requestSpec_spec_HttpRoute = null;

            // populate HttpRoute
            var requestSpec_spec_HttpRouteIsNull = true;

            requestSpec_spec_HttpRoute = new Amazon.AppMesh.Model.HttpGatewayRoute();
            Amazon.AppMesh.Model.HttpGatewayRouteAction requestSpec_spec_HttpRoute_spec_HttpRoute_Action = null;

            // populate Action
            var requestSpec_spec_HttpRoute_spec_HttpRoute_ActionIsNull = true;

            requestSpec_spec_HttpRoute_spec_HttpRoute_Action = new Amazon.AppMesh.Model.HttpGatewayRouteAction();
            Amazon.AppMesh.Model.GatewayRouteTarget requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target = null;

            // populate Target
            var requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_TargetIsNull = true;

            requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target = new Amazon.AppMesh.Model.GatewayRouteTarget();
            Amazon.AppMesh.Model.GatewayRouteVirtualService requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService = null;

            // populate VirtualService
            var requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualServiceIsNull = true;

            requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService = new Amazon.AppMesh.Model.GatewayRouteVirtualService();
            System.String requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService_spec_HttpRoute_Action_Target_VirtualService = null;
            if (cmdletContext.Spec_HttpRoute_Action_Target_VirtualService != null)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService_spec_HttpRoute_Action_Target_VirtualService = cmdletContext.Spec_HttpRoute_Action_Target_VirtualService;
            }
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService_spec_HttpRoute_Action_Target_VirtualService != null)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService.VirtualServiceName = requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService_spec_HttpRoute_Action_Target_VirtualService;
                requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualServiceIsNull = false;
            }
            // determine if requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService should be set to null
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualServiceIsNull)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService = null;
            }
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService != null)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target.VirtualService = requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target_spec_HttpRoute_Action_Target_VirtualService;
                requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_TargetIsNull          = false;
            }
            // determine if requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target should be set to null
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_TargetIsNull)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target = null;
            }
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target != null)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Action.Target = requestSpec_spec_HttpRoute_spec_HttpRoute_Action_spec_HttpRoute_Action_Target;
                requestSpec_spec_HttpRoute_spec_HttpRoute_ActionIsNull  = false;
            }
            // determine if requestSpec_spec_HttpRoute_spec_HttpRoute_Action should be set to null
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_ActionIsNull)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Action = null;
            }
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_Action != null)
            {
                requestSpec_spec_HttpRoute.Action = requestSpec_spec_HttpRoute_spec_HttpRoute_Action;
                requestSpec_spec_HttpRouteIsNull  = false;
            }
            Amazon.AppMesh.Model.HttpGatewayRouteMatch requestSpec_spec_HttpRoute_spec_HttpRoute_Match = null;

            // populate Match
            var requestSpec_spec_HttpRoute_spec_HttpRoute_MatchIsNull = true;

            requestSpec_spec_HttpRoute_spec_HttpRoute_Match = new Amazon.AppMesh.Model.HttpGatewayRouteMatch();
            System.String requestSpec_spec_HttpRoute_spec_HttpRoute_Match_spec_HttpRoute_Match_Prefix = null;
            if (cmdletContext.Spec_HttpRoute_Match_Prefix != null)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Match_spec_HttpRoute_Match_Prefix = cmdletContext.Spec_HttpRoute_Match_Prefix;
            }
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_Match_spec_HttpRoute_Match_Prefix != null)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Match.Prefix = requestSpec_spec_HttpRoute_spec_HttpRoute_Match_spec_HttpRoute_Match_Prefix;
                requestSpec_spec_HttpRoute_spec_HttpRoute_MatchIsNull  = false;
            }
            // determine if requestSpec_spec_HttpRoute_spec_HttpRoute_Match should be set to null
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_MatchIsNull)
            {
                requestSpec_spec_HttpRoute_spec_HttpRoute_Match = null;
            }
            if (requestSpec_spec_HttpRoute_spec_HttpRoute_Match != null)
            {
                requestSpec_spec_HttpRoute.Match = requestSpec_spec_HttpRoute_spec_HttpRoute_Match;
                requestSpec_spec_HttpRouteIsNull = false;
            }
            // determine if requestSpec_spec_HttpRoute should be set to null
            if (requestSpec_spec_HttpRouteIsNull)
            {
                requestSpec_spec_HttpRoute = null;
            }
            if (requestSpec_spec_HttpRoute != null)
            {
                request.Spec.HttpRoute = requestSpec_spec_HttpRoute;
                requestSpecIsNull      = false;
            }
            // determine if request.Spec should be set to null
            if (requestSpecIsNull)
            {
                request.Spec = null;
            }
            if (cmdletContext.Tag != null)
            {
                request.Tags = cmdletContext.Tag;
            }
            if (cmdletContext.VirtualGatewayName != null)
            {
                request.VirtualGatewayName = cmdletContext.VirtualGatewayName;
            }

            CmdletOutput output;

            // issue call
            var client = Client ?? CreateClient(_CurrentCredentials, _RegionEndpoint);

            try
            {
                var    response       = CallAWSServiceOperation(client, request);
                object pipelineOutput = null;
                pipelineOutput = cmdletContext.Select(response, this);
                output         = new CmdletOutput
                {
                    PipelineOutput  = pipelineOutput,
                    ServiceResponse = response
                };
            }
            catch (Exception e)
            {
                output = new CmdletOutput {
                    ErrorResponse = e
                };
            }

            return(output);
        }