private Amazon.MigrationHubStrategyRecommendations.Model.UpdateApplicationComponentConfigResponse CallAWSServiceOperation(IAmazonMigrationHubStrategyRecommendations client, Amazon.MigrationHubStrategyRecommendations.Model.UpdateApplicationComponentConfigRequest request)
 {
     Utils.Common.WriteVerboseEndpointMessage(this, client.Config, "Migration Hub Strategy Recommendations", "UpdateApplicationComponentConfig");
     try
     {
         #if DESKTOP
         return(client.UpdateApplicationComponentConfig(request));
         #elif CORECLR
         return(client.UpdateApplicationComponentConfigAsync(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.MigrationHubStrategyRecommendations.Model.UpdateApplicationComponentConfigRequest();

            if (cmdletContext.ApplicationComponentId != null)
            {
                request.ApplicationComponentId = cmdletContext.ApplicationComponentId;
            }
            if (cmdletContext.InclusionStatus != null)
            {
                request.InclusionStatus = cmdletContext.InclusionStatus;
            }
            if (cmdletContext.SecretsManagerKey != null)
            {
                request.SecretsManagerKey = cmdletContext.SecretsManagerKey;
            }
            if (cmdletContext.SourceCodeList != null)
            {
                request.SourceCodeList = cmdletContext.SourceCodeList;
            }

            // populate StrategyOption
            var requestStrategyOptionIsNull = true;

            request.StrategyOption = new Amazon.MigrationHubStrategyRecommendations.Model.StrategyOption();
            System.Boolean?requestStrategyOption_strategyOption_IsPreferred = null;
            if (cmdletContext.StrategyOption_IsPreferred != null)
            {
                requestStrategyOption_strategyOption_IsPreferred = cmdletContext.StrategyOption_IsPreferred.Value;
            }
            if (requestStrategyOption_strategyOption_IsPreferred != null)
            {
                request.StrategyOption.IsPreferred = requestStrategyOption_strategyOption_IsPreferred.Value;
                requestStrategyOptionIsNull        = false;
            }
            Amazon.MigrationHubStrategyRecommendations.Strategy requestStrategyOption_strategyOption_Strategy = null;
            if (cmdletContext.StrategyOption_Strategy != null)
            {
                requestStrategyOption_strategyOption_Strategy = cmdletContext.StrategyOption_Strategy;
            }
            if (requestStrategyOption_strategyOption_Strategy != null)
            {
                request.StrategyOption.Strategy = requestStrategyOption_strategyOption_Strategy;
                requestStrategyOptionIsNull     = false;
            }
            Amazon.MigrationHubStrategyRecommendations.TargetDestination requestStrategyOption_strategyOption_TargetDestination = null;
            if (cmdletContext.StrategyOption_TargetDestination != null)
            {
                requestStrategyOption_strategyOption_TargetDestination = cmdletContext.StrategyOption_TargetDestination;
            }
            if (requestStrategyOption_strategyOption_TargetDestination != null)
            {
                request.StrategyOption.TargetDestination = requestStrategyOption_strategyOption_TargetDestination;
                requestStrategyOptionIsNull = false;
            }
            Amazon.MigrationHubStrategyRecommendations.TransformationToolName requestStrategyOption_strategyOption_ToolName = null;
            if (cmdletContext.StrategyOption_ToolName != null)
            {
                requestStrategyOption_strategyOption_ToolName = cmdletContext.StrategyOption_ToolName;
            }
            if (requestStrategyOption_strategyOption_ToolName != null)
            {
                request.StrategyOption.ToolName = requestStrategyOption_strategyOption_ToolName;
                requestStrategyOptionIsNull     = false;
            }
            // determine if request.StrategyOption should be set to null
            if (requestStrategyOptionIsNull)
            {
                request.StrategyOption = null;
            }

            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);
        }