...

Source file src/github.com/Azure/azure-sdk-for-go/services/preview/cosmos-db/mgmt/2021-11-15-preview/documentdb/cassandraresources.go

Documentation: github.com/Azure/azure-sdk-for-go/services/preview/cosmos-db/mgmt/2021-11-15-preview/documentdb

     1  package documentdb
     2  
     3  // Copyright (c) Microsoft Corporation. All rights reserved.
     4  // Licensed under the MIT License. See License.txt in the project root for license information.
     5  //
     6  // Code generated by Microsoft (R) AutoRest Code Generator.
     7  // Changes may cause incorrect behavior and will be lost if the code is regenerated.
     8  
     9  import (
    10  	"context"
    11  	"github.com/Azure/go-autorest/autorest"
    12  	"github.com/Azure/go-autorest/autorest/azure"
    13  	"github.com/Azure/go-autorest/autorest/validation"
    14  	"github.com/Azure/go-autorest/tracing"
    15  	"net/http"
    16  )
    17  
    18  // CassandraResourcesClient is the client for the CassandraResources methods of the Documentdb service.
    19  type CassandraResourcesClient struct {
    20  	BaseClient
    21  }
    22  
    23  // NewCassandraResourcesClient creates an instance of the CassandraResourcesClient client.
    24  func NewCassandraResourcesClient(subscriptionID string) CassandraResourcesClient {
    25  	return NewCassandraResourcesClientWithBaseURI(DefaultBaseURI, subscriptionID)
    26  }
    27  
    28  // NewCassandraResourcesClientWithBaseURI creates an instance of the CassandraResourcesClient client using a custom
    29  // endpoint.  Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure
    30  // stack).
    31  func NewCassandraResourcesClientWithBaseURI(baseURI string, subscriptionID string) CassandraResourcesClient {
    32  	return CassandraResourcesClient{NewWithBaseURI(baseURI, subscriptionID)}
    33  }
    34  
    35  // CreateUpdateCassandraKeyspace create or update an Azure Cosmos DB Cassandra keyspace
    36  // Parameters:
    37  // resourceGroupName - the name of the resource group. The name is case insensitive.
    38  // accountName - cosmos DB database account name.
    39  // keyspaceName - cosmos DB keyspace name.
    40  // createUpdateCassandraKeyspaceParameters - the parameters to provide for the current Cassandra keyspace.
    41  func (client CassandraResourcesClient) CreateUpdateCassandraKeyspace(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, createUpdateCassandraKeyspaceParameters CassandraKeyspaceCreateUpdateParameters) (result CassandraResourcesCreateUpdateCassandraKeyspaceFuture, err error) {
    42  	if tracing.IsEnabled() {
    43  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.CreateUpdateCassandraKeyspace")
    44  		defer func() {
    45  			sc := -1
    46  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
    47  				sc = result.FutureAPI.Response().StatusCode
    48  			}
    49  			tracing.EndSpan(ctx, sc, err)
    50  		}()
    51  	}
    52  	if err := validation.Validate([]validation.Validation{
    53  		{TargetValue: client.SubscriptionID,
    54  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
    55  		{TargetValue: resourceGroupName,
    56  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
    57  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
    58  		{TargetValue: accountName,
    59  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
    60  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
    61  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}},
    62  		{TargetValue: createUpdateCassandraKeyspaceParameters,
    63  			Constraints: []validation.Constraint{{Target: "createUpdateCassandraKeyspaceParameters.CassandraKeyspaceCreateUpdateProperties", Name: validation.Null, Rule: true,
    64  				Chain: []validation.Constraint{{Target: "createUpdateCassandraKeyspaceParameters.CassandraKeyspaceCreateUpdateProperties.Resource", Name: validation.Null, Rule: true,
    65  					Chain: []validation.Constraint{{Target: "createUpdateCassandraKeyspaceParameters.CassandraKeyspaceCreateUpdateProperties.Resource.ID", Name: validation.Null, Rule: true, Chain: nil}}},
    66  				}}}}}); err != nil {
    67  		return result, validation.NewError("documentdb.CassandraResourcesClient", "CreateUpdateCassandraKeyspace", err.Error())
    68  	}
    69  
    70  	req, err := client.CreateUpdateCassandraKeyspacePreparer(ctx, resourceGroupName, accountName, keyspaceName, createUpdateCassandraKeyspaceParameters)
    71  	if err != nil {
    72  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "CreateUpdateCassandraKeyspace", nil, "Failure preparing request")
    73  		return
    74  	}
    75  
    76  	result, err = client.CreateUpdateCassandraKeyspaceSender(req)
    77  	if err != nil {
    78  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "CreateUpdateCassandraKeyspace", result.Response(), "Failure sending request")
    79  		return
    80  	}
    81  
    82  	return
    83  }
    84  
    85  // CreateUpdateCassandraKeyspacePreparer prepares the CreateUpdateCassandraKeyspace request.
    86  func (client CassandraResourcesClient) CreateUpdateCassandraKeyspacePreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, createUpdateCassandraKeyspaceParameters CassandraKeyspaceCreateUpdateParameters) (*http.Request, error) {
    87  	pathParameters := map[string]interface{}{
    88  		"accountName":       autorest.Encode("path", accountName),
    89  		"keyspaceName":      autorest.Encode("path", keyspaceName),
    90  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
    91  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
    92  	}
    93  
    94  	const APIVersion = "2021-11-15-preview"
    95  	queryParameters := map[string]interface{}{
    96  		"api-version": APIVersion,
    97  	}
    98  
    99  	preparer := autorest.CreatePreparer(
   100  		autorest.AsContentType("application/json; charset=utf-8"),
   101  		autorest.AsPut(),
   102  		autorest.WithBaseURL(client.BaseURI),
   103  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}", pathParameters),
   104  		autorest.WithJSON(createUpdateCassandraKeyspaceParameters),
   105  		autorest.WithQueryParameters(queryParameters))
   106  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   107  }
   108  
   109  // CreateUpdateCassandraKeyspaceSender sends the CreateUpdateCassandraKeyspace request. The method will close the
   110  // http.Response Body if it receives an error.
   111  func (client CassandraResourcesClient) CreateUpdateCassandraKeyspaceSender(req *http.Request) (future CassandraResourcesCreateUpdateCassandraKeyspaceFuture, err error) {
   112  	var resp *http.Response
   113  	future.FutureAPI = &azure.Future{}
   114  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
   115  	if err != nil {
   116  		return
   117  	}
   118  	var azf azure.Future
   119  	azf, err = azure.NewFutureFromResponse(resp)
   120  	future.FutureAPI = &azf
   121  	future.Result = future.result
   122  	return
   123  }
   124  
   125  // CreateUpdateCassandraKeyspaceResponder handles the response to the CreateUpdateCassandraKeyspace request. The method always
   126  // closes the http.Response Body.
   127  func (client CassandraResourcesClient) CreateUpdateCassandraKeyspaceResponder(resp *http.Response) (result CassandraKeyspaceGetResults, err error) {
   128  	err = autorest.Respond(
   129  		resp,
   130  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
   131  		autorest.ByUnmarshallingJSON(&result),
   132  		autorest.ByClosing())
   133  	result.Response = autorest.Response{Response: resp}
   134  	return
   135  }
   136  
   137  // CreateUpdateCassandraTable create or update an Azure Cosmos DB Cassandra Table
   138  // Parameters:
   139  // resourceGroupName - the name of the resource group. The name is case insensitive.
   140  // accountName - cosmos DB database account name.
   141  // keyspaceName - cosmos DB keyspace name.
   142  // tableName - cosmos DB table name.
   143  // createUpdateCassandraTableParameters - the parameters to provide for the current Cassandra Table.
   144  func (client CassandraResourcesClient) CreateUpdateCassandraTable(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string, createUpdateCassandraTableParameters CassandraTableCreateUpdateParameters) (result CassandraResourcesCreateUpdateCassandraTableFuture, err error) {
   145  	if tracing.IsEnabled() {
   146  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.CreateUpdateCassandraTable")
   147  		defer func() {
   148  			sc := -1
   149  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
   150  				sc = result.FutureAPI.Response().StatusCode
   151  			}
   152  			tracing.EndSpan(ctx, sc, err)
   153  		}()
   154  	}
   155  	if err := validation.Validate([]validation.Validation{
   156  		{TargetValue: client.SubscriptionID,
   157  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   158  		{TargetValue: resourceGroupName,
   159  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   160  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   161  		{TargetValue: accountName,
   162  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
   163  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
   164  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}},
   165  		{TargetValue: createUpdateCassandraTableParameters,
   166  			Constraints: []validation.Constraint{{Target: "createUpdateCassandraTableParameters.CassandraTableCreateUpdateProperties", Name: validation.Null, Rule: true,
   167  				Chain: []validation.Constraint{{Target: "createUpdateCassandraTableParameters.CassandraTableCreateUpdateProperties.Resource", Name: validation.Null, Rule: true,
   168  					Chain: []validation.Constraint{{Target: "createUpdateCassandraTableParameters.CassandraTableCreateUpdateProperties.Resource.ID", Name: validation.Null, Rule: true, Chain: nil}}},
   169  				}}}}}); err != nil {
   170  		return result, validation.NewError("documentdb.CassandraResourcesClient", "CreateUpdateCassandraTable", err.Error())
   171  	}
   172  
   173  	req, err := client.CreateUpdateCassandraTablePreparer(ctx, resourceGroupName, accountName, keyspaceName, tableName, createUpdateCassandraTableParameters)
   174  	if err != nil {
   175  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "CreateUpdateCassandraTable", nil, "Failure preparing request")
   176  		return
   177  	}
   178  
   179  	result, err = client.CreateUpdateCassandraTableSender(req)
   180  	if err != nil {
   181  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "CreateUpdateCassandraTable", result.Response(), "Failure sending request")
   182  		return
   183  	}
   184  
   185  	return
   186  }
   187  
   188  // CreateUpdateCassandraTablePreparer prepares the CreateUpdateCassandraTable request.
   189  func (client CassandraResourcesClient) CreateUpdateCassandraTablePreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string, createUpdateCassandraTableParameters CassandraTableCreateUpdateParameters) (*http.Request, error) {
   190  	pathParameters := map[string]interface{}{
   191  		"accountName":       autorest.Encode("path", accountName),
   192  		"keyspaceName":      autorest.Encode("path", keyspaceName),
   193  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   194  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   195  		"tableName":         autorest.Encode("path", tableName),
   196  	}
   197  
   198  	const APIVersion = "2021-11-15-preview"
   199  	queryParameters := map[string]interface{}{
   200  		"api-version": APIVersion,
   201  	}
   202  
   203  	preparer := autorest.CreatePreparer(
   204  		autorest.AsContentType("application/json; charset=utf-8"),
   205  		autorest.AsPut(),
   206  		autorest.WithBaseURL(client.BaseURI),
   207  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/tables/{tableName}", pathParameters),
   208  		autorest.WithJSON(createUpdateCassandraTableParameters),
   209  		autorest.WithQueryParameters(queryParameters))
   210  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   211  }
   212  
   213  // CreateUpdateCassandraTableSender sends the CreateUpdateCassandraTable request. The method will close the
   214  // http.Response Body if it receives an error.
   215  func (client CassandraResourcesClient) CreateUpdateCassandraTableSender(req *http.Request) (future CassandraResourcesCreateUpdateCassandraTableFuture, err error) {
   216  	var resp *http.Response
   217  	future.FutureAPI = &azure.Future{}
   218  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
   219  	if err != nil {
   220  		return
   221  	}
   222  	var azf azure.Future
   223  	azf, err = azure.NewFutureFromResponse(resp)
   224  	future.FutureAPI = &azf
   225  	future.Result = future.result
   226  	return
   227  }
   228  
   229  // CreateUpdateCassandraTableResponder handles the response to the CreateUpdateCassandraTable request. The method always
   230  // closes the http.Response Body.
   231  func (client CassandraResourcesClient) CreateUpdateCassandraTableResponder(resp *http.Response) (result CassandraTableGetResults, err error) {
   232  	err = autorest.Respond(
   233  		resp,
   234  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
   235  		autorest.ByUnmarshallingJSON(&result),
   236  		autorest.ByClosing())
   237  	result.Response = autorest.Response{Response: resp}
   238  	return
   239  }
   240  
   241  // CreateUpdateCassandraView create or update an Azure Cosmos DB Cassandra View
   242  // Parameters:
   243  // resourceGroupName - the name of the resource group. The name is case insensitive.
   244  // accountName - cosmos DB database account name.
   245  // keyspaceName - cosmos DB keyspace name.
   246  // viewName - cosmos DB view name.
   247  // createUpdateCassandraViewParameters - the parameters to provide for the current Cassandra View.
   248  func (client CassandraResourcesClient) CreateUpdateCassandraView(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string, createUpdateCassandraViewParameters CassandraViewCreateUpdateParameters) (result CassandraResourcesCreateUpdateCassandraViewFuture, err error) {
   249  	if tracing.IsEnabled() {
   250  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.CreateUpdateCassandraView")
   251  		defer func() {
   252  			sc := -1
   253  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
   254  				sc = result.FutureAPI.Response().StatusCode
   255  			}
   256  			tracing.EndSpan(ctx, sc, err)
   257  		}()
   258  	}
   259  	if err := validation.Validate([]validation.Validation{
   260  		{TargetValue: client.SubscriptionID,
   261  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   262  		{TargetValue: resourceGroupName,
   263  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   264  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   265  		{TargetValue: accountName,
   266  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
   267  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
   268  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}},
   269  		{TargetValue: createUpdateCassandraViewParameters,
   270  			Constraints: []validation.Constraint{{Target: "createUpdateCassandraViewParameters.CassandraViewCreateUpdateProperties", Name: validation.Null, Rule: true,
   271  				Chain: []validation.Constraint{{Target: "createUpdateCassandraViewParameters.CassandraViewCreateUpdateProperties.Resource", Name: validation.Null, Rule: true,
   272  					Chain: []validation.Constraint{{Target: "createUpdateCassandraViewParameters.CassandraViewCreateUpdateProperties.Resource.ID", Name: validation.Null, Rule: true, Chain: nil},
   273  						{Target: "createUpdateCassandraViewParameters.CassandraViewCreateUpdateProperties.Resource.ViewDefinition", Name: validation.Null, Rule: true, Chain: nil},
   274  					}},
   275  				}}}}}); err != nil {
   276  		return result, validation.NewError("documentdb.CassandraResourcesClient", "CreateUpdateCassandraView", err.Error())
   277  	}
   278  
   279  	req, err := client.CreateUpdateCassandraViewPreparer(ctx, resourceGroupName, accountName, keyspaceName, viewName, createUpdateCassandraViewParameters)
   280  	if err != nil {
   281  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "CreateUpdateCassandraView", nil, "Failure preparing request")
   282  		return
   283  	}
   284  
   285  	result, err = client.CreateUpdateCassandraViewSender(req)
   286  	if err != nil {
   287  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "CreateUpdateCassandraView", result.Response(), "Failure sending request")
   288  		return
   289  	}
   290  
   291  	return
   292  }
   293  
   294  // CreateUpdateCassandraViewPreparer prepares the CreateUpdateCassandraView request.
   295  func (client CassandraResourcesClient) CreateUpdateCassandraViewPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string, createUpdateCassandraViewParameters CassandraViewCreateUpdateParameters) (*http.Request, error) {
   296  	pathParameters := map[string]interface{}{
   297  		"accountName":       autorest.Encode("path", accountName),
   298  		"keyspaceName":      autorest.Encode("path", keyspaceName),
   299  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   300  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   301  		"viewName":          autorest.Encode("path", viewName),
   302  	}
   303  
   304  	const APIVersion = "2021-11-15-preview"
   305  	queryParameters := map[string]interface{}{
   306  		"api-version": APIVersion,
   307  	}
   308  
   309  	preparer := autorest.CreatePreparer(
   310  		autorest.AsContentType("application/json; charset=utf-8"),
   311  		autorest.AsPut(),
   312  		autorest.WithBaseURL(client.BaseURI),
   313  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}", pathParameters),
   314  		autorest.WithJSON(createUpdateCassandraViewParameters),
   315  		autorest.WithQueryParameters(queryParameters))
   316  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   317  }
   318  
   319  // CreateUpdateCassandraViewSender sends the CreateUpdateCassandraView request. The method will close the
   320  // http.Response Body if it receives an error.
   321  func (client CassandraResourcesClient) CreateUpdateCassandraViewSender(req *http.Request) (future CassandraResourcesCreateUpdateCassandraViewFuture, err error) {
   322  	var resp *http.Response
   323  	future.FutureAPI = &azure.Future{}
   324  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
   325  	if err != nil {
   326  		return
   327  	}
   328  	var azf azure.Future
   329  	azf, err = azure.NewFutureFromResponse(resp)
   330  	future.FutureAPI = &azf
   331  	future.Result = future.result
   332  	return
   333  }
   334  
   335  // CreateUpdateCassandraViewResponder handles the response to the CreateUpdateCassandraView request. The method always
   336  // closes the http.Response Body.
   337  func (client CassandraResourcesClient) CreateUpdateCassandraViewResponder(resp *http.Response) (result CassandraViewGetResults, err error) {
   338  	err = autorest.Respond(
   339  		resp,
   340  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
   341  		autorest.ByUnmarshallingJSON(&result),
   342  		autorest.ByClosing())
   343  	result.Response = autorest.Response{Response: resp}
   344  	return
   345  }
   346  
   347  // DeleteCassandraKeyspace deletes an existing Azure Cosmos DB Cassandra keyspace.
   348  // Parameters:
   349  // resourceGroupName - the name of the resource group. The name is case insensitive.
   350  // accountName - cosmos DB database account name.
   351  // keyspaceName - cosmos DB keyspace name.
   352  func (client CassandraResourcesClient) DeleteCassandraKeyspace(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (result CassandraResourcesDeleteCassandraKeyspaceFuture, err error) {
   353  	if tracing.IsEnabled() {
   354  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.DeleteCassandraKeyspace")
   355  		defer func() {
   356  			sc := -1
   357  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
   358  				sc = result.FutureAPI.Response().StatusCode
   359  			}
   360  			tracing.EndSpan(ctx, sc, err)
   361  		}()
   362  	}
   363  	if err := validation.Validate([]validation.Validation{
   364  		{TargetValue: client.SubscriptionID,
   365  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   366  		{TargetValue: resourceGroupName,
   367  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   368  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   369  		{TargetValue: accountName,
   370  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
   371  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
   372  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
   373  		return result, validation.NewError("documentdb.CassandraResourcesClient", "DeleteCassandraKeyspace", err.Error())
   374  	}
   375  
   376  	req, err := client.DeleteCassandraKeyspacePreparer(ctx, resourceGroupName, accountName, keyspaceName)
   377  	if err != nil {
   378  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "DeleteCassandraKeyspace", nil, "Failure preparing request")
   379  		return
   380  	}
   381  
   382  	result, err = client.DeleteCassandraKeyspaceSender(req)
   383  	if err != nil {
   384  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "DeleteCassandraKeyspace", result.Response(), "Failure sending request")
   385  		return
   386  	}
   387  
   388  	return
   389  }
   390  
   391  // DeleteCassandraKeyspacePreparer prepares the DeleteCassandraKeyspace request.
   392  func (client CassandraResourcesClient) DeleteCassandraKeyspacePreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (*http.Request, error) {
   393  	pathParameters := map[string]interface{}{
   394  		"accountName":       autorest.Encode("path", accountName),
   395  		"keyspaceName":      autorest.Encode("path", keyspaceName),
   396  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   397  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   398  	}
   399  
   400  	const APIVersion = "2021-11-15-preview"
   401  	queryParameters := map[string]interface{}{
   402  		"api-version": APIVersion,
   403  	}
   404  
   405  	preparer := autorest.CreatePreparer(
   406  		autorest.AsDelete(),
   407  		autorest.WithBaseURL(client.BaseURI),
   408  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}", pathParameters),
   409  		autorest.WithQueryParameters(queryParameters))
   410  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   411  }
   412  
   413  // DeleteCassandraKeyspaceSender sends the DeleteCassandraKeyspace request. The method will close the
   414  // http.Response Body if it receives an error.
   415  func (client CassandraResourcesClient) DeleteCassandraKeyspaceSender(req *http.Request) (future CassandraResourcesDeleteCassandraKeyspaceFuture, err error) {
   416  	var resp *http.Response
   417  	future.FutureAPI = &azure.Future{}
   418  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
   419  	if err != nil {
   420  		return
   421  	}
   422  	var azf azure.Future
   423  	azf, err = azure.NewFutureFromResponse(resp)
   424  	future.FutureAPI = &azf
   425  	future.Result = future.result
   426  	return
   427  }
   428  
   429  // DeleteCassandraKeyspaceResponder handles the response to the DeleteCassandraKeyspace request. The method always
   430  // closes the http.Response Body.
   431  func (client CassandraResourcesClient) DeleteCassandraKeyspaceResponder(resp *http.Response) (result autorest.Response, err error) {
   432  	err = autorest.Respond(
   433  		resp,
   434  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
   435  		autorest.ByClosing())
   436  	result.Response = resp
   437  	return
   438  }
   439  
   440  // DeleteCassandraTable deletes an existing Azure Cosmos DB Cassandra table.
   441  // Parameters:
   442  // resourceGroupName - the name of the resource group. The name is case insensitive.
   443  // accountName - cosmos DB database account name.
   444  // keyspaceName - cosmos DB keyspace name.
   445  // tableName - cosmos DB table name.
   446  func (client CassandraResourcesClient) DeleteCassandraTable(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (result CassandraResourcesDeleteCassandraTableFuture, err error) {
   447  	if tracing.IsEnabled() {
   448  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.DeleteCassandraTable")
   449  		defer func() {
   450  			sc := -1
   451  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
   452  				sc = result.FutureAPI.Response().StatusCode
   453  			}
   454  			tracing.EndSpan(ctx, sc, err)
   455  		}()
   456  	}
   457  	if err := validation.Validate([]validation.Validation{
   458  		{TargetValue: client.SubscriptionID,
   459  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   460  		{TargetValue: resourceGroupName,
   461  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   462  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   463  		{TargetValue: accountName,
   464  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
   465  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
   466  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
   467  		return result, validation.NewError("documentdb.CassandraResourcesClient", "DeleteCassandraTable", err.Error())
   468  	}
   469  
   470  	req, err := client.DeleteCassandraTablePreparer(ctx, resourceGroupName, accountName, keyspaceName, tableName)
   471  	if err != nil {
   472  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "DeleteCassandraTable", nil, "Failure preparing request")
   473  		return
   474  	}
   475  
   476  	result, err = client.DeleteCassandraTableSender(req)
   477  	if err != nil {
   478  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "DeleteCassandraTable", result.Response(), "Failure sending request")
   479  		return
   480  	}
   481  
   482  	return
   483  }
   484  
   485  // DeleteCassandraTablePreparer prepares the DeleteCassandraTable request.
   486  func (client CassandraResourcesClient) DeleteCassandraTablePreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (*http.Request, error) {
   487  	pathParameters := map[string]interface{}{
   488  		"accountName":       autorest.Encode("path", accountName),
   489  		"keyspaceName":      autorest.Encode("path", keyspaceName),
   490  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   491  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   492  		"tableName":         autorest.Encode("path", tableName),
   493  	}
   494  
   495  	const APIVersion = "2021-11-15-preview"
   496  	queryParameters := map[string]interface{}{
   497  		"api-version": APIVersion,
   498  	}
   499  
   500  	preparer := autorest.CreatePreparer(
   501  		autorest.AsDelete(),
   502  		autorest.WithBaseURL(client.BaseURI),
   503  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/tables/{tableName}", pathParameters),
   504  		autorest.WithQueryParameters(queryParameters))
   505  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   506  }
   507  
   508  // DeleteCassandraTableSender sends the DeleteCassandraTable request. The method will close the
   509  // http.Response Body if it receives an error.
   510  func (client CassandraResourcesClient) DeleteCassandraTableSender(req *http.Request) (future CassandraResourcesDeleteCassandraTableFuture, err error) {
   511  	var resp *http.Response
   512  	future.FutureAPI = &azure.Future{}
   513  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
   514  	if err != nil {
   515  		return
   516  	}
   517  	var azf azure.Future
   518  	azf, err = azure.NewFutureFromResponse(resp)
   519  	future.FutureAPI = &azf
   520  	future.Result = future.result
   521  	return
   522  }
   523  
   524  // DeleteCassandraTableResponder handles the response to the DeleteCassandraTable request. The method always
   525  // closes the http.Response Body.
   526  func (client CassandraResourcesClient) DeleteCassandraTableResponder(resp *http.Response) (result autorest.Response, err error) {
   527  	err = autorest.Respond(
   528  		resp,
   529  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
   530  		autorest.ByClosing())
   531  	result.Response = resp
   532  	return
   533  }
   534  
   535  // DeleteCassandraView deletes an existing Azure Cosmos DB Cassandra view.
   536  // Parameters:
   537  // resourceGroupName - the name of the resource group. The name is case insensitive.
   538  // accountName - cosmos DB database account name.
   539  // keyspaceName - cosmos DB keyspace name.
   540  // viewName - cosmos DB view name.
   541  func (client CassandraResourcesClient) DeleteCassandraView(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (result CassandraResourcesDeleteCassandraViewFuture, err error) {
   542  	if tracing.IsEnabled() {
   543  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.DeleteCassandraView")
   544  		defer func() {
   545  			sc := -1
   546  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
   547  				sc = result.FutureAPI.Response().StatusCode
   548  			}
   549  			tracing.EndSpan(ctx, sc, err)
   550  		}()
   551  	}
   552  	if err := validation.Validate([]validation.Validation{
   553  		{TargetValue: client.SubscriptionID,
   554  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   555  		{TargetValue: resourceGroupName,
   556  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   557  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   558  		{TargetValue: accountName,
   559  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
   560  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
   561  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
   562  		return result, validation.NewError("documentdb.CassandraResourcesClient", "DeleteCassandraView", err.Error())
   563  	}
   564  
   565  	req, err := client.DeleteCassandraViewPreparer(ctx, resourceGroupName, accountName, keyspaceName, viewName)
   566  	if err != nil {
   567  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "DeleteCassandraView", nil, "Failure preparing request")
   568  		return
   569  	}
   570  
   571  	result, err = client.DeleteCassandraViewSender(req)
   572  	if err != nil {
   573  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "DeleteCassandraView", result.Response(), "Failure sending request")
   574  		return
   575  	}
   576  
   577  	return
   578  }
   579  
   580  // DeleteCassandraViewPreparer prepares the DeleteCassandraView request.
   581  func (client CassandraResourcesClient) DeleteCassandraViewPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (*http.Request, error) {
   582  	pathParameters := map[string]interface{}{
   583  		"accountName":       autorest.Encode("path", accountName),
   584  		"keyspaceName":      autorest.Encode("path", keyspaceName),
   585  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   586  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   587  		"viewName":          autorest.Encode("path", viewName),
   588  	}
   589  
   590  	const APIVersion = "2021-11-15-preview"
   591  	queryParameters := map[string]interface{}{
   592  		"api-version": APIVersion,
   593  	}
   594  
   595  	preparer := autorest.CreatePreparer(
   596  		autorest.AsDelete(),
   597  		autorest.WithBaseURL(client.BaseURI),
   598  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}", pathParameters),
   599  		autorest.WithQueryParameters(queryParameters))
   600  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   601  }
   602  
   603  // DeleteCassandraViewSender sends the DeleteCassandraView request. The method will close the
   604  // http.Response Body if it receives an error.
   605  func (client CassandraResourcesClient) DeleteCassandraViewSender(req *http.Request) (future CassandraResourcesDeleteCassandraViewFuture, err error) {
   606  	var resp *http.Response
   607  	future.FutureAPI = &azure.Future{}
   608  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
   609  	if err != nil {
   610  		return
   611  	}
   612  	var azf azure.Future
   613  	azf, err = azure.NewFutureFromResponse(resp)
   614  	future.FutureAPI = &azf
   615  	future.Result = future.result
   616  	return
   617  }
   618  
   619  // DeleteCassandraViewResponder handles the response to the DeleteCassandraView request. The method always
   620  // closes the http.Response Body.
   621  func (client CassandraResourcesClient) DeleteCassandraViewResponder(resp *http.Response) (result autorest.Response, err error) {
   622  	err = autorest.Respond(
   623  		resp,
   624  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
   625  		autorest.ByClosing())
   626  	result.Response = resp
   627  	return
   628  }
   629  
   630  // GetCassandraKeyspace gets the Cassandra keyspaces under an existing Azure Cosmos DB database account with the
   631  // provided name.
   632  // Parameters:
   633  // resourceGroupName - the name of the resource group. The name is case insensitive.
   634  // accountName - cosmos DB database account name.
   635  // keyspaceName - cosmos DB keyspace name.
   636  func (client CassandraResourcesClient) GetCassandraKeyspace(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (result CassandraKeyspaceGetResults, err error) {
   637  	if tracing.IsEnabled() {
   638  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.GetCassandraKeyspace")
   639  		defer func() {
   640  			sc := -1
   641  			if result.Response.Response != nil {
   642  				sc = result.Response.Response.StatusCode
   643  			}
   644  			tracing.EndSpan(ctx, sc, err)
   645  		}()
   646  	}
   647  	if err := validation.Validate([]validation.Validation{
   648  		{TargetValue: client.SubscriptionID,
   649  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   650  		{TargetValue: resourceGroupName,
   651  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   652  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   653  		{TargetValue: accountName,
   654  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
   655  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
   656  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
   657  		return result, validation.NewError("documentdb.CassandraResourcesClient", "GetCassandraKeyspace", err.Error())
   658  	}
   659  
   660  	req, err := client.GetCassandraKeyspacePreparer(ctx, resourceGroupName, accountName, keyspaceName)
   661  	if err != nil {
   662  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraKeyspace", nil, "Failure preparing request")
   663  		return
   664  	}
   665  
   666  	resp, err := client.GetCassandraKeyspaceSender(req)
   667  	if err != nil {
   668  		result.Response = autorest.Response{Response: resp}
   669  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraKeyspace", resp, "Failure sending request")
   670  		return
   671  	}
   672  
   673  	result, err = client.GetCassandraKeyspaceResponder(resp)
   674  	if err != nil {
   675  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraKeyspace", resp, "Failure responding to request")
   676  		return
   677  	}
   678  
   679  	return
   680  }
   681  
   682  // GetCassandraKeyspacePreparer prepares the GetCassandraKeyspace request.
   683  func (client CassandraResourcesClient) GetCassandraKeyspacePreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (*http.Request, error) {
   684  	pathParameters := map[string]interface{}{
   685  		"accountName":       autorest.Encode("path", accountName),
   686  		"keyspaceName":      autorest.Encode("path", keyspaceName),
   687  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   688  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   689  	}
   690  
   691  	const APIVersion = "2021-11-15-preview"
   692  	queryParameters := map[string]interface{}{
   693  		"api-version": APIVersion,
   694  	}
   695  
   696  	preparer := autorest.CreatePreparer(
   697  		autorest.AsGet(),
   698  		autorest.WithBaseURL(client.BaseURI),
   699  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}", pathParameters),
   700  		autorest.WithQueryParameters(queryParameters))
   701  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   702  }
   703  
   704  // GetCassandraKeyspaceSender sends the GetCassandraKeyspace request. The method will close the
   705  // http.Response Body if it receives an error.
   706  func (client CassandraResourcesClient) GetCassandraKeyspaceSender(req *http.Request) (*http.Response, error) {
   707  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
   708  }
   709  
   710  // GetCassandraKeyspaceResponder handles the response to the GetCassandraKeyspace request. The method always
   711  // closes the http.Response Body.
   712  func (client CassandraResourcesClient) GetCassandraKeyspaceResponder(resp *http.Response) (result CassandraKeyspaceGetResults, err error) {
   713  	err = autorest.Respond(
   714  		resp,
   715  		azure.WithErrorUnlessStatusCode(http.StatusOK),
   716  		autorest.ByUnmarshallingJSON(&result),
   717  		autorest.ByClosing())
   718  	result.Response = autorest.Response{Response: resp}
   719  	return
   720  }
   721  
   722  // GetCassandraKeyspaceThroughput gets the RUs per second of the Cassandra Keyspace under an existing Azure Cosmos DB
   723  // database account with the provided name.
   724  // Parameters:
   725  // resourceGroupName - the name of the resource group. The name is case insensitive.
   726  // accountName - cosmos DB database account name.
   727  // keyspaceName - cosmos DB keyspace name.
   728  func (client CassandraResourcesClient) GetCassandraKeyspaceThroughput(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (result ThroughputSettingsGetResults, err error) {
   729  	if tracing.IsEnabled() {
   730  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.GetCassandraKeyspaceThroughput")
   731  		defer func() {
   732  			sc := -1
   733  			if result.Response.Response != nil {
   734  				sc = result.Response.Response.StatusCode
   735  			}
   736  			tracing.EndSpan(ctx, sc, err)
   737  		}()
   738  	}
   739  	if err := validation.Validate([]validation.Validation{
   740  		{TargetValue: client.SubscriptionID,
   741  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   742  		{TargetValue: resourceGroupName,
   743  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   744  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   745  		{TargetValue: accountName,
   746  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
   747  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
   748  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
   749  		return result, validation.NewError("documentdb.CassandraResourcesClient", "GetCassandraKeyspaceThroughput", err.Error())
   750  	}
   751  
   752  	req, err := client.GetCassandraKeyspaceThroughputPreparer(ctx, resourceGroupName, accountName, keyspaceName)
   753  	if err != nil {
   754  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraKeyspaceThroughput", nil, "Failure preparing request")
   755  		return
   756  	}
   757  
   758  	resp, err := client.GetCassandraKeyspaceThroughputSender(req)
   759  	if err != nil {
   760  		result.Response = autorest.Response{Response: resp}
   761  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraKeyspaceThroughput", resp, "Failure sending request")
   762  		return
   763  	}
   764  
   765  	result, err = client.GetCassandraKeyspaceThroughputResponder(resp)
   766  	if err != nil {
   767  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraKeyspaceThroughput", resp, "Failure responding to request")
   768  		return
   769  	}
   770  
   771  	return
   772  }
   773  
   774  // GetCassandraKeyspaceThroughputPreparer prepares the GetCassandraKeyspaceThroughput request.
   775  func (client CassandraResourcesClient) GetCassandraKeyspaceThroughputPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (*http.Request, error) {
   776  	pathParameters := map[string]interface{}{
   777  		"accountName":       autorest.Encode("path", accountName),
   778  		"keyspaceName":      autorest.Encode("path", keyspaceName),
   779  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   780  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   781  	}
   782  
   783  	const APIVersion = "2021-11-15-preview"
   784  	queryParameters := map[string]interface{}{
   785  		"api-version": APIVersion,
   786  	}
   787  
   788  	preparer := autorest.CreatePreparer(
   789  		autorest.AsGet(),
   790  		autorest.WithBaseURL(client.BaseURI),
   791  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/throughputSettings/default", pathParameters),
   792  		autorest.WithQueryParameters(queryParameters))
   793  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   794  }
   795  
   796  // GetCassandraKeyspaceThroughputSender sends the GetCassandraKeyspaceThroughput request. The method will close the
   797  // http.Response Body if it receives an error.
   798  func (client CassandraResourcesClient) GetCassandraKeyspaceThroughputSender(req *http.Request) (*http.Response, error) {
   799  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
   800  }
   801  
   802  // GetCassandraKeyspaceThroughputResponder handles the response to the GetCassandraKeyspaceThroughput request. The method always
   803  // closes the http.Response Body.
   804  func (client CassandraResourcesClient) GetCassandraKeyspaceThroughputResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
   805  	err = autorest.Respond(
   806  		resp,
   807  		azure.WithErrorUnlessStatusCode(http.StatusOK),
   808  		autorest.ByUnmarshallingJSON(&result),
   809  		autorest.ByClosing())
   810  	result.Response = autorest.Response{Response: resp}
   811  	return
   812  }
   813  
   814  // GetCassandraTable gets the Cassandra table under an existing Azure Cosmos DB database account.
   815  // Parameters:
   816  // resourceGroupName - the name of the resource group. The name is case insensitive.
   817  // accountName - cosmos DB database account name.
   818  // keyspaceName - cosmos DB keyspace name.
   819  // tableName - cosmos DB table name.
   820  func (client CassandraResourcesClient) GetCassandraTable(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (result CassandraTableGetResults, err error) {
   821  	if tracing.IsEnabled() {
   822  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.GetCassandraTable")
   823  		defer func() {
   824  			sc := -1
   825  			if result.Response.Response != nil {
   826  				sc = result.Response.Response.StatusCode
   827  			}
   828  			tracing.EndSpan(ctx, sc, err)
   829  		}()
   830  	}
   831  	if err := validation.Validate([]validation.Validation{
   832  		{TargetValue: client.SubscriptionID,
   833  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   834  		{TargetValue: resourceGroupName,
   835  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   836  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   837  		{TargetValue: accountName,
   838  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
   839  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
   840  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
   841  		return result, validation.NewError("documentdb.CassandraResourcesClient", "GetCassandraTable", err.Error())
   842  	}
   843  
   844  	req, err := client.GetCassandraTablePreparer(ctx, resourceGroupName, accountName, keyspaceName, tableName)
   845  	if err != nil {
   846  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraTable", nil, "Failure preparing request")
   847  		return
   848  	}
   849  
   850  	resp, err := client.GetCassandraTableSender(req)
   851  	if err != nil {
   852  		result.Response = autorest.Response{Response: resp}
   853  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraTable", resp, "Failure sending request")
   854  		return
   855  	}
   856  
   857  	result, err = client.GetCassandraTableResponder(resp)
   858  	if err != nil {
   859  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraTable", resp, "Failure responding to request")
   860  		return
   861  	}
   862  
   863  	return
   864  }
   865  
   866  // GetCassandraTablePreparer prepares the GetCassandraTable request.
   867  func (client CassandraResourcesClient) GetCassandraTablePreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (*http.Request, error) {
   868  	pathParameters := map[string]interface{}{
   869  		"accountName":       autorest.Encode("path", accountName),
   870  		"keyspaceName":      autorest.Encode("path", keyspaceName),
   871  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   872  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   873  		"tableName":         autorest.Encode("path", tableName),
   874  	}
   875  
   876  	const APIVersion = "2021-11-15-preview"
   877  	queryParameters := map[string]interface{}{
   878  		"api-version": APIVersion,
   879  	}
   880  
   881  	preparer := autorest.CreatePreparer(
   882  		autorest.AsGet(),
   883  		autorest.WithBaseURL(client.BaseURI),
   884  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/tables/{tableName}", pathParameters),
   885  		autorest.WithQueryParameters(queryParameters))
   886  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   887  }
   888  
   889  // GetCassandraTableSender sends the GetCassandraTable request. The method will close the
   890  // http.Response Body if it receives an error.
   891  func (client CassandraResourcesClient) GetCassandraTableSender(req *http.Request) (*http.Response, error) {
   892  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
   893  }
   894  
   895  // GetCassandraTableResponder handles the response to the GetCassandraTable request. The method always
   896  // closes the http.Response Body.
   897  func (client CassandraResourcesClient) GetCassandraTableResponder(resp *http.Response) (result CassandraTableGetResults, err error) {
   898  	err = autorest.Respond(
   899  		resp,
   900  		azure.WithErrorUnlessStatusCode(http.StatusOK),
   901  		autorest.ByUnmarshallingJSON(&result),
   902  		autorest.ByClosing())
   903  	result.Response = autorest.Response{Response: resp}
   904  	return
   905  }
   906  
   907  // GetCassandraTableThroughput gets the RUs per second of the Cassandra table under an existing Azure Cosmos DB
   908  // database account with the provided name.
   909  // Parameters:
   910  // resourceGroupName - the name of the resource group. The name is case insensitive.
   911  // accountName - cosmos DB database account name.
   912  // keyspaceName - cosmos DB keyspace name.
   913  // tableName - cosmos DB table name.
   914  func (client CassandraResourcesClient) GetCassandraTableThroughput(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (result ThroughputSettingsGetResults, err error) {
   915  	if tracing.IsEnabled() {
   916  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.GetCassandraTableThroughput")
   917  		defer func() {
   918  			sc := -1
   919  			if result.Response.Response != nil {
   920  				sc = result.Response.Response.StatusCode
   921  			}
   922  			tracing.EndSpan(ctx, sc, err)
   923  		}()
   924  	}
   925  	if err := validation.Validate([]validation.Validation{
   926  		{TargetValue: client.SubscriptionID,
   927  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   928  		{TargetValue: resourceGroupName,
   929  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   930  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   931  		{TargetValue: accountName,
   932  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
   933  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
   934  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
   935  		return result, validation.NewError("documentdb.CassandraResourcesClient", "GetCassandraTableThroughput", err.Error())
   936  	}
   937  
   938  	req, err := client.GetCassandraTableThroughputPreparer(ctx, resourceGroupName, accountName, keyspaceName, tableName)
   939  	if err != nil {
   940  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraTableThroughput", nil, "Failure preparing request")
   941  		return
   942  	}
   943  
   944  	resp, err := client.GetCassandraTableThroughputSender(req)
   945  	if err != nil {
   946  		result.Response = autorest.Response{Response: resp}
   947  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraTableThroughput", resp, "Failure sending request")
   948  		return
   949  	}
   950  
   951  	result, err = client.GetCassandraTableThroughputResponder(resp)
   952  	if err != nil {
   953  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraTableThroughput", resp, "Failure responding to request")
   954  		return
   955  	}
   956  
   957  	return
   958  }
   959  
   960  // GetCassandraTableThroughputPreparer prepares the GetCassandraTableThroughput request.
   961  func (client CassandraResourcesClient) GetCassandraTableThroughputPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (*http.Request, error) {
   962  	pathParameters := map[string]interface{}{
   963  		"accountName":       autorest.Encode("path", accountName),
   964  		"keyspaceName":      autorest.Encode("path", keyspaceName),
   965  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   966  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   967  		"tableName":         autorest.Encode("path", tableName),
   968  	}
   969  
   970  	const APIVersion = "2021-11-15-preview"
   971  	queryParameters := map[string]interface{}{
   972  		"api-version": APIVersion,
   973  	}
   974  
   975  	preparer := autorest.CreatePreparer(
   976  		autorest.AsGet(),
   977  		autorest.WithBaseURL(client.BaseURI),
   978  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/tables/{tableName}/throughputSettings/default", pathParameters),
   979  		autorest.WithQueryParameters(queryParameters))
   980  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   981  }
   982  
   983  // GetCassandraTableThroughputSender sends the GetCassandraTableThroughput request. The method will close the
   984  // http.Response Body if it receives an error.
   985  func (client CassandraResourcesClient) GetCassandraTableThroughputSender(req *http.Request) (*http.Response, error) {
   986  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
   987  }
   988  
   989  // GetCassandraTableThroughputResponder handles the response to the GetCassandraTableThroughput request. The method always
   990  // closes the http.Response Body.
   991  func (client CassandraResourcesClient) GetCassandraTableThroughputResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
   992  	err = autorest.Respond(
   993  		resp,
   994  		azure.WithErrorUnlessStatusCode(http.StatusOK),
   995  		autorest.ByUnmarshallingJSON(&result),
   996  		autorest.ByClosing())
   997  	result.Response = autorest.Response{Response: resp}
   998  	return
   999  }
  1000  
  1001  // GetCassandraView gets the Cassandra view under an existing Azure Cosmos DB database account.
  1002  // Parameters:
  1003  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1004  // accountName - cosmos DB database account name.
  1005  // keyspaceName - cosmos DB keyspace name.
  1006  // viewName - cosmos DB view name.
  1007  func (client CassandraResourcesClient) GetCassandraView(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (result CassandraViewGetResults, err error) {
  1008  	if tracing.IsEnabled() {
  1009  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.GetCassandraView")
  1010  		defer func() {
  1011  			sc := -1
  1012  			if result.Response.Response != nil {
  1013  				sc = result.Response.Response.StatusCode
  1014  			}
  1015  			tracing.EndSpan(ctx, sc, err)
  1016  		}()
  1017  	}
  1018  	if err := validation.Validate([]validation.Validation{
  1019  		{TargetValue: client.SubscriptionID,
  1020  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1021  		{TargetValue: resourceGroupName,
  1022  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1023  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1024  		{TargetValue: accountName,
  1025  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1026  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1027  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1028  		return result, validation.NewError("documentdb.CassandraResourcesClient", "GetCassandraView", err.Error())
  1029  	}
  1030  
  1031  	req, err := client.GetCassandraViewPreparer(ctx, resourceGroupName, accountName, keyspaceName, viewName)
  1032  	if err != nil {
  1033  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraView", nil, "Failure preparing request")
  1034  		return
  1035  	}
  1036  
  1037  	resp, err := client.GetCassandraViewSender(req)
  1038  	if err != nil {
  1039  		result.Response = autorest.Response{Response: resp}
  1040  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraView", resp, "Failure sending request")
  1041  		return
  1042  	}
  1043  
  1044  	result, err = client.GetCassandraViewResponder(resp)
  1045  	if err != nil {
  1046  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraView", resp, "Failure responding to request")
  1047  		return
  1048  	}
  1049  
  1050  	return
  1051  }
  1052  
  1053  // GetCassandraViewPreparer prepares the GetCassandraView request.
  1054  func (client CassandraResourcesClient) GetCassandraViewPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (*http.Request, error) {
  1055  	pathParameters := map[string]interface{}{
  1056  		"accountName":       autorest.Encode("path", accountName),
  1057  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1058  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1059  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1060  		"viewName":          autorest.Encode("path", viewName),
  1061  	}
  1062  
  1063  	const APIVersion = "2021-11-15-preview"
  1064  	queryParameters := map[string]interface{}{
  1065  		"api-version": APIVersion,
  1066  	}
  1067  
  1068  	preparer := autorest.CreatePreparer(
  1069  		autorest.AsGet(),
  1070  		autorest.WithBaseURL(client.BaseURI),
  1071  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}", pathParameters),
  1072  		autorest.WithQueryParameters(queryParameters))
  1073  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1074  }
  1075  
  1076  // GetCassandraViewSender sends the GetCassandraView request. The method will close the
  1077  // http.Response Body if it receives an error.
  1078  func (client CassandraResourcesClient) GetCassandraViewSender(req *http.Request) (*http.Response, error) {
  1079  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1080  }
  1081  
  1082  // GetCassandraViewResponder handles the response to the GetCassandraView request. The method always
  1083  // closes the http.Response Body.
  1084  func (client CassandraResourcesClient) GetCassandraViewResponder(resp *http.Response) (result CassandraViewGetResults, err error) {
  1085  	err = autorest.Respond(
  1086  		resp,
  1087  		azure.WithErrorUnlessStatusCode(http.StatusOK),
  1088  		autorest.ByUnmarshallingJSON(&result),
  1089  		autorest.ByClosing())
  1090  	result.Response = autorest.Response{Response: resp}
  1091  	return
  1092  }
  1093  
  1094  // GetCassandraViewThroughput gets the RUs per second of the Cassandra view under an existing Azure Cosmos DB database
  1095  // account with the provided name.
  1096  // Parameters:
  1097  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1098  // accountName - cosmos DB database account name.
  1099  // keyspaceName - cosmos DB keyspace name.
  1100  // viewName - cosmos DB view name.
  1101  func (client CassandraResourcesClient) GetCassandraViewThroughput(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (result ThroughputSettingsGetResults, err error) {
  1102  	if tracing.IsEnabled() {
  1103  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.GetCassandraViewThroughput")
  1104  		defer func() {
  1105  			sc := -1
  1106  			if result.Response.Response != nil {
  1107  				sc = result.Response.Response.StatusCode
  1108  			}
  1109  			tracing.EndSpan(ctx, sc, err)
  1110  		}()
  1111  	}
  1112  	if err := validation.Validate([]validation.Validation{
  1113  		{TargetValue: client.SubscriptionID,
  1114  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1115  		{TargetValue: resourceGroupName,
  1116  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1117  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1118  		{TargetValue: accountName,
  1119  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1120  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1121  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1122  		return result, validation.NewError("documentdb.CassandraResourcesClient", "GetCassandraViewThroughput", err.Error())
  1123  	}
  1124  
  1125  	req, err := client.GetCassandraViewThroughputPreparer(ctx, resourceGroupName, accountName, keyspaceName, viewName)
  1126  	if err != nil {
  1127  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraViewThroughput", nil, "Failure preparing request")
  1128  		return
  1129  	}
  1130  
  1131  	resp, err := client.GetCassandraViewThroughputSender(req)
  1132  	if err != nil {
  1133  		result.Response = autorest.Response{Response: resp}
  1134  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraViewThroughput", resp, "Failure sending request")
  1135  		return
  1136  	}
  1137  
  1138  	result, err = client.GetCassandraViewThroughputResponder(resp)
  1139  	if err != nil {
  1140  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "GetCassandraViewThroughput", resp, "Failure responding to request")
  1141  		return
  1142  	}
  1143  
  1144  	return
  1145  }
  1146  
  1147  // GetCassandraViewThroughputPreparer prepares the GetCassandraViewThroughput request.
  1148  func (client CassandraResourcesClient) GetCassandraViewThroughputPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (*http.Request, error) {
  1149  	pathParameters := map[string]interface{}{
  1150  		"accountName":       autorest.Encode("path", accountName),
  1151  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1152  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1153  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1154  		"viewName":          autorest.Encode("path", viewName),
  1155  	}
  1156  
  1157  	const APIVersion = "2021-11-15-preview"
  1158  	queryParameters := map[string]interface{}{
  1159  		"api-version": APIVersion,
  1160  	}
  1161  
  1162  	preparer := autorest.CreatePreparer(
  1163  		autorest.AsGet(),
  1164  		autorest.WithBaseURL(client.BaseURI),
  1165  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}/throughputSettings/default", pathParameters),
  1166  		autorest.WithQueryParameters(queryParameters))
  1167  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1168  }
  1169  
  1170  // GetCassandraViewThroughputSender sends the GetCassandraViewThroughput request. The method will close the
  1171  // http.Response Body if it receives an error.
  1172  func (client CassandraResourcesClient) GetCassandraViewThroughputSender(req *http.Request) (*http.Response, error) {
  1173  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1174  }
  1175  
  1176  // GetCassandraViewThroughputResponder handles the response to the GetCassandraViewThroughput request. The method always
  1177  // closes the http.Response Body.
  1178  func (client CassandraResourcesClient) GetCassandraViewThroughputResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  1179  	err = autorest.Respond(
  1180  		resp,
  1181  		azure.WithErrorUnlessStatusCode(http.StatusOK),
  1182  		autorest.ByUnmarshallingJSON(&result),
  1183  		autorest.ByClosing())
  1184  	result.Response = autorest.Response{Response: resp}
  1185  	return
  1186  }
  1187  
  1188  // ListCassandraKeyspaces lists the Cassandra keyspaces under an existing Azure Cosmos DB database account.
  1189  // Parameters:
  1190  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1191  // accountName - cosmos DB database account name.
  1192  func (client CassandraResourcesClient) ListCassandraKeyspaces(ctx context.Context, resourceGroupName string, accountName string) (result CassandraKeyspaceListResult, err error) {
  1193  	if tracing.IsEnabled() {
  1194  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.ListCassandraKeyspaces")
  1195  		defer func() {
  1196  			sc := -1
  1197  			if result.Response.Response != nil {
  1198  				sc = result.Response.Response.StatusCode
  1199  			}
  1200  			tracing.EndSpan(ctx, sc, err)
  1201  		}()
  1202  	}
  1203  	if err := validation.Validate([]validation.Validation{
  1204  		{TargetValue: client.SubscriptionID,
  1205  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1206  		{TargetValue: resourceGroupName,
  1207  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1208  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1209  		{TargetValue: accountName,
  1210  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1211  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1212  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1213  		return result, validation.NewError("documentdb.CassandraResourcesClient", "ListCassandraKeyspaces", err.Error())
  1214  	}
  1215  
  1216  	req, err := client.ListCassandraKeyspacesPreparer(ctx, resourceGroupName, accountName)
  1217  	if err != nil {
  1218  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "ListCassandraKeyspaces", nil, "Failure preparing request")
  1219  		return
  1220  	}
  1221  
  1222  	resp, err := client.ListCassandraKeyspacesSender(req)
  1223  	if err != nil {
  1224  		result.Response = autorest.Response{Response: resp}
  1225  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "ListCassandraKeyspaces", resp, "Failure sending request")
  1226  		return
  1227  	}
  1228  
  1229  	result, err = client.ListCassandraKeyspacesResponder(resp)
  1230  	if err != nil {
  1231  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "ListCassandraKeyspaces", resp, "Failure responding to request")
  1232  		return
  1233  	}
  1234  
  1235  	return
  1236  }
  1237  
  1238  // ListCassandraKeyspacesPreparer prepares the ListCassandraKeyspaces request.
  1239  func (client CassandraResourcesClient) ListCassandraKeyspacesPreparer(ctx context.Context, resourceGroupName string, accountName string) (*http.Request, error) {
  1240  	pathParameters := map[string]interface{}{
  1241  		"accountName":       autorest.Encode("path", accountName),
  1242  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1243  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1244  	}
  1245  
  1246  	const APIVersion = "2021-11-15-preview"
  1247  	queryParameters := map[string]interface{}{
  1248  		"api-version": APIVersion,
  1249  	}
  1250  
  1251  	preparer := autorest.CreatePreparer(
  1252  		autorest.AsGet(),
  1253  		autorest.WithBaseURL(client.BaseURI),
  1254  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces", pathParameters),
  1255  		autorest.WithQueryParameters(queryParameters))
  1256  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1257  }
  1258  
  1259  // ListCassandraKeyspacesSender sends the ListCassandraKeyspaces request. The method will close the
  1260  // http.Response Body if it receives an error.
  1261  func (client CassandraResourcesClient) ListCassandraKeyspacesSender(req *http.Request) (*http.Response, error) {
  1262  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1263  }
  1264  
  1265  // ListCassandraKeyspacesResponder handles the response to the ListCassandraKeyspaces request. The method always
  1266  // closes the http.Response Body.
  1267  func (client CassandraResourcesClient) ListCassandraKeyspacesResponder(resp *http.Response) (result CassandraKeyspaceListResult, err error) {
  1268  	err = autorest.Respond(
  1269  		resp,
  1270  		azure.WithErrorUnlessStatusCode(http.StatusOK),
  1271  		autorest.ByUnmarshallingJSON(&result),
  1272  		autorest.ByClosing())
  1273  	result.Response = autorest.Response{Response: resp}
  1274  	return
  1275  }
  1276  
  1277  // ListCassandraTables lists the Cassandra table under an existing Azure Cosmos DB database account.
  1278  // Parameters:
  1279  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1280  // accountName - cosmos DB database account name.
  1281  // keyspaceName - cosmos DB keyspace name.
  1282  func (client CassandraResourcesClient) ListCassandraTables(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (result CassandraTableListResult, err error) {
  1283  	if tracing.IsEnabled() {
  1284  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.ListCassandraTables")
  1285  		defer func() {
  1286  			sc := -1
  1287  			if result.Response.Response != nil {
  1288  				sc = result.Response.Response.StatusCode
  1289  			}
  1290  			tracing.EndSpan(ctx, sc, err)
  1291  		}()
  1292  	}
  1293  	if err := validation.Validate([]validation.Validation{
  1294  		{TargetValue: client.SubscriptionID,
  1295  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1296  		{TargetValue: resourceGroupName,
  1297  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1298  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1299  		{TargetValue: accountName,
  1300  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1301  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1302  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1303  		return result, validation.NewError("documentdb.CassandraResourcesClient", "ListCassandraTables", err.Error())
  1304  	}
  1305  
  1306  	req, err := client.ListCassandraTablesPreparer(ctx, resourceGroupName, accountName, keyspaceName)
  1307  	if err != nil {
  1308  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "ListCassandraTables", nil, "Failure preparing request")
  1309  		return
  1310  	}
  1311  
  1312  	resp, err := client.ListCassandraTablesSender(req)
  1313  	if err != nil {
  1314  		result.Response = autorest.Response{Response: resp}
  1315  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "ListCassandraTables", resp, "Failure sending request")
  1316  		return
  1317  	}
  1318  
  1319  	result, err = client.ListCassandraTablesResponder(resp)
  1320  	if err != nil {
  1321  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "ListCassandraTables", resp, "Failure responding to request")
  1322  		return
  1323  	}
  1324  
  1325  	return
  1326  }
  1327  
  1328  // ListCassandraTablesPreparer prepares the ListCassandraTables request.
  1329  func (client CassandraResourcesClient) ListCassandraTablesPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (*http.Request, error) {
  1330  	pathParameters := map[string]interface{}{
  1331  		"accountName":       autorest.Encode("path", accountName),
  1332  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1333  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1334  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1335  	}
  1336  
  1337  	const APIVersion = "2021-11-15-preview"
  1338  	queryParameters := map[string]interface{}{
  1339  		"api-version": APIVersion,
  1340  	}
  1341  
  1342  	preparer := autorest.CreatePreparer(
  1343  		autorest.AsGet(),
  1344  		autorest.WithBaseURL(client.BaseURI),
  1345  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/tables", pathParameters),
  1346  		autorest.WithQueryParameters(queryParameters))
  1347  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1348  }
  1349  
  1350  // ListCassandraTablesSender sends the ListCassandraTables request. The method will close the
  1351  // http.Response Body if it receives an error.
  1352  func (client CassandraResourcesClient) ListCassandraTablesSender(req *http.Request) (*http.Response, error) {
  1353  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1354  }
  1355  
  1356  // ListCassandraTablesResponder handles the response to the ListCassandraTables request. The method always
  1357  // closes the http.Response Body.
  1358  func (client CassandraResourcesClient) ListCassandraTablesResponder(resp *http.Response) (result CassandraTableListResult, err error) {
  1359  	err = autorest.Respond(
  1360  		resp,
  1361  		azure.WithErrorUnlessStatusCode(http.StatusOK),
  1362  		autorest.ByUnmarshallingJSON(&result),
  1363  		autorest.ByClosing())
  1364  	result.Response = autorest.Response{Response: resp}
  1365  	return
  1366  }
  1367  
  1368  // ListCassandraViews lists the Cassandra materialized views under an existing Azure Cosmos DB database account.
  1369  // Parameters:
  1370  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1371  // accountName - cosmos DB database account name.
  1372  // keyspaceName - cosmos DB keyspace name.
  1373  func (client CassandraResourcesClient) ListCassandraViews(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (result CassandraViewListResult, err error) {
  1374  	if tracing.IsEnabled() {
  1375  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.ListCassandraViews")
  1376  		defer func() {
  1377  			sc := -1
  1378  			if result.Response.Response != nil {
  1379  				sc = result.Response.Response.StatusCode
  1380  			}
  1381  			tracing.EndSpan(ctx, sc, err)
  1382  		}()
  1383  	}
  1384  	if err := validation.Validate([]validation.Validation{
  1385  		{TargetValue: client.SubscriptionID,
  1386  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1387  		{TargetValue: resourceGroupName,
  1388  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1389  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1390  		{TargetValue: accountName,
  1391  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1392  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1393  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1394  		return result, validation.NewError("documentdb.CassandraResourcesClient", "ListCassandraViews", err.Error())
  1395  	}
  1396  
  1397  	req, err := client.ListCassandraViewsPreparer(ctx, resourceGroupName, accountName, keyspaceName)
  1398  	if err != nil {
  1399  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "ListCassandraViews", nil, "Failure preparing request")
  1400  		return
  1401  	}
  1402  
  1403  	resp, err := client.ListCassandraViewsSender(req)
  1404  	if err != nil {
  1405  		result.Response = autorest.Response{Response: resp}
  1406  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "ListCassandraViews", resp, "Failure sending request")
  1407  		return
  1408  	}
  1409  
  1410  	result, err = client.ListCassandraViewsResponder(resp)
  1411  	if err != nil {
  1412  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "ListCassandraViews", resp, "Failure responding to request")
  1413  		return
  1414  	}
  1415  
  1416  	return
  1417  }
  1418  
  1419  // ListCassandraViewsPreparer prepares the ListCassandraViews request.
  1420  func (client CassandraResourcesClient) ListCassandraViewsPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (*http.Request, error) {
  1421  	pathParameters := map[string]interface{}{
  1422  		"accountName":       autorest.Encode("path", accountName),
  1423  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1424  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1425  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1426  	}
  1427  
  1428  	const APIVersion = "2021-11-15-preview"
  1429  	queryParameters := map[string]interface{}{
  1430  		"api-version": APIVersion,
  1431  	}
  1432  
  1433  	preparer := autorest.CreatePreparer(
  1434  		autorest.AsGet(),
  1435  		autorest.WithBaseURL(client.BaseURI),
  1436  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views", pathParameters),
  1437  		autorest.WithQueryParameters(queryParameters))
  1438  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1439  }
  1440  
  1441  // ListCassandraViewsSender sends the ListCassandraViews request. The method will close the
  1442  // http.Response Body if it receives an error.
  1443  func (client CassandraResourcesClient) ListCassandraViewsSender(req *http.Request) (*http.Response, error) {
  1444  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1445  }
  1446  
  1447  // ListCassandraViewsResponder handles the response to the ListCassandraViews request. The method always
  1448  // closes the http.Response Body.
  1449  func (client CassandraResourcesClient) ListCassandraViewsResponder(resp *http.Response) (result CassandraViewListResult, err error) {
  1450  	err = autorest.Respond(
  1451  		resp,
  1452  		azure.WithErrorUnlessStatusCode(http.StatusOK),
  1453  		autorest.ByUnmarshallingJSON(&result),
  1454  		autorest.ByClosing())
  1455  	result.Response = autorest.Response{Response: resp}
  1456  	return
  1457  }
  1458  
  1459  // MigrateCassandraKeyspaceToAutoscale migrate an Azure Cosmos DB Cassandra Keyspace from manual throughput to
  1460  // autoscale
  1461  // Parameters:
  1462  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1463  // accountName - cosmos DB database account name.
  1464  // keyspaceName - cosmos DB keyspace name.
  1465  func (client CassandraResourcesClient) MigrateCassandraKeyspaceToAutoscale(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (result CassandraResourcesMigrateCassandraKeyspaceToAutoscaleFuture, err error) {
  1466  	if tracing.IsEnabled() {
  1467  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.MigrateCassandraKeyspaceToAutoscale")
  1468  		defer func() {
  1469  			sc := -1
  1470  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
  1471  				sc = result.FutureAPI.Response().StatusCode
  1472  			}
  1473  			tracing.EndSpan(ctx, sc, err)
  1474  		}()
  1475  	}
  1476  	if err := validation.Validate([]validation.Validation{
  1477  		{TargetValue: client.SubscriptionID,
  1478  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1479  		{TargetValue: resourceGroupName,
  1480  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1481  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1482  		{TargetValue: accountName,
  1483  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1484  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1485  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1486  		return result, validation.NewError("documentdb.CassandraResourcesClient", "MigrateCassandraKeyspaceToAutoscale", err.Error())
  1487  	}
  1488  
  1489  	req, err := client.MigrateCassandraKeyspaceToAutoscalePreparer(ctx, resourceGroupName, accountName, keyspaceName)
  1490  	if err != nil {
  1491  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraKeyspaceToAutoscale", nil, "Failure preparing request")
  1492  		return
  1493  	}
  1494  
  1495  	result, err = client.MigrateCassandraKeyspaceToAutoscaleSender(req)
  1496  	if err != nil {
  1497  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraKeyspaceToAutoscale", result.Response(), "Failure sending request")
  1498  		return
  1499  	}
  1500  
  1501  	return
  1502  }
  1503  
  1504  // MigrateCassandraKeyspaceToAutoscalePreparer prepares the MigrateCassandraKeyspaceToAutoscale request.
  1505  func (client CassandraResourcesClient) MigrateCassandraKeyspaceToAutoscalePreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (*http.Request, error) {
  1506  	pathParameters := map[string]interface{}{
  1507  		"accountName":       autorest.Encode("path", accountName),
  1508  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1509  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1510  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1511  	}
  1512  
  1513  	const APIVersion = "2021-11-15-preview"
  1514  	queryParameters := map[string]interface{}{
  1515  		"api-version": APIVersion,
  1516  	}
  1517  
  1518  	preparer := autorest.CreatePreparer(
  1519  		autorest.AsPost(),
  1520  		autorest.WithBaseURL(client.BaseURI),
  1521  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/throughputSettings/default/migrateToAutoscale", pathParameters),
  1522  		autorest.WithQueryParameters(queryParameters))
  1523  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1524  }
  1525  
  1526  // MigrateCassandraKeyspaceToAutoscaleSender sends the MigrateCassandraKeyspaceToAutoscale request. The method will close the
  1527  // http.Response Body if it receives an error.
  1528  func (client CassandraResourcesClient) MigrateCassandraKeyspaceToAutoscaleSender(req *http.Request) (future CassandraResourcesMigrateCassandraKeyspaceToAutoscaleFuture, err error) {
  1529  	var resp *http.Response
  1530  	future.FutureAPI = &azure.Future{}
  1531  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1532  	if err != nil {
  1533  		return
  1534  	}
  1535  	var azf azure.Future
  1536  	azf, err = azure.NewFutureFromResponse(resp)
  1537  	future.FutureAPI = &azf
  1538  	future.Result = future.result
  1539  	return
  1540  }
  1541  
  1542  // MigrateCassandraKeyspaceToAutoscaleResponder handles the response to the MigrateCassandraKeyspaceToAutoscale request. The method always
  1543  // closes the http.Response Body.
  1544  func (client CassandraResourcesClient) MigrateCassandraKeyspaceToAutoscaleResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  1545  	err = autorest.Respond(
  1546  		resp,
  1547  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
  1548  		autorest.ByUnmarshallingJSON(&result),
  1549  		autorest.ByClosing())
  1550  	result.Response = autorest.Response{Response: resp}
  1551  	return
  1552  }
  1553  
  1554  // MigrateCassandraKeyspaceToManualThroughput migrate an Azure Cosmos DB Cassandra Keyspace from autoscale to manual
  1555  // throughput
  1556  // Parameters:
  1557  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1558  // accountName - cosmos DB database account name.
  1559  // keyspaceName - cosmos DB keyspace name.
  1560  func (client CassandraResourcesClient) MigrateCassandraKeyspaceToManualThroughput(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (result CassandraResourcesMigrateCassandraKeyspaceToManualThroughputFuture, err error) {
  1561  	if tracing.IsEnabled() {
  1562  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.MigrateCassandraKeyspaceToManualThroughput")
  1563  		defer func() {
  1564  			sc := -1
  1565  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
  1566  				sc = result.FutureAPI.Response().StatusCode
  1567  			}
  1568  			tracing.EndSpan(ctx, sc, err)
  1569  		}()
  1570  	}
  1571  	if err := validation.Validate([]validation.Validation{
  1572  		{TargetValue: client.SubscriptionID,
  1573  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1574  		{TargetValue: resourceGroupName,
  1575  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1576  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1577  		{TargetValue: accountName,
  1578  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1579  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1580  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1581  		return result, validation.NewError("documentdb.CassandraResourcesClient", "MigrateCassandraKeyspaceToManualThroughput", err.Error())
  1582  	}
  1583  
  1584  	req, err := client.MigrateCassandraKeyspaceToManualThroughputPreparer(ctx, resourceGroupName, accountName, keyspaceName)
  1585  	if err != nil {
  1586  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraKeyspaceToManualThroughput", nil, "Failure preparing request")
  1587  		return
  1588  	}
  1589  
  1590  	result, err = client.MigrateCassandraKeyspaceToManualThroughputSender(req)
  1591  	if err != nil {
  1592  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraKeyspaceToManualThroughput", result.Response(), "Failure sending request")
  1593  		return
  1594  	}
  1595  
  1596  	return
  1597  }
  1598  
  1599  // MigrateCassandraKeyspaceToManualThroughputPreparer prepares the MigrateCassandraKeyspaceToManualThroughput request.
  1600  func (client CassandraResourcesClient) MigrateCassandraKeyspaceToManualThroughputPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string) (*http.Request, error) {
  1601  	pathParameters := map[string]interface{}{
  1602  		"accountName":       autorest.Encode("path", accountName),
  1603  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1604  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1605  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1606  	}
  1607  
  1608  	const APIVersion = "2021-11-15-preview"
  1609  	queryParameters := map[string]interface{}{
  1610  		"api-version": APIVersion,
  1611  	}
  1612  
  1613  	preparer := autorest.CreatePreparer(
  1614  		autorest.AsPost(),
  1615  		autorest.WithBaseURL(client.BaseURI),
  1616  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/throughputSettings/default/migrateToManualThroughput", pathParameters),
  1617  		autorest.WithQueryParameters(queryParameters))
  1618  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1619  }
  1620  
  1621  // MigrateCassandraKeyspaceToManualThroughputSender sends the MigrateCassandraKeyspaceToManualThroughput request. The method will close the
  1622  // http.Response Body if it receives an error.
  1623  func (client CassandraResourcesClient) MigrateCassandraKeyspaceToManualThroughputSender(req *http.Request) (future CassandraResourcesMigrateCassandraKeyspaceToManualThroughputFuture, err error) {
  1624  	var resp *http.Response
  1625  	future.FutureAPI = &azure.Future{}
  1626  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1627  	if err != nil {
  1628  		return
  1629  	}
  1630  	var azf azure.Future
  1631  	azf, err = azure.NewFutureFromResponse(resp)
  1632  	future.FutureAPI = &azf
  1633  	future.Result = future.result
  1634  	return
  1635  }
  1636  
  1637  // MigrateCassandraKeyspaceToManualThroughputResponder handles the response to the MigrateCassandraKeyspaceToManualThroughput request. The method always
  1638  // closes the http.Response Body.
  1639  func (client CassandraResourcesClient) MigrateCassandraKeyspaceToManualThroughputResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  1640  	err = autorest.Respond(
  1641  		resp,
  1642  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
  1643  		autorest.ByUnmarshallingJSON(&result),
  1644  		autorest.ByClosing())
  1645  	result.Response = autorest.Response{Response: resp}
  1646  	return
  1647  }
  1648  
  1649  // MigrateCassandraTableToAutoscale migrate an Azure Cosmos DB Cassandra table from manual throughput to autoscale
  1650  // Parameters:
  1651  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1652  // accountName - cosmos DB database account name.
  1653  // keyspaceName - cosmos DB keyspace name.
  1654  // tableName - cosmos DB table name.
  1655  func (client CassandraResourcesClient) MigrateCassandraTableToAutoscale(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (result CassandraResourcesMigrateCassandraTableToAutoscaleFuture, err error) {
  1656  	if tracing.IsEnabled() {
  1657  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.MigrateCassandraTableToAutoscale")
  1658  		defer func() {
  1659  			sc := -1
  1660  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
  1661  				sc = result.FutureAPI.Response().StatusCode
  1662  			}
  1663  			tracing.EndSpan(ctx, sc, err)
  1664  		}()
  1665  	}
  1666  	if err := validation.Validate([]validation.Validation{
  1667  		{TargetValue: client.SubscriptionID,
  1668  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1669  		{TargetValue: resourceGroupName,
  1670  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1671  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1672  		{TargetValue: accountName,
  1673  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1674  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1675  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1676  		return result, validation.NewError("documentdb.CassandraResourcesClient", "MigrateCassandraTableToAutoscale", err.Error())
  1677  	}
  1678  
  1679  	req, err := client.MigrateCassandraTableToAutoscalePreparer(ctx, resourceGroupName, accountName, keyspaceName, tableName)
  1680  	if err != nil {
  1681  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraTableToAutoscale", nil, "Failure preparing request")
  1682  		return
  1683  	}
  1684  
  1685  	result, err = client.MigrateCassandraTableToAutoscaleSender(req)
  1686  	if err != nil {
  1687  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraTableToAutoscale", result.Response(), "Failure sending request")
  1688  		return
  1689  	}
  1690  
  1691  	return
  1692  }
  1693  
  1694  // MigrateCassandraTableToAutoscalePreparer prepares the MigrateCassandraTableToAutoscale request.
  1695  func (client CassandraResourcesClient) MigrateCassandraTableToAutoscalePreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (*http.Request, error) {
  1696  	pathParameters := map[string]interface{}{
  1697  		"accountName":       autorest.Encode("path", accountName),
  1698  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1699  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1700  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1701  		"tableName":         autorest.Encode("path", tableName),
  1702  	}
  1703  
  1704  	const APIVersion = "2021-11-15-preview"
  1705  	queryParameters := map[string]interface{}{
  1706  		"api-version": APIVersion,
  1707  	}
  1708  
  1709  	preparer := autorest.CreatePreparer(
  1710  		autorest.AsPost(),
  1711  		autorest.WithBaseURL(client.BaseURI),
  1712  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/tables/{tableName}/throughputSettings/default/migrateToAutoscale", pathParameters),
  1713  		autorest.WithQueryParameters(queryParameters))
  1714  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1715  }
  1716  
  1717  // MigrateCassandraTableToAutoscaleSender sends the MigrateCassandraTableToAutoscale request. The method will close the
  1718  // http.Response Body if it receives an error.
  1719  func (client CassandraResourcesClient) MigrateCassandraTableToAutoscaleSender(req *http.Request) (future CassandraResourcesMigrateCassandraTableToAutoscaleFuture, err error) {
  1720  	var resp *http.Response
  1721  	future.FutureAPI = &azure.Future{}
  1722  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1723  	if err != nil {
  1724  		return
  1725  	}
  1726  	var azf azure.Future
  1727  	azf, err = azure.NewFutureFromResponse(resp)
  1728  	future.FutureAPI = &azf
  1729  	future.Result = future.result
  1730  	return
  1731  }
  1732  
  1733  // MigrateCassandraTableToAutoscaleResponder handles the response to the MigrateCassandraTableToAutoscale request. The method always
  1734  // closes the http.Response Body.
  1735  func (client CassandraResourcesClient) MigrateCassandraTableToAutoscaleResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  1736  	err = autorest.Respond(
  1737  		resp,
  1738  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
  1739  		autorest.ByUnmarshallingJSON(&result),
  1740  		autorest.ByClosing())
  1741  	result.Response = autorest.Response{Response: resp}
  1742  	return
  1743  }
  1744  
  1745  // MigrateCassandraTableToManualThroughput migrate an Azure Cosmos DB Cassandra table from autoscale to manual
  1746  // throughput
  1747  // Parameters:
  1748  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1749  // accountName - cosmos DB database account name.
  1750  // keyspaceName - cosmos DB keyspace name.
  1751  // tableName - cosmos DB table name.
  1752  func (client CassandraResourcesClient) MigrateCassandraTableToManualThroughput(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (result CassandraResourcesMigrateCassandraTableToManualThroughputFuture, err error) {
  1753  	if tracing.IsEnabled() {
  1754  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.MigrateCassandraTableToManualThroughput")
  1755  		defer func() {
  1756  			sc := -1
  1757  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
  1758  				sc = result.FutureAPI.Response().StatusCode
  1759  			}
  1760  			tracing.EndSpan(ctx, sc, err)
  1761  		}()
  1762  	}
  1763  	if err := validation.Validate([]validation.Validation{
  1764  		{TargetValue: client.SubscriptionID,
  1765  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1766  		{TargetValue: resourceGroupName,
  1767  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1768  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1769  		{TargetValue: accountName,
  1770  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1771  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1772  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1773  		return result, validation.NewError("documentdb.CassandraResourcesClient", "MigrateCassandraTableToManualThroughput", err.Error())
  1774  	}
  1775  
  1776  	req, err := client.MigrateCassandraTableToManualThroughputPreparer(ctx, resourceGroupName, accountName, keyspaceName, tableName)
  1777  	if err != nil {
  1778  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraTableToManualThroughput", nil, "Failure preparing request")
  1779  		return
  1780  	}
  1781  
  1782  	result, err = client.MigrateCassandraTableToManualThroughputSender(req)
  1783  	if err != nil {
  1784  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraTableToManualThroughput", result.Response(), "Failure sending request")
  1785  		return
  1786  	}
  1787  
  1788  	return
  1789  }
  1790  
  1791  // MigrateCassandraTableToManualThroughputPreparer prepares the MigrateCassandraTableToManualThroughput request.
  1792  func (client CassandraResourcesClient) MigrateCassandraTableToManualThroughputPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string) (*http.Request, error) {
  1793  	pathParameters := map[string]interface{}{
  1794  		"accountName":       autorest.Encode("path", accountName),
  1795  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1796  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1797  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1798  		"tableName":         autorest.Encode("path", tableName),
  1799  	}
  1800  
  1801  	const APIVersion = "2021-11-15-preview"
  1802  	queryParameters := map[string]interface{}{
  1803  		"api-version": APIVersion,
  1804  	}
  1805  
  1806  	preparer := autorest.CreatePreparer(
  1807  		autorest.AsPost(),
  1808  		autorest.WithBaseURL(client.BaseURI),
  1809  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/tables/{tableName}/throughputSettings/default/migrateToManualThroughput", pathParameters),
  1810  		autorest.WithQueryParameters(queryParameters))
  1811  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1812  }
  1813  
  1814  // MigrateCassandraTableToManualThroughputSender sends the MigrateCassandraTableToManualThroughput request. The method will close the
  1815  // http.Response Body if it receives an error.
  1816  func (client CassandraResourcesClient) MigrateCassandraTableToManualThroughputSender(req *http.Request) (future CassandraResourcesMigrateCassandraTableToManualThroughputFuture, err error) {
  1817  	var resp *http.Response
  1818  	future.FutureAPI = &azure.Future{}
  1819  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1820  	if err != nil {
  1821  		return
  1822  	}
  1823  	var azf azure.Future
  1824  	azf, err = azure.NewFutureFromResponse(resp)
  1825  	future.FutureAPI = &azf
  1826  	future.Result = future.result
  1827  	return
  1828  }
  1829  
  1830  // MigrateCassandraTableToManualThroughputResponder handles the response to the MigrateCassandraTableToManualThroughput request. The method always
  1831  // closes the http.Response Body.
  1832  func (client CassandraResourcesClient) MigrateCassandraTableToManualThroughputResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  1833  	err = autorest.Respond(
  1834  		resp,
  1835  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
  1836  		autorest.ByUnmarshallingJSON(&result),
  1837  		autorest.ByClosing())
  1838  	result.Response = autorest.Response{Response: resp}
  1839  	return
  1840  }
  1841  
  1842  // MigrateCassandraViewToAutoscale migrate an Azure Cosmos DB Cassandra view from manual throughput to autoscale
  1843  // Parameters:
  1844  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1845  // accountName - cosmos DB database account name.
  1846  // keyspaceName - cosmos DB keyspace name.
  1847  // viewName - cosmos DB view name.
  1848  func (client CassandraResourcesClient) MigrateCassandraViewToAutoscale(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (result CassandraResourcesMigrateCassandraViewToAutoscaleFuture, err error) {
  1849  	if tracing.IsEnabled() {
  1850  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.MigrateCassandraViewToAutoscale")
  1851  		defer func() {
  1852  			sc := -1
  1853  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
  1854  				sc = result.FutureAPI.Response().StatusCode
  1855  			}
  1856  			tracing.EndSpan(ctx, sc, err)
  1857  		}()
  1858  	}
  1859  	if err := validation.Validate([]validation.Validation{
  1860  		{TargetValue: client.SubscriptionID,
  1861  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1862  		{TargetValue: resourceGroupName,
  1863  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1864  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1865  		{TargetValue: accountName,
  1866  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1867  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1868  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1869  		return result, validation.NewError("documentdb.CassandraResourcesClient", "MigrateCassandraViewToAutoscale", err.Error())
  1870  	}
  1871  
  1872  	req, err := client.MigrateCassandraViewToAutoscalePreparer(ctx, resourceGroupName, accountName, keyspaceName, viewName)
  1873  	if err != nil {
  1874  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraViewToAutoscale", nil, "Failure preparing request")
  1875  		return
  1876  	}
  1877  
  1878  	result, err = client.MigrateCassandraViewToAutoscaleSender(req)
  1879  	if err != nil {
  1880  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraViewToAutoscale", result.Response(), "Failure sending request")
  1881  		return
  1882  	}
  1883  
  1884  	return
  1885  }
  1886  
  1887  // MigrateCassandraViewToAutoscalePreparer prepares the MigrateCassandraViewToAutoscale request.
  1888  func (client CassandraResourcesClient) MigrateCassandraViewToAutoscalePreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (*http.Request, error) {
  1889  	pathParameters := map[string]interface{}{
  1890  		"accountName":       autorest.Encode("path", accountName),
  1891  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1892  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1893  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1894  		"viewName":          autorest.Encode("path", viewName),
  1895  	}
  1896  
  1897  	const APIVersion = "2021-11-15-preview"
  1898  	queryParameters := map[string]interface{}{
  1899  		"api-version": APIVersion,
  1900  	}
  1901  
  1902  	preparer := autorest.CreatePreparer(
  1903  		autorest.AsPost(),
  1904  		autorest.WithBaseURL(client.BaseURI),
  1905  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}/throughputSettings/default/migrateToAutoscale", pathParameters),
  1906  		autorest.WithQueryParameters(queryParameters))
  1907  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  1908  }
  1909  
  1910  // MigrateCassandraViewToAutoscaleSender sends the MigrateCassandraViewToAutoscale request. The method will close the
  1911  // http.Response Body if it receives an error.
  1912  func (client CassandraResourcesClient) MigrateCassandraViewToAutoscaleSender(req *http.Request) (future CassandraResourcesMigrateCassandraViewToAutoscaleFuture, err error) {
  1913  	var resp *http.Response
  1914  	future.FutureAPI = &azure.Future{}
  1915  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
  1916  	if err != nil {
  1917  		return
  1918  	}
  1919  	var azf azure.Future
  1920  	azf, err = azure.NewFutureFromResponse(resp)
  1921  	future.FutureAPI = &azf
  1922  	future.Result = future.result
  1923  	return
  1924  }
  1925  
  1926  // MigrateCassandraViewToAutoscaleResponder handles the response to the MigrateCassandraViewToAutoscale request. The method always
  1927  // closes the http.Response Body.
  1928  func (client CassandraResourcesClient) MigrateCassandraViewToAutoscaleResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  1929  	err = autorest.Respond(
  1930  		resp,
  1931  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
  1932  		autorest.ByUnmarshallingJSON(&result),
  1933  		autorest.ByClosing())
  1934  	result.Response = autorest.Response{Response: resp}
  1935  	return
  1936  }
  1937  
  1938  // MigrateCassandraViewToManualThroughput migrate an Azure Cosmos DB Cassandra view from autoscale to manual throughput
  1939  // Parameters:
  1940  // resourceGroupName - the name of the resource group. The name is case insensitive.
  1941  // accountName - cosmos DB database account name.
  1942  // keyspaceName - cosmos DB keyspace name.
  1943  // viewName - cosmos DB view name.
  1944  func (client CassandraResourcesClient) MigrateCassandraViewToManualThroughput(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (result CassandraResourcesMigrateCassandraViewToManualThroughputFuture, err error) {
  1945  	if tracing.IsEnabled() {
  1946  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.MigrateCassandraViewToManualThroughput")
  1947  		defer func() {
  1948  			sc := -1
  1949  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
  1950  				sc = result.FutureAPI.Response().StatusCode
  1951  			}
  1952  			tracing.EndSpan(ctx, sc, err)
  1953  		}()
  1954  	}
  1955  	if err := validation.Validate([]validation.Validation{
  1956  		{TargetValue: client.SubscriptionID,
  1957  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1958  		{TargetValue: resourceGroupName,
  1959  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  1960  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  1961  		{TargetValue: accountName,
  1962  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  1963  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  1964  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}}}); err != nil {
  1965  		return result, validation.NewError("documentdb.CassandraResourcesClient", "MigrateCassandraViewToManualThroughput", err.Error())
  1966  	}
  1967  
  1968  	req, err := client.MigrateCassandraViewToManualThroughputPreparer(ctx, resourceGroupName, accountName, keyspaceName, viewName)
  1969  	if err != nil {
  1970  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraViewToManualThroughput", nil, "Failure preparing request")
  1971  		return
  1972  	}
  1973  
  1974  	result, err = client.MigrateCassandraViewToManualThroughputSender(req)
  1975  	if err != nil {
  1976  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "MigrateCassandraViewToManualThroughput", result.Response(), "Failure sending request")
  1977  		return
  1978  	}
  1979  
  1980  	return
  1981  }
  1982  
  1983  // MigrateCassandraViewToManualThroughputPreparer prepares the MigrateCassandraViewToManualThroughput request.
  1984  func (client CassandraResourcesClient) MigrateCassandraViewToManualThroughputPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string) (*http.Request, error) {
  1985  	pathParameters := map[string]interface{}{
  1986  		"accountName":       autorest.Encode("path", accountName),
  1987  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  1988  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  1989  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  1990  		"viewName":          autorest.Encode("path", viewName),
  1991  	}
  1992  
  1993  	const APIVersion = "2021-11-15-preview"
  1994  	queryParameters := map[string]interface{}{
  1995  		"api-version": APIVersion,
  1996  	}
  1997  
  1998  	preparer := autorest.CreatePreparer(
  1999  		autorest.AsPost(),
  2000  		autorest.WithBaseURL(client.BaseURI),
  2001  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}/throughputSettings/default/migrateToManualThroughput", pathParameters),
  2002  		autorest.WithQueryParameters(queryParameters))
  2003  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  2004  }
  2005  
  2006  // MigrateCassandraViewToManualThroughputSender sends the MigrateCassandraViewToManualThroughput request. The method will close the
  2007  // http.Response Body if it receives an error.
  2008  func (client CassandraResourcesClient) MigrateCassandraViewToManualThroughputSender(req *http.Request) (future CassandraResourcesMigrateCassandraViewToManualThroughputFuture, err error) {
  2009  	var resp *http.Response
  2010  	future.FutureAPI = &azure.Future{}
  2011  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
  2012  	if err != nil {
  2013  		return
  2014  	}
  2015  	var azf azure.Future
  2016  	azf, err = azure.NewFutureFromResponse(resp)
  2017  	future.FutureAPI = &azf
  2018  	future.Result = future.result
  2019  	return
  2020  }
  2021  
  2022  // MigrateCassandraViewToManualThroughputResponder handles the response to the MigrateCassandraViewToManualThroughput request. The method always
  2023  // closes the http.Response Body.
  2024  func (client CassandraResourcesClient) MigrateCassandraViewToManualThroughputResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  2025  	err = autorest.Respond(
  2026  		resp,
  2027  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
  2028  		autorest.ByUnmarshallingJSON(&result),
  2029  		autorest.ByClosing())
  2030  	result.Response = autorest.Response{Response: resp}
  2031  	return
  2032  }
  2033  
  2034  // UpdateCassandraKeyspaceThroughput update RUs per second of an Azure Cosmos DB Cassandra Keyspace
  2035  // Parameters:
  2036  // resourceGroupName - the name of the resource group. The name is case insensitive.
  2037  // accountName - cosmos DB database account name.
  2038  // keyspaceName - cosmos DB keyspace name.
  2039  // updateThroughputParameters - the RUs per second of the parameters to provide for the current Cassandra
  2040  // Keyspace.
  2041  func (client CassandraResourcesClient) UpdateCassandraKeyspaceThroughput(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, updateThroughputParameters ThroughputSettingsUpdateParameters) (result CassandraResourcesUpdateCassandraKeyspaceThroughputFuture, err error) {
  2042  	if tracing.IsEnabled() {
  2043  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.UpdateCassandraKeyspaceThroughput")
  2044  		defer func() {
  2045  			sc := -1
  2046  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
  2047  				sc = result.FutureAPI.Response().StatusCode
  2048  			}
  2049  			tracing.EndSpan(ctx, sc, err)
  2050  		}()
  2051  	}
  2052  	if err := validation.Validate([]validation.Validation{
  2053  		{TargetValue: client.SubscriptionID,
  2054  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  2055  		{TargetValue: resourceGroupName,
  2056  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  2057  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  2058  		{TargetValue: accountName,
  2059  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  2060  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  2061  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}},
  2062  		{TargetValue: updateThroughputParameters,
  2063  			Constraints: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties", Name: validation.Null, Rule: true,
  2064  				Chain: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties.Resource", Name: validation.Null, Rule: true,
  2065  					Chain: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties.Resource.AutoscaleSettings", Name: validation.Null, Rule: false,
  2066  						Chain: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties.Resource.AutoscaleSettings.MaxThroughput", Name: validation.Null, Rule: true, Chain: nil}}},
  2067  					}},
  2068  				}}}}}); err != nil {
  2069  		return result, validation.NewError("documentdb.CassandraResourcesClient", "UpdateCassandraKeyspaceThroughput", err.Error())
  2070  	}
  2071  
  2072  	req, err := client.UpdateCassandraKeyspaceThroughputPreparer(ctx, resourceGroupName, accountName, keyspaceName, updateThroughputParameters)
  2073  	if err != nil {
  2074  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "UpdateCassandraKeyspaceThroughput", nil, "Failure preparing request")
  2075  		return
  2076  	}
  2077  
  2078  	result, err = client.UpdateCassandraKeyspaceThroughputSender(req)
  2079  	if err != nil {
  2080  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "UpdateCassandraKeyspaceThroughput", result.Response(), "Failure sending request")
  2081  		return
  2082  	}
  2083  
  2084  	return
  2085  }
  2086  
  2087  // UpdateCassandraKeyspaceThroughputPreparer prepares the UpdateCassandraKeyspaceThroughput request.
  2088  func (client CassandraResourcesClient) UpdateCassandraKeyspaceThroughputPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, updateThroughputParameters ThroughputSettingsUpdateParameters) (*http.Request, error) {
  2089  	pathParameters := map[string]interface{}{
  2090  		"accountName":       autorest.Encode("path", accountName),
  2091  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  2092  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  2093  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  2094  	}
  2095  
  2096  	const APIVersion = "2021-11-15-preview"
  2097  	queryParameters := map[string]interface{}{
  2098  		"api-version": APIVersion,
  2099  	}
  2100  
  2101  	preparer := autorest.CreatePreparer(
  2102  		autorest.AsContentType("application/json; charset=utf-8"),
  2103  		autorest.AsPut(),
  2104  		autorest.WithBaseURL(client.BaseURI),
  2105  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/throughputSettings/default", pathParameters),
  2106  		autorest.WithJSON(updateThroughputParameters),
  2107  		autorest.WithQueryParameters(queryParameters))
  2108  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  2109  }
  2110  
  2111  // UpdateCassandraKeyspaceThroughputSender sends the UpdateCassandraKeyspaceThroughput request. The method will close the
  2112  // http.Response Body if it receives an error.
  2113  func (client CassandraResourcesClient) UpdateCassandraKeyspaceThroughputSender(req *http.Request) (future CassandraResourcesUpdateCassandraKeyspaceThroughputFuture, err error) {
  2114  	var resp *http.Response
  2115  	future.FutureAPI = &azure.Future{}
  2116  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
  2117  	if err != nil {
  2118  		return
  2119  	}
  2120  	var azf azure.Future
  2121  	azf, err = azure.NewFutureFromResponse(resp)
  2122  	future.FutureAPI = &azf
  2123  	future.Result = future.result
  2124  	return
  2125  }
  2126  
  2127  // UpdateCassandraKeyspaceThroughputResponder handles the response to the UpdateCassandraKeyspaceThroughput request. The method always
  2128  // closes the http.Response Body.
  2129  func (client CassandraResourcesClient) UpdateCassandraKeyspaceThroughputResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  2130  	err = autorest.Respond(
  2131  		resp,
  2132  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
  2133  		autorest.ByUnmarshallingJSON(&result),
  2134  		autorest.ByClosing())
  2135  	result.Response = autorest.Response{Response: resp}
  2136  	return
  2137  }
  2138  
  2139  // UpdateCassandraTableThroughput update RUs per second of an Azure Cosmos DB Cassandra table
  2140  // Parameters:
  2141  // resourceGroupName - the name of the resource group. The name is case insensitive.
  2142  // accountName - cosmos DB database account name.
  2143  // keyspaceName - cosmos DB keyspace name.
  2144  // tableName - cosmos DB table name.
  2145  // updateThroughputParameters - the RUs per second of the parameters to provide for the current Cassandra
  2146  // table.
  2147  func (client CassandraResourcesClient) UpdateCassandraTableThroughput(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string, updateThroughputParameters ThroughputSettingsUpdateParameters) (result CassandraResourcesUpdateCassandraTableThroughputFuture, err error) {
  2148  	if tracing.IsEnabled() {
  2149  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.UpdateCassandraTableThroughput")
  2150  		defer func() {
  2151  			sc := -1
  2152  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
  2153  				sc = result.FutureAPI.Response().StatusCode
  2154  			}
  2155  			tracing.EndSpan(ctx, sc, err)
  2156  		}()
  2157  	}
  2158  	if err := validation.Validate([]validation.Validation{
  2159  		{TargetValue: client.SubscriptionID,
  2160  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  2161  		{TargetValue: resourceGroupName,
  2162  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  2163  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  2164  		{TargetValue: accountName,
  2165  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  2166  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  2167  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}},
  2168  		{TargetValue: updateThroughputParameters,
  2169  			Constraints: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties", Name: validation.Null, Rule: true,
  2170  				Chain: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties.Resource", Name: validation.Null, Rule: true,
  2171  					Chain: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties.Resource.AutoscaleSettings", Name: validation.Null, Rule: false,
  2172  						Chain: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties.Resource.AutoscaleSettings.MaxThroughput", Name: validation.Null, Rule: true, Chain: nil}}},
  2173  					}},
  2174  				}}}}}); err != nil {
  2175  		return result, validation.NewError("documentdb.CassandraResourcesClient", "UpdateCassandraTableThroughput", err.Error())
  2176  	}
  2177  
  2178  	req, err := client.UpdateCassandraTableThroughputPreparer(ctx, resourceGroupName, accountName, keyspaceName, tableName, updateThroughputParameters)
  2179  	if err != nil {
  2180  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "UpdateCassandraTableThroughput", nil, "Failure preparing request")
  2181  		return
  2182  	}
  2183  
  2184  	result, err = client.UpdateCassandraTableThroughputSender(req)
  2185  	if err != nil {
  2186  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "UpdateCassandraTableThroughput", result.Response(), "Failure sending request")
  2187  		return
  2188  	}
  2189  
  2190  	return
  2191  }
  2192  
  2193  // UpdateCassandraTableThroughputPreparer prepares the UpdateCassandraTableThroughput request.
  2194  func (client CassandraResourcesClient) UpdateCassandraTableThroughputPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, tableName string, updateThroughputParameters ThroughputSettingsUpdateParameters) (*http.Request, error) {
  2195  	pathParameters := map[string]interface{}{
  2196  		"accountName":       autorest.Encode("path", accountName),
  2197  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  2198  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  2199  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  2200  		"tableName":         autorest.Encode("path", tableName),
  2201  	}
  2202  
  2203  	const APIVersion = "2021-11-15-preview"
  2204  	queryParameters := map[string]interface{}{
  2205  		"api-version": APIVersion,
  2206  	}
  2207  
  2208  	preparer := autorest.CreatePreparer(
  2209  		autorest.AsContentType("application/json; charset=utf-8"),
  2210  		autorest.AsPut(),
  2211  		autorest.WithBaseURL(client.BaseURI),
  2212  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/tables/{tableName}/throughputSettings/default", pathParameters),
  2213  		autorest.WithJSON(updateThroughputParameters),
  2214  		autorest.WithQueryParameters(queryParameters))
  2215  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  2216  }
  2217  
  2218  // UpdateCassandraTableThroughputSender sends the UpdateCassandraTableThroughput request. The method will close the
  2219  // http.Response Body if it receives an error.
  2220  func (client CassandraResourcesClient) UpdateCassandraTableThroughputSender(req *http.Request) (future CassandraResourcesUpdateCassandraTableThroughputFuture, err error) {
  2221  	var resp *http.Response
  2222  	future.FutureAPI = &azure.Future{}
  2223  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
  2224  	if err != nil {
  2225  		return
  2226  	}
  2227  	var azf azure.Future
  2228  	azf, err = azure.NewFutureFromResponse(resp)
  2229  	future.FutureAPI = &azf
  2230  	future.Result = future.result
  2231  	return
  2232  }
  2233  
  2234  // UpdateCassandraTableThroughputResponder handles the response to the UpdateCassandraTableThroughput request. The method always
  2235  // closes the http.Response Body.
  2236  func (client CassandraResourcesClient) UpdateCassandraTableThroughputResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  2237  	err = autorest.Respond(
  2238  		resp,
  2239  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
  2240  		autorest.ByUnmarshallingJSON(&result),
  2241  		autorest.ByClosing())
  2242  	result.Response = autorest.Response{Response: resp}
  2243  	return
  2244  }
  2245  
  2246  // UpdateCassandraViewThroughput update RUs per second of an Azure Cosmos DB Cassandra view
  2247  // Parameters:
  2248  // resourceGroupName - the name of the resource group. The name is case insensitive.
  2249  // accountName - cosmos DB database account name.
  2250  // keyspaceName - cosmos DB keyspace name.
  2251  // viewName - cosmos DB view name.
  2252  // updateThroughputParameters - the RUs per second of the parameters to provide for the current Cassandra view.
  2253  func (client CassandraResourcesClient) UpdateCassandraViewThroughput(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string, updateThroughputParameters ThroughputSettingsUpdateParameters) (result CassandraResourcesUpdateCassandraViewThroughputFuture, err error) {
  2254  	if tracing.IsEnabled() {
  2255  		ctx = tracing.StartSpan(ctx, fqdn+"/CassandraResourcesClient.UpdateCassandraViewThroughput")
  2256  		defer func() {
  2257  			sc := -1
  2258  			if result.FutureAPI != nil && result.FutureAPI.Response() != nil {
  2259  				sc = result.FutureAPI.Response().StatusCode
  2260  			}
  2261  			tracing.EndSpan(ctx, sc, err)
  2262  		}()
  2263  	}
  2264  	if err := validation.Validate([]validation.Validation{
  2265  		{TargetValue: client.SubscriptionID,
  2266  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  2267  		{TargetValue: resourceGroupName,
  2268  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
  2269  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
  2270  		{TargetValue: accountName,
  2271  			Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 50, Chain: nil},
  2272  				{Target: "accountName", Name: validation.MinLength, Rule: 3, Chain: nil},
  2273  				{Target: "accountName", Name: validation.Pattern, Rule: `^[a-z0-9]+(-[a-z0-9]+)*`, Chain: nil}}},
  2274  		{TargetValue: updateThroughputParameters,
  2275  			Constraints: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties", Name: validation.Null, Rule: true,
  2276  				Chain: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties.Resource", Name: validation.Null, Rule: true,
  2277  					Chain: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties.Resource.AutoscaleSettings", Name: validation.Null, Rule: false,
  2278  						Chain: []validation.Constraint{{Target: "updateThroughputParameters.ThroughputSettingsUpdateProperties.Resource.AutoscaleSettings.MaxThroughput", Name: validation.Null, Rule: true, Chain: nil}}},
  2279  					}},
  2280  				}}}}}); err != nil {
  2281  		return result, validation.NewError("documentdb.CassandraResourcesClient", "UpdateCassandraViewThroughput", err.Error())
  2282  	}
  2283  
  2284  	req, err := client.UpdateCassandraViewThroughputPreparer(ctx, resourceGroupName, accountName, keyspaceName, viewName, updateThroughputParameters)
  2285  	if err != nil {
  2286  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "UpdateCassandraViewThroughput", nil, "Failure preparing request")
  2287  		return
  2288  	}
  2289  
  2290  	result, err = client.UpdateCassandraViewThroughputSender(req)
  2291  	if err != nil {
  2292  		err = autorest.NewErrorWithError(err, "documentdb.CassandraResourcesClient", "UpdateCassandraViewThroughput", result.Response(), "Failure sending request")
  2293  		return
  2294  	}
  2295  
  2296  	return
  2297  }
  2298  
  2299  // UpdateCassandraViewThroughputPreparer prepares the UpdateCassandraViewThroughput request.
  2300  func (client CassandraResourcesClient) UpdateCassandraViewThroughputPreparer(ctx context.Context, resourceGroupName string, accountName string, keyspaceName string, viewName string, updateThroughputParameters ThroughputSettingsUpdateParameters) (*http.Request, error) {
  2301  	pathParameters := map[string]interface{}{
  2302  		"accountName":       autorest.Encode("path", accountName),
  2303  		"keyspaceName":      autorest.Encode("path", keyspaceName),
  2304  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
  2305  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
  2306  		"viewName":          autorest.Encode("path", viewName),
  2307  	}
  2308  
  2309  	const APIVersion = "2021-11-15-preview"
  2310  	queryParameters := map[string]interface{}{
  2311  		"api-version": APIVersion,
  2312  	}
  2313  
  2314  	preparer := autorest.CreatePreparer(
  2315  		autorest.AsContentType("application/json; charset=utf-8"),
  2316  		autorest.AsPut(),
  2317  		autorest.WithBaseURL(client.BaseURI),
  2318  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}/throughputSettings/default", pathParameters),
  2319  		autorest.WithJSON(updateThroughputParameters),
  2320  		autorest.WithQueryParameters(queryParameters))
  2321  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
  2322  }
  2323  
  2324  // UpdateCassandraViewThroughputSender sends the UpdateCassandraViewThroughput request. The method will close the
  2325  // http.Response Body if it receives an error.
  2326  func (client CassandraResourcesClient) UpdateCassandraViewThroughputSender(req *http.Request) (future CassandraResourcesUpdateCassandraViewThroughputFuture, err error) {
  2327  	var resp *http.Response
  2328  	future.FutureAPI = &azure.Future{}
  2329  	resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
  2330  	if err != nil {
  2331  		return
  2332  	}
  2333  	var azf azure.Future
  2334  	azf, err = azure.NewFutureFromResponse(resp)
  2335  	future.FutureAPI = &azf
  2336  	future.Result = future.result
  2337  	return
  2338  }
  2339  
  2340  // UpdateCassandraViewThroughputResponder handles the response to the UpdateCassandraViewThroughput request. The method always
  2341  // closes the http.Response Body.
  2342  func (client CassandraResourcesClient) UpdateCassandraViewThroughputResponder(resp *http.Response) (result ThroughputSettingsGetResults, err error) {
  2343  	err = autorest.Respond(
  2344  		resp,
  2345  		azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
  2346  		autorest.ByUnmarshallingJSON(&result),
  2347  		autorest.ByClosing())
  2348  	result.Response = autorest.Response{Response: resp}
  2349  	return
  2350  }
  2351  

View as plain text