/// <summary>Snippet for DeleteGameServerConfig</summary> public void DeleteGameServerConfigResourceNames() { // Snippet: DeleteGameServerConfig(GameServerConfigName, CallSettings) // Create client GameServerConfigsServiceClient gameServerConfigsServiceClient = GameServerConfigsServiceClient.Create(); // Initialize request argument(s) GameServerConfigName name = GameServerConfigName.FromProjectLocationDeploymentConfig("[PROJECT]", "[LOCATION]", "[DEPLOYMENT]", "[CONFIG]"); // Make the request Operation <GameServerConfig, OperationMetadata> response = gameServerConfigsServiceClient.DeleteGameServerConfig(name); // Poll until the returned long-running operation is complete Operation <GameServerConfig, OperationMetadata> completedResponse = response.PollUntilCompleted(); // Retrieve the operation result GameServerConfig result = completedResponse.Result; // Or get the name of the operation string operationName = response.Name; // This name can be stored, then the long-running operation retrieved later by name Operation <GameServerConfig, OperationMetadata> retrievedResponse = gameServerConfigsServiceClient.PollOnceDeleteGameServerConfig(operationName); // Check if the retrieved long-running operation has completed if (retrievedResponse.IsCompleted) { // If it has completed, then access the result GameServerConfig retrievedResult = retrievedResponse.Result; } // End snippet }
/// <summary>Snippet for DeleteGameServerConfig</summary> public void DeleteGameServerConfig() { // Snippet: DeleteGameServerConfig(string, CallSettings) // Create client GameServerConfigsServiceClient gameServerConfigsServiceClient = GameServerConfigsServiceClient.Create(); // Initialize request argument(s) string name = "projects/[PROJECT]/locations/[LOCATION]/gameServerDeployments/[DEPLOYMENT]/configs/[CONFIG]"; // Make the request Operation <Empty, OperationMetadata> response = gameServerConfigsServiceClient.DeleteGameServerConfig(name); // Poll until the returned long-running operation is complete Operation <Empty, OperationMetadata> completedResponse = response.PollUntilCompleted(); // Retrieve the operation result Empty result = completedResponse.Result; // Or get the name of the operation string operationName = response.Name; // This name can be stored, then the long-running operation retrieved later by name Operation <Empty, OperationMetadata> retrievedResponse = gameServerConfigsServiceClient.PollOnceDeleteGameServerConfig(operationName); // Check if the retrieved long-running operation has completed if (retrievedResponse.IsCompleted) { // If it has completed, then access the result Empty retrievedResult = retrievedResponse.Result; } // End snippet }