...

Source file src/github.com/Azure/azure-sdk-for-go/services/preview/appinsights/mgmt/2020-02-02-preview/insights/exportconfigurations.go

Documentation: github.com/Azure/azure-sdk-for-go/services/preview/appinsights/mgmt/2020-02-02-preview/insights

     1  package insights
     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  // ExportConfigurationsClient is the composite Swagger for Application Insights Management Client
    19  type ExportConfigurationsClient struct {
    20  	BaseClient
    21  }
    22  
    23  // NewExportConfigurationsClient creates an instance of the ExportConfigurationsClient client.
    24  func NewExportConfigurationsClient(subscriptionID string) ExportConfigurationsClient {
    25  	return NewExportConfigurationsClientWithBaseURI(DefaultBaseURI, subscriptionID)
    26  }
    27  
    28  // NewExportConfigurationsClientWithBaseURI creates an instance of the ExportConfigurationsClient 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 NewExportConfigurationsClientWithBaseURI(baseURI string, subscriptionID string) ExportConfigurationsClient {
    32  	return ExportConfigurationsClient{NewWithBaseURI(baseURI, subscriptionID)}
    33  }
    34  
    35  // Create create a Continuous Export configuration of an Application Insights component.
    36  // Parameters:
    37  // resourceGroupName - the name of the resource group. The name is case insensitive.
    38  // resourceName - the name of the Application Insights component resource.
    39  // exportProperties - properties that need to be specified to create a Continuous Export configuration of a
    40  // Application Insights component.
    41  func (client ExportConfigurationsClient) Create(ctx context.Context, resourceGroupName string, resourceName string, exportProperties ApplicationInsightsComponentExportRequest) (result ListApplicationInsightsComponentExportConfiguration, err error) {
    42  	if tracing.IsEnabled() {
    43  		ctx = tracing.StartSpan(ctx, fqdn+"/ExportConfigurationsClient.Create")
    44  		defer func() {
    45  			sc := -1
    46  			if result.Response.Response != nil {
    47  				sc = result.Response.Response.StatusCode
    48  			}
    49  			tracing.EndSpan(ctx, sc, err)
    50  		}()
    51  	}
    52  	if err := validation.Validate([]validation.Validation{
    53  		{TargetValue: resourceGroupName,
    54  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
    55  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
    56  		{TargetValue: client.SubscriptionID,
    57  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}}}); err != nil {
    58  		return result, validation.NewError("insights.ExportConfigurationsClient", "Create", err.Error())
    59  	}
    60  
    61  	req, err := client.CreatePreparer(ctx, resourceGroupName, resourceName, exportProperties)
    62  	if err != nil {
    63  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Create", nil, "Failure preparing request")
    64  		return
    65  	}
    66  
    67  	resp, err := client.CreateSender(req)
    68  	if err != nil {
    69  		result.Response = autorest.Response{Response: resp}
    70  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Create", resp, "Failure sending request")
    71  		return
    72  	}
    73  
    74  	result, err = client.CreateResponder(resp)
    75  	if err != nil {
    76  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Create", resp, "Failure responding to request")
    77  		return
    78  	}
    79  
    80  	return
    81  }
    82  
    83  // CreatePreparer prepares the Create request.
    84  func (client ExportConfigurationsClient) CreatePreparer(ctx context.Context, resourceGroupName string, resourceName string, exportProperties ApplicationInsightsComponentExportRequest) (*http.Request, error) {
    85  	pathParameters := map[string]interface{}{
    86  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
    87  		"resourceName":      autorest.Encode("path", resourceName),
    88  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
    89  	}
    90  
    91  	const APIVersion = "2015-05-01"
    92  	queryParameters := map[string]interface{}{
    93  		"api-version": APIVersion,
    94  	}
    95  
    96  	preparer := autorest.CreatePreparer(
    97  		autorest.AsContentType("application/json; charset=utf-8"),
    98  		autorest.AsPost(),
    99  		autorest.WithBaseURL(client.BaseURI),
   100  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/components/{resourceName}/exportconfiguration", pathParameters),
   101  		autorest.WithJSON(exportProperties),
   102  		autorest.WithQueryParameters(queryParameters))
   103  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   104  }
   105  
   106  // CreateSender sends the Create request. The method will close the
   107  // http.Response Body if it receives an error.
   108  func (client ExportConfigurationsClient) CreateSender(req *http.Request) (*http.Response, error) {
   109  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
   110  }
   111  
   112  // CreateResponder handles the response to the Create request. The method always
   113  // closes the http.Response Body.
   114  func (client ExportConfigurationsClient) CreateResponder(resp *http.Response) (result ListApplicationInsightsComponentExportConfiguration, err error) {
   115  	err = autorest.Respond(
   116  		resp,
   117  		azure.WithErrorUnlessStatusCode(http.StatusOK),
   118  		autorest.ByUnmarshallingJSON(&result.Value),
   119  		autorest.ByClosing())
   120  	result.Response = autorest.Response{Response: resp}
   121  	return
   122  }
   123  
   124  // Delete delete a Continuous Export configuration of an Application Insights component.
   125  // Parameters:
   126  // resourceGroupName - the name of the resource group. The name is case insensitive.
   127  // resourceName - the name of the Application Insights component resource.
   128  // exportID - the Continuous Export configuration ID. This is unique within a Application Insights component.
   129  func (client ExportConfigurationsClient) Delete(ctx context.Context, resourceGroupName string, resourceName string, exportID string) (result ApplicationInsightsComponentExportConfiguration, err error) {
   130  	if tracing.IsEnabled() {
   131  		ctx = tracing.StartSpan(ctx, fqdn+"/ExportConfigurationsClient.Delete")
   132  		defer func() {
   133  			sc := -1
   134  			if result.Response.Response != nil {
   135  				sc = result.Response.Response.StatusCode
   136  			}
   137  			tracing.EndSpan(ctx, sc, err)
   138  		}()
   139  	}
   140  	if err := validation.Validate([]validation.Validation{
   141  		{TargetValue: resourceGroupName,
   142  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   143  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   144  		{TargetValue: client.SubscriptionID,
   145  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}}}); err != nil {
   146  		return result, validation.NewError("insights.ExportConfigurationsClient", "Delete", err.Error())
   147  	}
   148  
   149  	req, err := client.DeletePreparer(ctx, resourceGroupName, resourceName, exportID)
   150  	if err != nil {
   151  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Delete", nil, "Failure preparing request")
   152  		return
   153  	}
   154  
   155  	resp, err := client.DeleteSender(req)
   156  	if err != nil {
   157  		result.Response = autorest.Response{Response: resp}
   158  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Delete", resp, "Failure sending request")
   159  		return
   160  	}
   161  
   162  	result, err = client.DeleteResponder(resp)
   163  	if err != nil {
   164  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Delete", resp, "Failure responding to request")
   165  		return
   166  	}
   167  
   168  	return
   169  }
   170  
   171  // DeletePreparer prepares the Delete request.
   172  func (client ExportConfigurationsClient) DeletePreparer(ctx context.Context, resourceGroupName string, resourceName string, exportID string) (*http.Request, error) {
   173  	pathParameters := map[string]interface{}{
   174  		"exportId":          autorest.Encode("path", exportID),
   175  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   176  		"resourceName":      autorest.Encode("path", resourceName),
   177  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   178  	}
   179  
   180  	const APIVersion = "2015-05-01"
   181  	queryParameters := map[string]interface{}{
   182  		"api-version": APIVersion,
   183  	}
   184  
   185  	preparer := autorest.CreatePreparer(
   186  		autorest.AsDelete(),
   187  		autorest.WithBaseURL(client.BaseURI),
   188  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/components/{resourceName}/exportconfiguration/{exportId}", pathParameters),
   189  		autorest.WithQueryParameters(queryParameters))
   190  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   191  }
   192  
   193  // DeleteSender sends the Delete request. The method will close the
   194  // http.Response Body if it receives an error.
   195  func (client ExportConfigurationsClient) DeleteSender(req *http.Request) (*http.Response, error) {
   196  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
   197  }
   198  
   199  // DeleteResponder handles the response to the Delete request. The method always
   200  // closes the http.Response Body.
   201  func (client ExportConfigurationsClient) DeleteResponder(resp *http.Response) (result ApplicationInsightsComponentExportConfiguration, err error) {
   202  	err = autorest.Respond(
   203  		resp,
   204  		azure.WithErrorUnlessStatusCode(http.StatusOK),
   205  		autorest.ByUnmarshallingJSON(&result),
   206  		autorest.ByClosing())
   207  	result.Response = autorest.Response{Response: resp}
   208  	return
   209  }
   210  
   211  // Get get the Continuous Export configuration for this export id.
   212  // Parameters:
   213  // resourceGroupName - the name of the resource group. The name is case insensitive.
   214  // resourceName - the name of the Application Insights component resource.
   215  // exportID - the Continuous Export configuration ID. This is unique within a Application Insights component.
   216  func (client ExportConfigurationsClient) Get(ctx context.Context, resourceGroupName string, resourceName string, exportID string) (result ApplicationInsightsComponentExportConfiguration, err error) {
   217  	if tracing.IsEnabled() {
   218  		ctx = tracing.StartSpan(ctx, fqdn+"/ExportConfigurationsClient.Get")
   219  		defer func() {
   220  			sc := -1
   221  			if result.Response.Response != nil {
   222  				sc = result.Response.Response.StatusCode
   223  			}
   224  			tracing.EndSpan(ctx, sc, err)
   225  		}()
   226  	}
   227  	if err := validation.Validate([]validation.Validation{
   228  		{TargetValue: resourceGroupName,
   229  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   230  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   231  		{TargetValue: client.SubscriptionID,
   232  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}}}); err != nil {
   233  		return result, validation.NewError("insights.ExportConfigurationsClient", "Get", err.Error())
   234  	}
   235  
   236  	req, err := client.GetPreparer(ctx, resourceGroupName, resourceName, exportID)
   237  	if err != nil {
   238  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Get", nil, "Failure preparing request")
   239  		return
   240  	}
   241  
   242  	resp, err := client.GetSender(req)
   243  	if err != nil {
   244  		result.Response = autorest.Response{Response: resp}
   245  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Get", resp, "Failure sending request")
   246  		return
   247  	}
   248  
   249  	result, err = client.GetResponder(resp)
   250  	if err != nil {
   251  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Get", resp, "Failure responding to request")
   252  		return
   253  	}
   254  
   255  	return
   256  }
   257  
   258  // GetPreparer prepares the Get request.
   259  func (client ExportConfigurationsClient) GetPreparer(ctx context.Context, resourceGroupName string, resourceName string, exportID string) (*http.Request, error) {
   260  	pathParameters := map[string]interface{}{
   261  		"exportId":          autorest.Encode("path", exportID),
   262  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   263  		"resourceName":      autorest.Encode("path", resourceName),
   264  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   265  	}
   266  
   267  	const APIVersion = "2015-05-01"
   268  	queryParameters := map[string]interface{}{
   269  		"api-version": APIVersion,
   270  	}
   271  
   272  	preparer := autorest.CreatePreparer(
   273  		autorest.AsGet(),
   274  		autorest.WithBaseURL(client.BaseURI),
   275  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/components/{resourceName}/exportconfiguration/{exportId}", pathParameters),
   276  		autorest.WithQueryParameters(queryParameters))
   277  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   278  }
   279  
   280  // GetSender sends the Get request. The method will close the
   281  // http.Response Body if it receives an error.
   282  func (client ExportConfigurationsClient) GetSender(req *http.Request) (*http.Response, error) {
   283  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
   284  }
   285  
   286  // GetResponder handles the response to the Get request. The method always
   287  // closes the http.Response Body.
   288  func (client ExportConfigurationsClient) GetResponder(resp *http.Response) (result ApplicationInsightsComponentExportConfiguration, err error) {
   289  	err = autorest.Respond(
   290  		resp,
   291  		azure.WithErrorUnlessStatusCode(http.StatusOK),
   292  		autorest.ByUnmarshallingJSON(&result),
   293  		autorest.ByClosing())
   294  	result.Response = autorest.Response{Response: resp}
   295  	return
   296  }
   297  
   298  // List gets a list of Continuous Export configuration of an Application Insights component.
   299  // Parameters:
   300  // resourceGroupName - the name of the resource group. The name is case insensitive.
   301  // resourceName - the name of the Application Insights component resource.
   302  func (client ExportConfigurationsClient) List(ctx context.Context, resourceGroupName string, resourceName string) (result ListApplicationInsightsComponentExportConfiguration, err error) {
   303  	if tracing.IsEnabled() {
   304  		ctx = tracing.StartSpan(ctx, fqdn+"/ExportConfigurationsClient.List")
   305  		defer func() {
   306  			sc := -1
   307  			if result.Response.Response != nil {
   308  				sc = result.Response.Response.StatusCode
   309  			}
   310  			tracing.EndSpan(ctx, sc, err)
   311  		}()
   312  	}
   313  	if err := validation.Validate([]validation.Validation{
   314  		{TargetValue: resourceGroupName,
   315  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   316  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   317  		{TargetValue: client.SubscriptionID,
   318  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}}}); err != nil {
   319  		return result, validation.NewError("insights.ExportConfigurationsClient", "List", err.Error())
   320  	}
   321  
   322  	req, err := client.ListPreparer(ctx, resourceGroupName, resourceName)
   323  	if err != nil {
   324  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "List", nil, "Failure preparing request")
   325  		return
   326  	}
   327  
   328  	resp, err := client.ListSender(req)
   329  	if err != nil {
   330  		result.Response = autorest.Response{Response: resp}
   331  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "List", resp, "Failure sending request")
   332  		return
   333  	}
   334  
   335  	result, err = client.ListResponder(resp)
   336  	if err != nil {
   337  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "List", resp, "Failure responding to request")
   338  		return
   339  	}
   340  
   341  	return
   342  }
   343  
   344  // ListPreparer prepares the List request.
   345  func (client ExportConfigurationsClient) ListPreparer(ctx context.Context, resourceGroupName string, resourceName string) (*http.Request, error) {
   346  	pathParameters := map[string]interface{}{
   347  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   348  		"resourceName":      autorest.Encode("path", resourceName),
   349  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   350  	}
   351  
   352  	const APIVersion = "2015-05-01"
   353  	queryParameters := map[string]interface{}{
   354  		"api-version": APIVersion,
   355  	}
   356  
   357  	preparer := autorest.CreatePreparer(
   358  		autorest.AsGet(),
   359  		autorest.WithBaseURL(client.BaseURI),
   360  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/components/{resourceName}/exportconfiguration", pathParameters),
   361  		autorest.WithQueryParameters(queryParameters))
   362  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   363  }
   364  
   365  // ListSender sends the List request. The method will close the
   366  // http.Response Body if it receives an error.
   367  func (client ExportConfigurationsClient) ListSender(req *http.Request) (*http.Response, error) {
   368  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
   369  }
   370  
   371  // ListResponder handles the response to the List request. The method always
   372  // closes the http.Response Body.
   373  func (client ExportConfigurationsClient) ListResponder(resp *http.Response) (result ListApplicationInsightsComponentExportConfiguration, err error) {
   374  	err = autorest.Respond(
   375  		resp,
   376  		azure.WithErrorUnlessStatusCode(http.StatusOK),
   377  		autorest.ByUnmarshallingJSON(&result.Value),
   378  		autorest.ByClosing())
   379  	result.Response = autorest.Response{Response: resp}
   380  	return
   381  }
   382  
   383  // Update update the Continuous Export configuration for this export id.
   384  // Parameters:
   385  // resourceGroupName - the name of the resource group. The name is case insensitive.
   386  // resourceName - the name of the Application Insights component resource.
   387  // exportID - the Continuous Export configuration ID. This is unique within a Application Insights component.
   388  // exportProperties - properties that need to be specified to update the Continuous Export configuration.
   389  func (client ExportConfigurationsClient) Update(ctx context.Context, resourceGroupName string, resourceName string, exportID string, exportProperties ApplicationInsightsComponentExportRequest) (result ApplicationInsightsComponentExportConfiguration, err error) {
   390  	if tracing.IsEnabled() {
   391  		ctx = tracing.StartSpan(ctx, fqdn+"/ExportConfigurationsClient.Update")
   392  		defer func() {
   393  			sc := -1
   394  			if result.Response.Response != nil {
   395  				sc = result.Response.Response.StatusCode
   396  			}
   397  			tracing.EndSpan(ctx, sc, err)
   398  		}()
   399  	}
   400  	if err := validation.Validate([]validation.Validation{
   401  		{TargetValue: resourceGroupName,
   402  			Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
   403  				{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
   404  		{TargetValue: client.SubscriptionID,
   405  			Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}}}); err != nil {
   406  		return result, validation.NewError("insights.ExportConfigurationsClient", "Update", err.Error())
   407  	}
   408  
   409  	req, err := client.UpdatePreparer(ctx, resourceGroupName, resourceName, exportID, exportProperties)
   410  	if err != nil {
   411  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Update", nil, "Failure preparing request")
   412  		return
   413  	}
   414  
   415  	resp, err := client.UpdateSender(req)
   416  	if err != nil {
   417  		result.Response = autorest.Response{Response: resp}
   418  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Update", resp, "Failure sending request")
   419  		return
   420  	}
   421  
   422  	result, err = client.UpdateResponder(resp)
   423  	if err != nil {
   424  		err = autorest.NewErrorWithError(err, "insights.ExportConfigurationsClient", "Update", resp, "Failure responding to request")
   425  		return
   426  	}
   427  
   428  	return
   429  }
   430  
   431  // UpdatePreparer prepares the Update request.
   432  func (client ExportConfigurationsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, resourceName string, exportID string, exportProperties ApplicationInsightsComponentExportRequest) (*http.Request, error) {
   433  	pathParameters := map[string]interface{}{
   434  		"exportId":          autorest.Encode("path", exportID),
   435  		"resourceGroupName": autorest.Encode("path", resourceGroupName),
   436  		"resourceName":      autorest.Encode("path", resourceName),
   437  		"subscriptionId":    autorest.Encode("path", client.SubscriptionID),
   438  	}
   439  
   440  	const APIVersion = "2015-05-01"
   441  	queryParameters := map[string]interface{}{
   442  		"api-version": APIVersion,
   443  	}
   444  
   445  	preparer := autorest.CreatePreparer(
   446  		autorest.AsContentType("application/json; charset=utf-8"),
   447  		autorest.AsPut(),
   448  		autorest.WithBaseURL(client.BaseURI),
   449  		autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/components/{resourceName}/exportconfiguration/{exportId}", pathParameters),
   450  		autorest.WithJSON(exportProperties),
   451  		autorest.WithQueryParameters(queryParameters))
   452  	return preparer.Prepare((&http.Request{}).WithContext(ctx))
   453  }
   454  
   455  // UpdateSender sends the Update request. The method will close the
   456  // http.Response Body if it receives an error.
   457  func (client ExportConfigurationsClient) UpdateSender(req *http.Request) (*http.Response, error) {
   458  	return client.Send(req, azure.DoRetryWithRegistration(client.Client))
   459  }
   460  
   461  // UpdateResponder handles the response to the Update request. The method always
   462  // closes the http.Response Body.
   463  func (client ExportConfigurationsClient) UpdateResponder(resp *http.Response) (result ApplicationInsightsComponentExportConfiguration, err error) {
   464  	err = autorest.Respond(
   465  		resp,
   466  		azure.WithErrorUnlessStatusCode(http.StatusOK),
   467  		autorest.ByUnmarshallingJSON(&result),
   468  		autorest.ByClosing())
   469  	result.Response = autorest.Response{Response: resp}
   470  	return
   471  }
   472  

View as plain text