mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-20 18:31:15 +00:00
Update vendor for Azure API bumps
Signed-off-by: Stephen Augustus <saugustus@vmware.com>
This commit is contained in:
parent
a8ea88960d
commit
77a41043a5
8
vendor/BUILD
vendored
8
vendor/BUILD
vendored
@ -11,10 +11,10 @@ filegroup(
|
||||
":package-srcs",
|
||||
"//vendor/bitbucket.org/bertimus9/systemstat:all-srcs",
|
||||
"//vendor/cloud.google.com/go/compute/metadata:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-03-01/compute:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2018-09-01/containerregistry:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2018-08-01/network:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2018-07-01/storage:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/storage:all-srcs",
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/version:all-srcs",
|
||||
"//vendor/github.com/Azure/go-ansiterm:all-srcs",
|
||||
|
@ -1,401 +0,0 @@
|
||||
package compute
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/tracing"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// GalleryApplicationsClient is the compute Client
|
||||
type GalleryApplicationsClient struct {
|
||||
BaseClient
|
||||
}
|
||||
|
||||
// NewGalleryApplicationsClient creates an instance of the GalleryApplicationsClient client.
|
||||
func NewGalleryApplicationsClient(subscriptionID string) GalleryApplicationsClient {
|
||||
return NewGalleryApplicationsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewGalleryApplicationsClientWithBaseURI creates an instance of the GalleryApplicationsClient client.
|
||||
func NewGalleryApplicationsClientWithBaseURI(baseURI string, subscriptionID string) GalleryApplicationsClient {
|
||||
return GalleryApplicationsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// CreateOrUpdate create or update a gallery Application Definition.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// galleryName - the name of the Shared Application Gallery in which the Application Definition is to be
|
||||
// created.
|
||||
// galleryApplicationName - the name of the gallery Application Definition to be created or updated. The
|
||||
// allowed characters are alphabets and numbers with dots, dashes, and periods allowed in the middle. The
|
||||
// maximum length is 80 characters.
|
||||
// galleryApplication - parameters supplied to the create or update gallery Application operation.
|
||||
func (client GalleryApplicationsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplication GalleryApplication) (result GalleryApplicationsCreateOrUpdateFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationsClient.CreateOrUpdate")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, galleryName, galleryApplicationName, galleryApplication)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "CreateOrUpdate", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
|
||||
func (client GalleryApplicationsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplication GalleryApplication) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"galleryApplicationName": autorest.Encode("path", galleryApplicationName),
|
||||
"galleryName": autorest.Encode("path", galleryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/applications/{galleryApplicationName}", pathParameters),
|
||||
autorest.WithJSON(galleryApplication),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client GalleryApplicationsClient) CreateOrUpdateSender(req *http.Request) (future GalleryApplicationsCreateOrUpdateFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client GalleryApplicationsClient) CreateOrUpdateResponder(resp *http.Response) (result GalleryApplication, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// Delete delete a gallery Application.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// galleryName - the name of the Shared Application Gallery in which the Application Definition is to be
|
||||
// deleted.
|
||||
// galleryApplicationName - the name of the gallery Application Definition to be deleted.
|
||||
func (client GalleryApplicationsClient) Delete(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string) (result GalleryApplicationsDeleteFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationsClient.Delete")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.DeletePreparer(ctx, resourceGroupName, galleryName, galleryApplicationName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Delete", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Delete", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// DeletePreparer prepares the Delete request.
|
||||
func (client GalleryApplicationsClient) DeletePreparer(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"galleryApplicationName": autorest.Encode("path", galleryApplicationName),
|
||||
"galleryName": autorest.Encode("path", galleryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsDelete(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/applications/{galleryApplicationName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// DeleteSender sends the Delete request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client GalleryApplicationsClient) DeleteSender(req *http.Request) (future GalleryApplicationsDeleteFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// DeleteResponder handles the response to the Delete request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client GalleryApplicationsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
|
||||
autorest.ByClosing())
|
||||
result.Response = resp
|
||||
return
|
||||
}
|
||||
|
||||
// Get retrieves information about a gallery Application Definition.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// galleryName - the name of the Shared Application Gallery from which the Application Definitions are to be
|
||||
// retrieved.
|
||||
// galleryApplicationName - the name of the gallery Application Definition to be retrieved.
|
||||
func (client GalleryApplicationsClient) Get(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string) (result GalleryApplication, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationsClient.Get")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.GetPreparer(ctx, resourceGroupName, galleryName, galleryApplicationName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Get", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.GetSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Get", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Get", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// GetPreparer prepares the Get request.
|
||||
func (client GalleryApplicationsClient) GetPreparer(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"galleryApplicationName": autorest.Encode("path", galleryApplicationName),
|
||||
"galleryName": autorest.Encode("path", galleryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/applications/{galleryApplicationName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// GetSender sends the Get request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client GalleryApplicationsClient) GetSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// GetResponder handles the response to the Get request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client GalleryApplicationsClient) GetResponder(resp *http.Response) (result GalleryApplication, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// ListByGallery list gallery Application Definitions in a gallery.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// galleryName - the name of the Shared Application Gallery from which Application Definitions are to be
|
||||
// listed.
|
||||
func (client GalleryApplicationsClient) ListByGallery(ctx context.Context, resourceGroupName string, galleryName string) (result GalleryApplicationListPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationsClient.ListByGallery")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.gal.Response.Response != nil {
|
||||
sc = result.gal.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listByGalleryNextResults
|
||||
req, err := client.ListByGalleryPreparer(ctx, resourceGroupName, galleryName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "ListByGallery", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListByGallerySender(req)
|
||||
if err != nil {
|
||||
result.gal.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "ListByGallery", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.gal, err = client.ListByGalleryResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "ListByGallery", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListByGalleryPreparer prepares the ListByGallery request.
|
||||
func (client GalleryApplicationsClient) ListByGalleryPreparer(ctx context.Context, resourceGroupName string, galleryName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"galleryName": autorest.Encode("path", galleryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/applications", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListByGallerySender sends the ListByGallery request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client GalleryApplicationsClient) ListByGallerySender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListByGalleryResponder handles the response to the ListByGallery request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client GalleryApplicationsClient) ListByGalleryResponder(resp *http.Response) (result GalleryApplicationList, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listByGalleryNextResults retrieves the next set of results, if any.
|
||||
func (client GalleryApplicationsClient) listByGalleryNextResults(ctx context.Context, lastResults GalleryApplicationList) (result GalleryApplicationList, err error) {
|
||||
req, err := lastResults.galleryApplicationListPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "listByGalleryNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListByGallerySender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "listByGalleryNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListByGalleryResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "listByGalleryNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListByGalleryComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client GalleryApplicationsClient) ListByGalleryComplete(ctx context.Context, resourceGroupName string, galleryName string) (result GalleryApplicationListIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationsClient.ListByGallery")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.ListByGallery(ctx, resourceGroupName, galleryName)
|
||||
return
|
||||
}
|
@ -1,428 +0,0 @@
|
||||
package compute
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/autorest/validation"
|
||||
"github.com/Azure/go-autorest/tracing"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// GalleryApplicationVersionsClient is the compute Client
|
||||
type GalleryApplicationVersionsClient struct {
|
||||
BaseClient
|
||||
}
|
||||
|
||||
// NewGalleryApplicationVersionsClient creates an instance of the GalleryApplicationVersionsClient client.
|
||||
func NewGalleryApplicationVersionsClient(subscriptionID string) GalleryApplicationVersionsClient {
|
||||
return NewGalleryApplicationVersionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewGalleryApplicationVersionsClientWithBaseURI creates an instance of the GalleryApplicationVersionsClient client.
|
||||
func NewGalleryApplicationVersionsClientWithBaseURI(baseURI string, subscriptionID string) GalleryApplicationVersionsClient {
|
||||
return GalleryApplicationVersionsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// CreateOrUpdate create or update a gallery Application Version.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// galleryName - the name of the Shared Application Gallery in which the Application Definition resides.
|
||||
// galleryApplicationName - the name of the gallery Application Definition in which the Application Version is
|
||||
// to be created.
|
||||
// galleryApplicationVersionName - the name of the gallery Application Version to be created. Needs to follow
|
||||
// semantic version name pattern: The allowed characters are digit and period. Digits must be within the range
|
||||
// of a 32-bit integer. Format: <MajorVersion>.<MinorVersion>.<Patch>
|
||||
// galleryApplicationVersion - parameters supplied to the create or update gallery Application Version
|
||||
// operation.
|
||||
func (client GalleryApplicationVersionsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplicationVersionName string, galleryApplicationVersion GalleryApplicationVersion) (result GalleryApplicationVersionsCreateOrUpdateFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationVersionsClient.CreateOrUpdate")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: galleryApplicationVersion,
|
||||
Constraints: []validation.Constraint{{Target: "galleryApplicationVersion.GalleryApplicationVersionProperties", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "galleryApplicationVersion.GalleryApplicationVersionProperties.PublishingProfile", Name: validation.Null, Rule: true,
|
||||
Chain: []validation.Constraint{{Target: "galleryApplicationVersion.GalleryApplicationVersionProperties.PublishingProfile.Source", Name: validation.Null, Rule: true,
|
||||
Chain: []validation.Constraint{{Target: "galleryApplicationVersion.GalleryApplicationVersionProperties.PublishingProfile.Source.FileName", Name: validation.Null, Rule: true, Chain: nil},
|
||||
{Target: "galleryApplicationVersion.GalleryApplicationVersionProperties.PublishingProfile.Source.MediaLink", Name: validation.Null, Rule: true, Chain: nil},
|
||||
}},
|
||||
}},
|
||||
}}}}}); err != nil {
|
||||
return result, validation.NewError("compute.GalleryApplicationVersionsClient", "CreateOrUpdate", err.Error())
|
||||
}
|
||||
|
||||
req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, galleryName, galleryApplicationName, galleryApplicationVersionName, galleryApplicationVersion)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "CreateOrUpdate", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
|
||||
func (client GalleryApplicationVersionsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplicationVersionName string, galleryApplicationVersion GalleryApplicationVersion) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"galleryApplicationName": autorest.Encode("path", galleryApplicationName),
|
||||
"galleryApplicationVersionName": autorest.Encode("path", galleryApplicationVersionName),
|
||||
"galleryName": autorest.Encode("path", galleryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/applications/{galleryApplicationName}/versions/{galleryApplicationVersionName}", pathParameters),
|
||||
autorest.WithJSON(galleryApplicationVersion),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client GalleryApplicationVersionsClient) CreateOrUpdateSender(req *http.Request) (future GalleryApplicationVersionsCreateOrUpdateFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client GalleryApplicationVersionsClient) CreateOrUpdateResponder(resp *http.Response) (result GalleryApplicationVersion, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// Delete delete a gallery Application Version.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// galleryName - the name of the Shared Application Gallery in which the Application Definition resides.
|
||||
// galleryApplicationName - the name of the gallery Application Definition in which the Application Version
|
||||
// resides.
|
||||
// galleryApplicationVersionName - the name of the gallery Application Version to be deleted.
|
||||
func (client GalleryApplicationVersionsClient) Delete(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplicationVersionName string) (result GalleryApplicationVersionsDeleteFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationVersionsClient.Delete")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.DeletePreparer(ctx, resourceGroupName, galleryName, galleryApplicationName, galleryApplicationVersionName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Delete", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Delete", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// DeletePreparer prepares the Delete request.
|
||||
func (client GalleryApplicationVersionsClient) DeletePreparer(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplicationVersionName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"galleryApplicationName": autorest.Encode("path", galleryApplicationName),
|
||||
"galleryApplicationVersionName": autorest.Encode("path", galleryApplicationVersionName),
|
||||
"galleryName": autorest.Encode("path", galleryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsDelete(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/applications/{galleryApplicationName}/versions/{galleryApplicationVersionName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// DeleteSender sends the Delete request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client GalleryApplicationVersionsClient) DeleteSender(req *http.Request) (future GalleryApplicationVersionsDeleteFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// DeleteResponder handles the response to the Delete request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client GalleryApplicationVersionsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
|
||||
autorest.ByClosing())
|
||||
result.Response = resp
|
||||
return
|
||||
}
|
||||
|
||||
// Get retrieves information about a gallery Application Version.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// galleryName - the name of the Shared Application Gallery in which the Application Definition resides.
|
||||
// galleryApplicationName - the name of the gallery Application Definition in which the Application Version
|
||||
// resides.
|
||||
// galleryApplicationVersionName - the name of the gallery Application Version to be retrieved.
|
||||
// expand - the expand expression to apply on the operation.
|
||||
func (client GalleryApplicationVersionsClient) Get(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplicationVersionName string, expand ReplicationStatusTypes) (result GalleryApplicationVersion, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationVersionsClient.Get")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.GetPreparer(ctx, resourceGroupName, galleryName, galleryApplicationName, galleryApplicationVersionName, expand)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Get", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.GetSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Get", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Get", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// GetPreparer prepares the Get request.
|
||||
func (client GalleryApplicationVersionsClient) GetPreparer(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplicationVersionName string, expand ReplicationStatusTypes) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"galleryApplicationName": autorest.Encode("path", galleryApplicationName),
|
||||
"galleryApplicationVersionName": autorest.Encode("path", galleryApplicationVersionName),
|
||||
"galleryName": autorest.Encode("path", galleryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
if len(string(expand)) > 0 {
|
||||
queryParameters["$expand"] = autorest.Encode("query", expand)
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/applications/{galleryApplicationName}/versions/{galleryApplicationVersionName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// GetSender sends the Get request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client GalleryApplicationVersionsClient) GetSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// GetResponder handles the response to the Get request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client GalleryApplicationVersionsClient) GetResponder(resp *http.Response) (result GalleryApplicationVersion, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// ListByGalleryApplication list gallery Application Versions in a gallery Application Definition.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// galleryName - the name of the Shared Application Gallery in which the Application Definition resides.
|
||||
// galleryApplicationName - the name of the Shared Application Gallery Application Definition from which the
|
||||
// Application Versions are to be listed.
|
||||
func (client GalleryApplicationVersionsClient) ListByGalleryApplication(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string) (result GalleryApplicationVersionListPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationVersionsClient.ListByGalleryApplication")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.gavl.Response.Response != nil {
|
||||
sc = result.gavl.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listByGalleryApplicationNextResults
|
||||
req, err := client.ListByGalleryApplicationPreparer(ctx, resourceGroupName, galleryName, galleryApplicationName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "ListByGalleryApplication", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListByGalleryApplicationSender(req)
|
||||
if err != nil {
|
||||
result.gavl.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "ListByGalleryApplication", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.gavl, err = client.ListByGalleryApplicationResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "ListByGalleryApplication", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListByGalleryApplicationPreparer prepares the ListByGalleryApplication request.
|
||||
func (client GalleryApplicationVersionsClient) ListByGalleryApplicationPreparer(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"galleryApplicationName": autorest.Encode("path", galleryApplicationName),
|
||||
"galleryName": autorest.Encode("path", galleryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/applications/{galleryApplicationName}/versions", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListByGalleryApplicationSender sends the ListByGalleryApplication request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client GalleryApplicationVersionsClient) ListByGalleryApplicationSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListByGalleryApplicationResponder handles the response to the ListByGalleryApplication request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client GalleryApplicationVersionsClient) ListByGalleryApplicationResponder(resp *http.Response) (result GalleryApplicationVersionList, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listByGalleryApplicationNextResults retrieves the next set of results, if any.
|
||||
func (client GalleryApplicationVersionsClient) listByGalleryApplicationNextResults(ctx context.Context, lastResults GalleryApplicationVersionList) (result GalleryApplicationVersionList, err error) {
|
||||
req, err := lastResults.galleryApplicationVersionListPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "listByGalleryApplicationNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListByGalleryApplicationSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "listByGalleryApplicationNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListByGalleryApplicationResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "listByGalleryApplicationNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListByGalleryApplicationComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client GalleryApplicationVersionsClient) ListByGalleryApplicationComplete(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string) (result GalleryApplicationVersionListIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationVersionsClient.ListByGalleryApplication")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.ListByGalleryApplication(ctx, resourceGroupName, galleryName, galleryApplicationName)
|
||||
return
|
||||
}
|
@ -10,8 +10,6 @@ go_library(
|
||||
"dedicatedhosts.go",
|
||||
"disks.go",
|
||||
"galleries.go",
|
||||
"galleryapplications.go",
|
||||
"galleryapplicationversions.go",
|
||||
"galleryimages.go",
|
||||
"galleryimageversions.go",
|
||||
"images.go",
|
||||
@ -34,8 +32,8 @@ go_library(
|
||||
"virtualmachinescalesetvms.go",
|
||||
"virtualmachinesizes.go",
|
||||
],
|
||||
importmap = "k8s.io/kubernetes/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-03-01/compute",
|
||||
importpath = "github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-03-01/compute",
|
||||
importmap = "k8s.io/kubernetes/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute",
|
||||
importpath = "github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute",
|
||||
visibility = ["//visibility:public"],
|
||||
deps = [
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/version:go_default_library",
|
@ -80,7 +80,7 @@ func (client GalleriesClient) CreateOrUpdatePreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -159,7 +159,7 @@ func (client GalleriesClient) DeletePreparer(ctx context.Context, resourceGroupN
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -241,7 +241,7 @@ func (client GalleriesClient) GetPreparer(ctx context.Context, resourceGroupName
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -314,7 +314,7 @@ func (client GalleriesClient) ListPreparer(ctx context.Context) (*http.Request,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -427,7 +427,7 @@ func (client GalleriesClient) ListByResourceGroupPreparer(ctx context.Context, r
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -96,7 +96,7 @@ func (client GalleryImagesClient) CreateOrUpdatePreparer(ctx context.Context, re
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -177,7 +177,7 @@ func (client GalleryImagesClient) DeletePreparer(ctx context.Context, resourceGr
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -261,7 +261,7 @@ func (client GalleryImagesClient) GetPreparer(ctx context.Context, resourceGroup
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -339,7 +339,7 @@ func (client GalleryImagesClient) ListByGalleryPreparer(ctx context.Context, res
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -64,11 +64,9 @@ func (client GalleryImageVersionsClient) CreateOrUpdate(ctx context.Context, res
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: galleryImageVersion,
|
||||
Constraints: []validation.Constraint{{Target: "galleryImageVersion.GalleryImageVersionProperties", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "galleryImageVersion.GalleryImageVersionProperties.PublishingProfile", Name: validation.Null, Rule: true,
|
||||
Chain: []validation.Constraint{{Target: "galleryImageVersion.GalleryImageVersionProperties.PublishingProfile.Source", Name: validation.Null, Rule: true,
|
||||
Chain: []validation.Constraint{{Target: "galleryImageVersion.GalleryImageVersionProperties.PublishingProfile.Source.ManagedImage", Name: validation.Null, Rule: true,
|
||||
Chain: []validation.Constraint{{Target: "galleryImageVersion.GalleryImageVersionProperties.PublishingProfile.Source.ManagedImage.ID", Name: validation.Null, Rule: true, Chain: nil}}},
|
||||
}},
|
||||
Chain: []validation.Constraint{{Target: "galleryImageVersion.GalleryImageVersionProperties.StorageProfile", Name: validation.Null, Rule: true,
|
||||
Chain: []validation.Constraint{{Target: "galleryImageVersion.GalleryImageVersionProperties.StorageProfile.Source", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "galleryImageVersion.GalleryImageVersionProperties.StorageProfile.Source.ID", Name: validation.Null, Rule: true, Chain: nil}}},
|
||||
}},
|
||||
}}}}}); err != nil {
|
||||
return result, validation.NewError("compute.GalleryImageVersionsClient", "CreateOrUpdate", err.Error())
|
||||
@ -99,7 +97,7 @@ func (client GalleryImageVersionsClient) CreateOrUpdatePreparer(ctx context.Cont
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -182,7 +180,7 @@ func (client GalleryImageVersionsClient) DeletePreparer(ctx context.Context, res
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -269,7 +267,7 @@ func (client GalleryImageVersionsClient) GetPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -353,7 +351,7 @@ func (client GalleryImageVersionsClient) ListByGalleryImagePreparer(ctx context.
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-03-01"
|
||||
const APIVersion = "2019-07-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -29,7 +29,7 @@ import (
|
||||
)
|
||||
|
||||
// The package's fully qualified name.
|
||||
const fqdn = "github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-03-01/compute"
|
||||
const fqdn = "github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute"
|
||||
|
||||
// AccessLevel enumerates the values for access level.
|
||||
type AccessLevel string
|
||||
@ -605,29 +605,6 @@ func PossibleProvisioningState2Values() []ProvisioningState2 {
|
||||
return []ProvisioningState2{ProvisioningState2Creating, ProvisioningState2Deleting, ProvisioningState2Failed, ProvisioningState2Migrating, ProvisioningState2Succeeded, ProvisioningState2Updating}
|
||||
}
|
||||
|
||||
// ProvisioningState3 enumerates the values for provisioning state 3.
|
||||
type ProvisioningState3 string
|
||||
|
||||
const (
|
||||
// ProvisioningState3Creating ...
|
||||
ProvisioningState3Creating ProvisioningState3 = "Creating"
|
||||
// ProvisioningState3Deleting ...
|
||||
ProvisioningState3Deleting ProvisioningState3 = "Deleting"
|
||||
// ProvisioningState3Failed ...
|
||||
ProvisioningState3Failed ProvisioningState3 = "Failed"
|
||||
// ProvisioningState3Migrating ...
|
||||
ProvisioningState3Migrating ProvisioningState3 = "Migrating"
|
||||
// ProvisioningState3Succeeded ...
|
||||
ProvisioningState3Succeeded ProvisioningState3 = "Succeeded"
|
||||
// ProvisioningState3Updating ...
|
||||
ProvisioningState3Updating ProvisioningState3 = "Updating"
|
||||
)
|
||||
|
||||
// PossibleProvisioningState3Values returns an array of possible values for the ProvisioningState3 const type.
|
||||
func PossibleProvisioningState3Values() []ProvisioningState3 {
|
||||
return []ProvisioningState3{ProvisioningState3Creating, ProvisioningState3Deleting, ProvisioningState3Failed, ProvisioningState3Migrating, ProvisioningState3Succeeded, ProvisioningState3Updating}
|
||||
}
|
||||
|
||||
// ProximityPlacementGroupType enumerates the values for proximity placement group type.
|
||||
type ProximityPlacementGroupType string
|
||||
|
||||
@ -3707,688 +3684,36 @@ func (g *Gallery) UnmarshalJSON(body []byte) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// GalleryApplication specifies information about the gallery Application Definition that you want to
|
||||
// create or update.
|
||||
type GalleryApplication struct {
|
||||
autorest.Response `json:"-"`
|
||||
*GalleryApplicationProperties `json:"properties,omitempty"`
|
||||
// ID - READ-ONLY; Resource Id
|
||||
ID *string `json:"id,omitempty"`
|
||||
// Name - READ-ONLY; Resource name
|
||||
Name *string `json:"name,omitempty"`
|
||||
// Type - READ-ONLY; Resource type
|
||||
Type *string `json:"type,omitempty"`
|
||||
// Location - Resource location
|
||||
Location *string `json:"location,omitempty"`
|
||||
// Tags - Resource tags
|
||||
Tags map[string]*string `json:"tags"`
|
||||
}
|
||||
|
||||
// MarshalJSON is the custom marshaler for GalleryApplication.
|
||||
func (ga GalleryApplication) MarshalJSON() ([]byte, error) {
|
||||
objectMap := make(map[string]interface{})
|
||||
if ga.GalleryApplicationProperties != nil {
|
||||
objectMap["properties"] = ga.GalleryApplicationProperties
|
||||
}
|
||||
if ga.Location != nil {
|
||||
objectMap["location"] = ga.Location
|
||||
}
|
||||
if ga.Tags != nil {
|
||||
objectMap["tags"] = ga.Tags
|
||||
}
|
||||
return json.Marshal(objectMap)
|
||||
}
|
||||
|
||||
// UnmarshalJSON is the custom unmarshaler for GalleryApplication struct.
|
||||
func (ga *GalleryApplication) UnmarshalJSON(body []byte) error {
|
||||
var m map[string]*json.RawMessage
|
||||
err := json.Unmarshal(body, &m)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
for k, v := range m {
|
||||
switch k {
|
||||
case "properties":
|
||||
if v != nil {
|
||||
var galleryApplicationProperties GalleryApplicationProperties
|
||||
err = json.Unmarshal(*v, &galleryApplicationProperties)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
ga.GalleryApplicationProperties = &galleryApplicationProperties
|
||||
}
|
||||
case "id":
|
||||
if v != nil {
|
||||
var ID string
|
||||
err = json.Unmarshal(*v, &ID)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
ga.ID = &ID
|
||||
}
|
||||
case "name":
|
||||
if v != nil {
|
||||
var name string
|
||||
err = json.Unmarshal(*v, &name)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
ga.Name = &name
|
||||
}
|
||||
case "type":
|
||||
if v != nil {
|
||||
var typeVar string
|
||||
err = json.Unmarshal(*v, &typeVar)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
ga.Type = &typeVar
|
||||
}
|
||||
case "location":
|
||||
if v != nil {
|
||||
var location string
|
||||
err = json.Unmarshal(*v, &location)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
ga.Location = &location
|
||||
}
|
||||
case "tags":
|
||||
if v != nil {
|
||||
var tags map[string]*string
|
||||
err = json.Unmarshal(*v, &tags)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
ga.Tags = tags
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
// GalleryApplicationList the List Gallery Applications operation response.
|
||||
type GalleryApplicationList struct {
|
||||
autorest.Response `json:"-"`
|
||||
// Value - A list of Gallery Applications.
|
||||
Value *[]GalleryApplication `json:"value,omitempty"`
|
||||
// NextLink - The uri to fetch the next page of Application Definitions in the Application Gallery. Call ListNext() with this to fetch the next page of gallery Application Definitions.
|
||||
NextLink *string `json:"nextLink,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryApplicationListIterator provides access to a complete listing of GalleryApplication values.
|
||||
type GalleryApplicationListIterator struct {
|
||||
i int
|
||||
page GalleryApplicationListPage
|
||||
}
|
||||
|
||||
// NextWithContext advances to the next value. If there was an error making
|
||||
// the request the iterator does not advance and the error is returned.
|
||||
func (iter *GalleryApplicationListIterator) NextWithContext(ctx context.Context) (err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationListIterator.NextWithContext")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if iter.Response().Response.Response != nil {
|
||||
sc = iter.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
iter.i++
|
||||
if iter.i < len(iter.page.Values()) {
|
||||
return nil
|
||||
}
|
||||
err = iter.page.NextWithContext(ctx)
|
||||
if err != nil {
|
||||
iter.i--
|
||||
return err
|
||||
}
|
||||
iter.i = 0
|
||||
return nil
|
||||
}
|
||||
|
||||
// Next advances to the next value. If there was an error making
|
||||
// the request the iterator does not advance and the error is returned.
|
||||
// Deprecated: Use NextWithContext() instead.
|
||||
func (iter *GalleryApplicationListIterator) Next() error {
|
||||
return iter.NextWithContext(context.Background())
|
||||
}
|
||||
|
||||
// NotDone returns true if the enumeration should be started or is not yet complete.
|
||||
func (iter GalleryApplicationListIterator) NotDone() bool {
|
||||
return iter.page.NotDone() && iter.i < len(iter.page.Values())
|
||||
}
|
||||
|
||||
// Response returns the raw server response from the last page request.
|
||||
func (iter GalleryApplicationListIterator) Response() GalleryApplicationList {
|
||||
return iter.page.Response()
|
||||
}
|
||||
|
||||
// Value returns the current value or a zero-initialized value if the
|
||||
// iterator has advanced beyond the end of the collection.
|
||||
func (iter GalleryApplicationListIterator) Value() GalleryApplication {
|
||||
if !iter.page.NotDone() {
|
||||
return GalleryApplication{}
|
||||
}
|
||||
return iter.page.Values()[iter.i]
|
||||
}
|
||||
|
||||
// Creates a new instance of the GalleryApplicationListIterator type.
|
||||
func NewGalleryApplicationListIterator(page GalleryApplicationListPage) GalleryApplicationListIterator {
|
||||
return GalleryApplicationListIterator{page: page}
|
||||
}
|
||||
|
||||
// IsEmpty returns true if the ListResult contains no values.
|
||||
func (gal GalleryApplicationList) IsEmpty() bool {
|
||||
return gal.Value == nil || len(*gal.Value) == 0
|
||||
}
|
||||
|
||||
// galleryApplicationListPreparer prepares a request to retrieve the next set of results.
|
||||
// It returns nil if no more results exist.
|
||||
func (gal GalleryApplicationList) galleryApplicationListPreparer(ctx context.Context) (*http.Request, error) {
|
||||
if gal.NextLink == nil || len(to.String(gal.NextLink)) < 1 {
|
||||
return nil, nil
|
||||
}
|
||||
return autorest.Prepare((&http.Request{}).WithContext(ctx),
|
||||
autorest.AsJSON(),
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(to.String(gal.NextLink)))
|
||||
}
|
||||
|
||||
// GalleryApplicationListPage contains a page of GalleryApplication values.
|
||||
type GalleryApplicationListPage struct {
|
||||
fn func(context.Context, GalleryApplicationList) (GalleryApplicationList, error)
|
||||
gal GalleryApplicationList
|
||||
}
|
||||
|
||||
// NextWithContext advances to the next page of values. If there was an error making
|
||||
// the request the page does not advance and the error is returned.
|
||||
func (page *GalleryApplicationListPage) NextWithContext(ctx context.Context) (err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationListPage.NextWithContext")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if page.Response().Response.Response != nil {
|
||||
sc = page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.gal)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.gal = next
|
||||
return nil
|
||||
}
|
||||
|
||||
// Next advances to the next page of values. If there was an error making
|
||||
// the request the page does not advance and the error is returned.
|
||||
// Deprecated: Use NextWithContext() instead.
|
||||
func (page *GalleryApplicationListPage) Next() error {
|
||||
return page.NextWithContext(context.Background())
|
||||
}
|
||||
|
||||
// NotDone returns true if the page enumeration should be started or is not yet complete.
|
||||
func (page GalleryApplicationListPage) NotDone() bool {
|
||||
return !page.gal.IsEmpty()
|
||||
}
|
||||
|
||||
// Response returns the raw server response from the last page request.
|
||||
func (page GalleryApplicationListPage) Response() GalleryApplicationList {
|
||||
return page.gal
|
||||
}
|
||||
|
||||
// Values returns the slice of values for the current page or nil if there are no values.
|
||||
func (page GalleryApplicationListPage) Values() []GalleryApplication {
|
||||
if page.gal.IsEmpty() {
|
||||
return nil
|
||||
}
|
||||
return *page.gal.Value
|
||||
}
|
||||
|
||||
// Creates a new instance of the GalleryApplicationListPage type.
|
||||
func NewGalleryApplicationListPage(getNextPage func(context.Context, GalleryApplicationList) (GalleryApplicationList, error)) GalleryApplicationListPage {
|
||||
return GalleryApplicationListPage{fn: getNextPage}
|
||||
}
|
||||
|
||||
// GalleryApplicationProperties describes the properties of a gallery Application Definition.
|
||||
type GalleryApplicationProperties struct {
|
||||
// Description - The description of this gallery Application Definition resource. This property is updatable.
|
||||
Description *string `json:"description,omitempty"`
|
||||
// Eula - The Eula agreement for the gallery Application Definition.
|
||||
Eula *string `json:"eula,omitempty"`
|
||||
// PrivacyStatementURI - The privacy statement uri.
|
||||
PrivacyStatementURI *string `json:"privacyStatementUri,omitempty"`
|
||||
// ReleaseNoteURI - The release note uri.
|
||||
ReleaseNoteURI *string `json:"releaseNoteUri,omitempty"`
|
||||
// EndOfLifeDate - The end of life date of the gallery Application Definition. This property can be used for decommissioning purposes. This property is updatable.
|
||||
EndOfLifeDate *date.Time `json:"endOfLifeDate,omitempty"`
|
||||
// SupportedOSType - This property allows you to specify the supported type of the OS that application is built for. <br><br> Possible values are: <br><br> **Windows** <br><br> **Linux**. Possible values include: 'Windows', 'Linux'
|
||||
SupportedOSType OperatingSystemTypes `json:"supportedOSType,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryApplicationsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
|
||||
// long-running operation.
|
||||
type GalleryApplicationsCreateOrUpdateFuture struct {
|
||||
azure.Future
|
||||
}
|
||||
|
||||
// Result returns the result of the asynchronous operation.
|
||||
// If the operation has not completed it will return an error.
|
||||
func (future *GalleryApplicationsCreateOrUpdateFuture) Result(client GalleryApplicationsClient) (ga GalleryApplication, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if ga.Response.Response, err = future.GetResult(sender); err == nil && ga.Response.Response.StatusCode != http.StatusNoContent {
|
||||
ga, err = client.CreateOrUpdateResponder(ga.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsCreateOrUpdateFuture", "Result", ga.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// GalleryApplicationsDeleteFuture an abstraction for monitoring and retrieving the results of a
|
||||
// long-running operation.
|
||||
type GalleryApplicationsDeleteFuture struct {
|
||||
azure.Future
|
||||
}
|
||||
|
||||
// Result returns the result of the asynchronous operation.
|
||||
// If the operation has not completed it will return an error.
|
||||
func (future *GalleryApplicationsDeleteFuture) Result(client GalleryApplicationsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
|
||||
// GalleryApplicationVersion specifies information about the gallery Application Version that you want to
|
||||
// create or update.
|
||||
type GalleryApplicationVersion struct {
|
||||
autorest.Response `json:"-"`
|
||||
*GalleryApplicationVersionProperties `json:"properties,omitempty"`
|
||||
// ID - READ-ONLY; Resource Id
|
||||
ID *string `json:"id,omitempty"`
|
||||
// Name - READ-ONLY; Resource name
|
||||
Name *string `json:"name,omitempty"`
|
||||
// Type - READ-ONLY; Resource type
|
||||
Type *string `json:"type,omitempty"`
|
||||
// Location - Resource location
|
||||
Location *string `json:"location,omitempty"`
|
||||
// Tags - Resource tags
|
||||
Tags map[string]*string `json:"tags"`
|
||||
}
|
||||
|
||||
// MarshalJSON is the custom marshaler for GalleryApplicationVersion.
|
||||
func (gav GalleryApplicationVersion) MarshalJSON() ([]byte, error) {
|
||||
objectMap := make(map[string]interface{})
|
||||
if gav.GalleryApplicationVersionProperties != nil {
|
||||
objectMap["properties"] = gav.GalleryApplicationVersionProperties
|
||||
}
|
||||
if gav.Location != nil {
|
||||
objectMap["location"] = gav.Location
|
||||
}
|
||||
if gav.Tags != nil {
|
||||
objectMap["tags"] = gav.Tags
|
||||
}
|
||||
return json.Marshal(objectMap)
|
||||
}
|
||||
|
||||
// UnmarshalJSON is the custom unmarshaler for GalleryApplicationVersion struct.
|
||||
func (gav *GalleryApplicationVersion) UnmarshalJSON(body []byte) error {
|
||||
var m map[string]*json.RawMessage
|
||||
err := json.Unmarshal(body, &m)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
for k, v := range m {
|
||||
switch k {
|
||||
case "properties":
|
||||
if v != nil {
|
||||
var galleryApplicationVersionProperties GalleryApplicationVersionProperties
|
||||
err = json.Unmarshal(*v, &galleryApplicationVersionProperties)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
gav.GalleryApplicationVersionProperties = &galleryApplicationVersionProperties
|
||||
}
|
||||
case "id":
|
||||
if v != nil {
|
||||
var ID string
|
||||
err = json.Unmarshal(*v, &ID)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
gav.ID = &ID
|
||||
}
|
||||
case "name":
|
||||
if v != nil {
|
||||
var name string
|
||||
err = json.Unmarshal(*v, &name)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
gav.Name = &name
|
||||
}
|
||||
case "type":
|
||||
if v != nil {
|
||||
var typeVar string
|
||||
err = json.Unmarshal(*v, &typeVar)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
gav.Type = &typeVar
|
||||
}
|
||||
case "location":
|
||||
if v != nil {
|
||||
var location string
|
||||
err = json.Unmarshal(*v, &location)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
gav.Location = &location
|
||||
}
|
||||
case "tags":
|
||||
if v != nil {
|
||||
var tags map[string]*string
|
||||
err = json.Unmarshal(*v, &tags)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
gav.Tags = tags
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
// GalleryApplicationVersionList the List Gallery Application version operation response.
|
||||
type GalleryApplicationVersionList struct {
|
||||
autorest.Response `json:"-"`
|
||||
// Value - A list of gallery Application Versions.
|
||||
Value *[]GalleryApplicationVersion `json:"value,omitempty"`
|
||||
// NextLink - The uri to fetch the next page of gallery Application Versions. Call ListNext() with this to fetch the next page of gallery Application Versions.
|
||||
NextLink *string `json:"nextLink,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryApplicationVersionListIterator provides access to a complete listing of GalleryApplicationVersion
|
||||
// values.
|
||||
type GalleryApplicationVersionListIterator struct {
|
||||
i int
|
||||
page GalleryApplicationVersionListPage
|
||||
}
|
||||
|
||||
// NextWithContext advances to the next value. If there was an error making
|
||||
// the request the iterator does not advance and the error is returned.
|
||||
func (iter *GalleryApplicationVersionListIterator) NextWithContext(ctx context.Context) (err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationVersionListIterator.NextWithContext")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if iter.Response().Response.Response != nil {
|
||||
sc = iter.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
iter.i++
|
||||
if iter.i < len(iter.page.Values()) {
|
||||
return nil
|
||||
}
|
||||
err = iter.page.NextWithContext(ctx)
|
||||
if err != nil {
|
||||
iter.i--
|
||||
return err
|
||||
}
|
||||
iter.i = 0
|
||||
return nil
|
||||
}
|
||||
|
||||
// Next advances to the next value. If there was an error making
|
||||
// the request the iterator does not advance and the error is returned.
|
||||
// Deprecated: Use NextWithContext() instead.
|
||||
func (iter *GalleryApplicationVersionListIterator) Next() error {
|
||||
return iter.NextWithContext(context.Background())
|
||||
}
|
||||
|
||||
// NotDone returns true if the enumeration should be started or is not yet complete.
|
||||
func (iter GalleryApplicationVersionListIterator) NotDone() bool {
|
||||
return iter.page.NotDone() && iter.i < len(iter.page.Values())
|
||||
}
|
||||
|
||||
// Response returns the raw server response from the last page request.
|
||||
func (iter GalleryApplicationVersionListIterator) Response() GalleryApplicationVersionList {
|
||||
return iter.page.Response()
|
||||
}
|
||||
|
||||
// Value returns the current value or a zero-initialized value if the
|
||||
// iterator has advanced beyond the end of the collection.
|
||||
func (iter GalleryApplicationVersionListIterator) Value() GalleryApplicationVersion {
|
||||
if !iter.page.NotDone() {
|
||||
return GalleryApplicationVersion{}
|
||||
}
|
||||
return iter.page.Values()[iter.i]
|
||||
}
|
||||
|
||||
// Creates a new instance of the GalleryApplicationVersionListIterator type.
|
||||
func NewGalleryApplicationVersionListIterator(page GalleryApplicationVersionListPage) GalleryApplicationVersionListIterator {
|
||||
return GalleryApplicationVersionListIterator{page: page}
|
||||
}
|
||||
|
||||
// IsEmpty returns true if the ListResult contains no values.
|
||||
func (gavl GalleryApplicationVersionList) IsEmpty() bool {
|
||||
return gavl.Value == nil || len(*gavl.Value) == 0
|
||||
}
|
||||
|
||||
// galleryApplicationVersionListPreparer prepares a request to retrieve the next set of results.
|
||||
// It returns nil if no more results exist.
|
||||
func (gavl GalleryApplicationVersionList) galleryApplicationVersionListPreparer(ctx context.Context) (*http.Request, error) {
|
||||
if gavl.NextLink == nil || len(to.String(gavl.NextLink)) < 1 {
|
||||
return nil, nil
|
||||
}
|
||||
return autorest.Prepare((&http.Request{}).WithContext(ctx),
|
||||
autorest.AsJSON(),
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(to.String(gavl.NextLink)))
|
||||
}
|
||||
|
||||
// GalleryApplicationVersionListPage contains a page of GalleryApplicationVersion values.
|
||||
type GalleryApplicationVersionListPage struct {
|
||||
fn func(context.Context, GalleryApplicationVersionList) (GalleryApplicationVersionList, error)
|
||||
gavl GalleryApplicationVersionList
|
||||
}
|
||||
|
||||
// NextWithContext advances to the next page of values. If there was an error making
|
||||
// the request the page does not advance and the error is returned.
|
||||
func (page *GalleryApplicationVersionListPage) NextWithContext(ctx context.Context) (err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/GalleryApplicationVersionListPage.NextWithContext")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if page.Response().Response.Response != nil {
|
||||
sc = page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.gavl)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.gavl = next
|
||||
return nil
|
||||
}
|
||||
|
||||
// Next advances to the next page of values. If there was an error making
|
||||
// the request the page does not advance and the error is returned.
|
||||
// Deprecated: Use NextWithContext() instead.
|
||||
func (page *GalleryApplicationVersionListPage) Next() error {
|
||||
return page.NextWithContext(context.Background())
|
||||
}
|
||||
|
||||
// NotDone returns true if the page enumeration should be started or is not yet complete.
|
||||
func (page GalleryApplicationVersionListPage) NotDone() bool {
|
||||
return !page.gavl.IsEmpty()
|
||||
}
|
||||
|
||||
// Response returns the raw server response from the last page request.
|
||||
func (page GalleryApplicationVersionListPage) Response() GalleryApplicationVersionList {
|
||||
return page.gavl
|
||||
}
|
||||
|
||||
// Values returns the slice of values for the current page or nil if there are no values.
|
||||
func (page GalleryApplicationVersionListPage) Values() []GalleryApplicationVersion {
|
||||
if page.gavl.IsEmpty() {
|
||||
return nil
|
||||
}
|
||||
return *page.gavl.Value
|
||||
}
|
||||
|
||||
// Creates a new instance of the GalleryApplicationVersionListPage type.
|
||||
func NewGalleryApplicationVersionListPage(getNextPage func(context.Context, GalleryApplicationVersionList) (GalleryApplicationVersionList, error)) GalleryApplicationVersionListPage {
|
||||
return GalleryApplicationVersionListPage{fn: getNextPage}
|
||||
}
|
||||
|
||||
// GalleryApplicationVersionProperties describes the properties of a gallery Image Version.
|
||||
type GalleryApplicationVersionProperties struct {
|
||||
PublishingProfile *GalleryApplicationVersionPublishingProfile `json:"publishingProfile,omitempty"`
|
||||
// ProvisioningState - READ-ONLY; The provisioning state, which only appears in the response. Possible values include: 'ProvisioningState1Creating', 'ProvisioningState1Updating', 'ProvisioningState1Failed', 'ProvisioningState1Succeeded', 'ProvisioningState1Deleting', 'ProvisioningState1Migrating'
|
||||
ProvisioningState ProvisioningState1 `json:"provisioningState,omitempty"`
|
||||
// ReplicationStatus - READ-ONLY
|
||||
ReplicationStatus *ReplicationStatus `json:"replicationStatus,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryApplicationVersionPublishingProfile the publishing profile of a gallery Image Version.
|
||||
type GalleryApplicationVersionPublishingProfile struct {
|
||||
Source *UserArtifactSource `json:"source,omitempty"`
|
||||
// ContentType - Optional. May be used to help process this file. The type of file contained in the source, e.g. zip, json, etc.
|
||||
ContentType *string `json:"contentType,omitempty"`
|
||||
// EnableHealthCheck - Optional. Whether or not this application reports health.
|
||||
EnableHealthCheck *bool `json:"enableHealthCheck,omitempty"`
|
||||
// TargetRegions - The target regions where the Image Version is going to be replicated to. This property is updatable.
|
||||
TargetRegions *[]TargetRegion `json:"targetRegions,omitempty"`
|
||||
// ReplicaCount - The number of replicas of the Image Version to be created per region. This property would take effect for a region when regionalReplicaCount is not specified. This property is updatable.
|
||||
ReplicaCount *int32 `json:"replicaCount,omitempty"`
|
||||
// ExcludeFromLatest - If set to true, Virtual Machines deployed from the latest version of the Image Definition won't use this Image Version.
|
||||
ExcludeFromLatest *bool `json:"excludeFromLatest,omitempty"`
|
||||
// PublishedDate - READ-ONLY; The timestamp for when the gallery Image Version is published.
|
||||
PublishedDate *date.Time `json:"publishedDate,omitempty"`
|
||||
// EndOfLifeDate - The end of life date of the gallery Image Version. This property can be used for decommissioning purposes. This property is updatable.
|
||||
EndOfLifeDate *date.Time `json:"endOfLifeDate,omitempty"`
|
||||
// StorageAccountType - Specifies the storage account type to be used to store the image. This property is not updatable. Possible values include: 'StorageAccountTypeStandardLRS', 'StorageAccountTypeStandardZRS'
|
||||
StorageAccountType StorageAccountType `json:"storageAccountType,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryApplicationVersionsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results
|
||||
// of a long-running operation.
|
||||
type GalleryApplicationVersionsCreateOrUpdateFuture struct {
|
||||
azure.Future
|
||||
}
|
||||
|
||||
// Result returns the result of the asynchronous operation.
|
||||
// If the operation has not completed it will return an error.
|
||||
func (future *GalleryApplicationVersionsCreateOrUpdateFuture) Result(client GalleryApplicationVersionsClient) (gav GalleryApplicationVersion, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationVersionsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if gav.Response.Response, err = future.GetResult(sender); err == nil && gav.Response.Response.StatusCode != http.StatusNoContent {
|
||||
gav, err = client.CreateOrUpdateResponder(gav.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsCreateOrUpdateFuture", "Result", gav.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// GalleryApplicationVersionsDeleteFuture an abstraction for monitoring and retrieving the results of a
|
||||
// long-running operation.
|
||||
type GalleryApplicationVersionsDeleteFuture struct {
|
||||
azure.Future
|
||||
}
|
||||
|
||||
// Result returns the result of the asynchronous operation.
|
||||
// If the operation has not completed it will return an error.
|
||||
func (future *GalleryApplicationVersionsDeleteFuture) Result(client GalleryApplicationVersionsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationVersionsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
|
||||
// GalleryArtifactPublishingProfileBase describes the basic gallery artifact publishing profile.
|
||||
type GalleryArtifactPublishingProfileBase struct {
|
||||
// TargetRegions - The target regions where the Image Version is going to be replicated to. This property is updatable.
|
||||
TargetRegions *[]TargetRegion `json:"targetRegions,omitempty"`
|
||||
// ReplicaCount - The number of replicas of the Image Version to be created per region. This property would take effect for a region when regionalReplicaCount is not specified. This property is updatable.
|
||||
ReplicaCount *int32 `json:"replicaCount,omitempty"`
|
||||
// ExcludeFromLatest - If set to true, Virtual Machines deployed from the latest version of the Image Definition won't use this Image Version.
|
||||
ExcludeFromLatest *bool `json:"excludeFromLatest,omitempty"`
|
||||
// PublishedDate - READ-ONLY; The timestamp for when the gallery Image Version is published.
|
||||
PublishedDate *date.Time `json:"publishedDate,omitempty"`
|
||||
// EndOfLifeDate - The end of life date of the gallery Image Version. This property can be used for decommissioning purposes. This property is updatable.
|
||||
EndOfLifeDate *date.Time `json:"endOfLifeDate,omitempty"`
|
||||
// StorageAccountType - Specifies the storage account type to be used to store the image. This property is not updatable. Possible values include: 'StorageAccountTypeStandardLRS', 'StorageAccountTypeStandardZRS'
|
||||
StorageAccountType StorageAccountType `json:"storageAccountType,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryArtifactSource the source image from which the Image Version is going to be created.
|
||||
type GalleryArtifactSource struct {
|
||||
ManagedImage *ManagedArtifact `json:"managedImage,omitempty"`
|
||||
// GalleryArtifactVersionSource the gallery artifact version source.
|
||||
type GalleryArtifactVersionSource struct {
|
||||
// ID - The id of the gallery artifact version source. Can specify a disk uri, snapshot uri, or user image.
|
||||
ID *string `json:"id,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryDataDiskImage this is the data disk image.
|
||||
type GalleryDataDiskImage struct {
|
||||
// Lun - READ-ONLY; This property specifies the logical unit number of the data disk. This value is used to identify data disks within the Virtual Machine and therefore must be unique for each data disk attached to the Virtual Machine.
|
||||
// Lun - This property specifies the logical unit number of the data disk. This value is used to identify data disks within the Virtual Machine and therefore must be unique for each data disk attached to the Virtual Machine.
|
||||
Lun *int32 `json:"lun,omitempty"`
|
||||
// SizeInGB - READ-ONLY; This property indicates the size of the VHD to be created.
|
||||
SizeInGB *int32 `json:"sizeInGB,omitempty"`
|
||||
// HostCaching - READ-ONLY; The host caching of the disk. Valid values are 'None', 'ReadOnly', and 'ReadWrite'. Possible values include: 'HostCachingNone', 'HostCachingReadOnly', 'HostCachingReadWrite'
|
||||
HostCaching HostCaching `json:"hostCaching,omitempty"`
|
||||
// HostCaching - The host caching of the disk. Valid values are 'None', 'ReadOnly', and 'ReadWrite'. Possible values include: 'HostCachingNone', 'HostCachingReadOnly', 'HostCachingReadWrite'
|
||||
HostCaching HostCaching `json:"hostCaching,omitempty"`
|
||||
Source *GalleryArtifactVersionSource `json:"source,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryDiskImage this is the disk image base class.
|
||||
type GalleryDiskImage struct {
|
||||
// SizeInGB - READ-ONLY; This property indicates the size of the VHD to be created.
|
||||
SizeInGB *int32 `json:"sizeInGB,omitempty"`
|
||||
// HostCaching - READ-ONLY; The host caching of the disk. Valid values are 'None', 'ReadOnly', and 'ReadWrite'. Possible values include: 'HostCachingNone', 'HostCachingReadOnly', 'HostCachingReadWrite'
|
||||
HostCaching HostCaching `json:"hostCaching,omitempty"`
|
||||
// HostCaching - The host caching of the disk. Valid values are 'None', 'ReadOnly', and 'ReadWrite'. Possible values include: 'HostCachingNone', 'HostCachingReadOnly', 'HostCachingReadWrite'
|
||||
HostCaching HostCaching `json:"hostCaching,omitempty"`
|
||||
Source *GalleryArtifactVersionSource `json:"source,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryIdentifier describes the gallery unique name.
|
||||
@ -4665,16 +3990,18 @@ type GalleryImageProperties struct {
|
||||
ReleaseNoteURI *string `json:"releaseNoteUri,omitempty"`
|
||||
// OsType - This property allows you to specify the type of the OS that is included in the disk when creating a VM from a managed image. <br><br> Possible values are: <br><br> **Windows** <br><br> **Linux**. Possible values include: 'Windows', 'Linux'
|
||||
OsType OperatingSystemTypes `json:"osType,omitempty"`
|
||||
// OsState - The allowed values for OS State are 'Generalized'. Possible values include: 'Generalized', 'Specialized'
|
||||
// OsState - This property allows the user to specify whether the virtual machines created under this image are 'Generalized' or 'Specialized'. Possible values include: 'Generalized', 'Specialized'
|
||||
OsState OperatingSystemStateTypes `json:"osState,omitempty"`
|
||||
// HyperVGeneration - The hypervisor generation of the Virtual Machine. Applicable to OS disks only. Possible values include: 'V1', 'V2'
|
||||
HyperVGeneration HyperVGeneration `json:"hyperVGeneration,omitempty"`
|
||||
// EndOfLifeDate - The end of life date of the gallery Image Definition. This property can be used for decommissioning purposes. This property is updatable.
|
||||
EndOfLifeDate *date.Time `json:"endOfLifeDate,omitempty"`
|
||||
Identifier *GalleryImageIdentifier `json:"identifier,omitempty"`
|
||||
Recommended *RecommendedMachineConfiguration `json:"recommended,omitempty"`
|
||||
Disallowed *Disallowed `json:"disallowed,omitempty"`
|
||||
PurchasePlan *ImagePurchasePlan `json:"purchasePlan,omitempty"`
|
||||
// ProvisioningState - READ-ONLY; The provisioning state, which only appears in the response. Possible values include: 'ProvisioningState2Creating', 'ProvisioningState2Updating', 'ProvisioningState2Failed', 'ProvisioningState2Succeeded', 'ProvisioningState2Deleting', 'ProvisioningState2Migrating'
|
||||
ProvisioningState ProvisioningState2 `json:"provisioningState,omitempty"`
|
||||
// ProvisioningState - READ-ONLY; The provisioning state, which only appears in the response. Possible values include: 'ProvisioningState1Creating', 'ProvisioningState1Updating', 'ProvisioningState1Failed', 'ProvisioningState1Succeeded', 'ProvisioningState1Deleting', 'ProvisioningState1Migrating'
|
||||
ProvisioningState ProvisioningState1 `json:"provisioningState,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryImagesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
|
||||
@ -4979,19 +4306,15 @@ func NewGalleryImageVersionListPage(getNextPage func(context.Context, GalleryIma
|
||||
// GalleryImageVersionProperties describes the properties of a gallery Image Version.
|
||||
type GalleryImageVersionProperties struct {
|
||||
PublishingProfile *GalleryImageVersionPublishingProfile `json:"publishingProfile,omitempty"`
|
||||
// ProvisioningState - READ-ONLY; The provisioning state, which only appears in the response. Possible values include: 'ProvisioningState3Creating', 'ProvisioningState3Updating', 'ProvisioningState3Failed', 'ProvisioningState3Succeeded', 'ProvisioningState3Deleting', 'ProvisioningState3Migrating'
|
||||
ProvisioningState ProvisioningState3 `json:"provisioningState,omitempty"`
|
||||
// StorageProfile - READ-ONLY
|
||||
StorageProfile *GalleryImageVersionStorageProfile `json:"storageProfile,omitempty"`
|
||||
// ProvisioningState - READ-ONLY; The provisioning state, which only appears in the response. Possible values include: 'ProvisioningState2Creating', 'ProvisioningState2Updating', 'ProvisioningState2Failed', 'ProvisioningState2Succeeded', 'ProvisioningState2Deleting', 'ProvisioningState2Migrating'
|
||||
ProvisioningState ProvisioningState2 `json:"provisioningState,omitempty"`
|
||||
StorageProfile *GalleryImageVersionStorageProfile `json:"storageProfile,omitempty"`
|
||||
// ReplicationStatus - READ-ONLY
|
||||
ReplicationStatus *ReplicationStatus `json:"replicationStatus,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryImageVersionPublishingProfile the publishing profile of a gallery Image Version.
|
||||
type GalleryImageVersionPublishingProfile struct {
|
||||
Source *GalleryArtifactSource `json:"source,omitempty"`
|
||||
// TargetRegions - The target regions where the Image Version is going to be replicated to. This property is updatable.
|
||||
TargetRegions *[]TargetRegion `json:"targetRegions,omitempty"`
|
||||
// ReplicaCount - The number of replicas of the Image Version to be created per region. This property would take effect for a region when regionalReplicaCount is not specified. This property is updatable.
|
||||
ReplicaCount *int32 `json:"replicaCount,omitempty"`
|
||||
// ExcludeFromLatest - If set to true, Virtual Machines deployed from the latest version of the Image Definition won't use this Image Version.
|
||||
@ -5002,6 +4325,8 @@ type GalleryImageVersionPublishingProfile struct {
|
||||
EndOfLifeDate *date.Time `json:"endOfLifeDate,omitempty"`
|
||||
// StorageAccountType - Specifies the storage account type to be used to store the image. This property is not updatable. Possible values include: 'StorageAccountTypeStandardLRS', 'StorageAccountTypeStandardZRS'
|
||||
StorageAccountType StorageAccountType `json:"storageAccountType,omitempty"`
|
||||
// TargetRegions - The target regions where the Image Version is going to be replicated to. This property is updatable.
|
||||
TargetRegions *[]TargetRegion `json:"targetRegions,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryImageVersionsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
|
||||
@ -5056,11 +4381,11 @@ func (future *GalleryImageVersionsDeleteFuture) Result(client GalleryImageVersio
|
||||
return
|
||||
}
|
||||
|
||||
// GalleryImageVersionStorageProfile this is the storage profile of a gallery Image Version.
|
||||
// GalleryImageVersionStorageProfile this is the storage profile of a Gallery Image Version.
|
||||
type GalleryImageVersionStorageProfile struct {
|
||||
// OsDiskImage - READ-ONLY
|
||||
OsDiskImage *GalleryOSDiskImage `json:"osDiskImage,omitempty"`
|
||||
// DataDiskImages - READ-ONLY; A list of data disk images.
|
||||
Source *GalleryArtifactVersionSource `json:"source,omitempty"`
|
||||
OsDiskImage *GalleryOSDiskImage `json:"osDiskImage,omitempty"`
|
||||
// DataDiskImages - A list of data disk images.
|
||||
DataDiskImages *[]GalleryDataDiskImage `json:"dataDiskImages,omitempty"`
|
||||
}
|
||||
|
||||
@ -5214,8 +4539,9 @@ func NewGalleryListPage(getNextPage func(context.Context, GalleryList) (GalleryL
|
||||
type GalleryOSDiskImage struct {
|
||||
// SizeInGB - READ-ONLY; This property indicates the size of the VHD to be created.
|
||||
SizeInGB *int32 `json:"sizeInGB,omitempty"`
|
||||
// HostCaching - READ-ONLY; The host caching of the disk. Valid values are 'None', 'ReadOnly', and 'ReadWrite'. Possible values include: 'HostCachingNone', 'HostCachingReadOnly', 'HostCachingReadWrite'
|
||||
HostCaching HostCaching `json:"hostCaching,omitempty"`
|
||||
// HostCaching - The host caching of the disk. Valid values are 'None', 'ReadOnly', and 'ReadWrite'. Possible values include: 'HostCachingNone', 'HostCachingReadOnly', 'HostCachingReadWrite'
|
||||
HostCaching HostCaching `json:"hostCaching,omitempty"`
|
||||
Source *GalleryArtifactVersionSource `json:"source,omitempty"`
|
||||
}
|
||||
|
||||
// GalleryProperties describes the properties of a Shared Image Gallery.
|
||||
@ -6048,12 +5374,6 @@ type MaintenanceRedeployStatus struct {
|
||||
LastOperationMessage *string `json:"lastOperationMessage,omitempty"`
|
||||
}
|
||||
|
||||
// ManagedArtifact the managed artifact.
|
||||
type ManagedArtifact struct {
|
||||
// ID - The managed artifact id.
|
||||
ID *string `json:"id,omitempty"`
|
||||
}
|
||||
|
||||
// ManagedDiskParameters the parameters of a managed disk.
|
||||
type ManagedDiskParameters struct {
|
||||
// StorageAccountType - Specifies the storage account type for the managed disk. NOTE: UltraSSD_LRS can only be used with data disks, it cannot be used with OS Disk. Possible values include: 'StorageAccountTypesStandardLRS', 'StorageAccountTypesPremiumLRS', 'StorageAccountTypesStandardSSDLRS', 'StorageAccountTypesUltraSSDLRS'
|
||||
@ -7933,14 +7253,6 @@ type UsageName struct {
|
||||
LocalizedValue *string `json:"localizedValue,omitempty"`
|
||||
}
|
||||
|
||||
// UserArtifactSource the source image from which the Image Version is going to be created.
|
||||
type UserArtifactSource struct {
|
||||
// FileName - Required. The fileName of the artifact.
|
||||
FileName *string `json:"fileName,omitempty"`
|
||||
// MediaLink - Required. The mediaLink of the artifact, must be a readable storage blob.
|
||||
MediaLink *string `json:"mediaLink,omitempty"`
|
||||
}
|
||||
|
||||
// VaultCertificate describes a single certificate reference in a Key Vault, and where the certificate
|
||||
// should reside on the VM.
|
||||
type VaultCertificate struct {
|
@ -21,7 +21,7 @@ import "github.com/Azure/azure-sdk-for-go/version"
|
||||
|
||||
// UserAgent returns the UserAgent string to use when sending http.Requests.
|
||||
func UserAgent() string {
|
||||
return "Azure-SDK-For-Go/" + version.Number + " compute/2019-03-01"
|
||||
return "Azure-SDK-For-Go/" + version.Number + " compute/2019-07-01"
|
||||
}
|
||||
|
||||
// Version returns the semantic version (see http://semver.org) of the client.
|
@ -13,8 +13,8 @@ go_library(
|
||||
"version.go",
|
||||
"webhooks.go",
|
||||
],
|
||||
importmap = "k8s.io/kubernetes/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2018-09-01/containerregistry",
|
||||
importpath = "github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2018-09-01/containerregistry",
|
||||
importmap = "k8s.io/kubernetes/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry",
|
||||
importpath = "github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry",
|
||||
visibility = ["//visibility:public"],
|
||||
deps = [
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/version:go_default_library",
|
@ -29,7 +29,7 @@ import (
|
||||
)
|
||||
|
||||
// The package's fully qualified name.
|
||||
const fqdn = "github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2018-09-01/containerregistry"
|
||||
const fqdn = "github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry"
|
||||
|
||||
// Action enumerates the values for action.
|
||||
type Action string
|
||||
@ -204,6 +204,25 @@ func PossibleRegistryUsageUnitValues() []RegistryUsageUnit {
|
||||
return []RegistryUsageUnit{Bytes, Count}
|
||||
}
|
||||
|
||||
// ResourceIdentityType enumerates the values for resource identity type.
|
||||
type ResourceIdentityType string
|
||||
|
||||
const (
|
||||
// None ...
|
||||
None ResourceIdentityType = "None"
|
||||
// SystemAssigned ...
|
||||
SystemAssigned ResourceIdentityType = "SystemAssigned"
|
||||
// SystemAssignedUserAssigned ...
|
||||
SystemAssignedUserAssigned ResourceIdentityType = "SystemAssigned, UserAssigned"
|
||||
// UserAssigned ...
|
||||
UserAssigned ResourceIdentityType = "UserAssigned"
|
||||
)
|
||||
|
||||
// PossibleResourceIdentityTypeValues returns an array of possible values for the ResourceIdentityType const type.
|
||||
func PossibleResourceIdentityTypeValues() []ResourceIdentityType {
|
||||
return []ResourceIdentityType{None, SystemAssigned, SystemAssignedUserAssigned, UserAssigned}
|
||||
}
|
||||
|
||||
// RunStatus enumerates the values for run status.
|
||||
type RunStatus string
|
||||
|
||||
@ -256,11 +275,13 @@ type SecretObjectType string
|
||||
const (
|
||||
// Opaque ...
|
||||
Opaque SecretObjectType = "Opaque"
|
||||
// Vaultsecret ...
|
||||
Vaultsecret SecretObjectType = "Vaultsecret"
|
||||
)
|
||||
|
||||
// PossibleSecretObjectTypeValues returns an array of possible values for the SecretObjectType const type.
|
||||
func PossibleSecretObjectTypeValues() []SecretObjectType {
|
||||
return []SecretObjectType{Opaque}
|
||||
return []SecretObjectType{Opaque, Vaultsecret}
|
||||
}
|
||||
|
||||
// SkuName enumerates the values for sku name.
|
||||
@ -320,15 +341,15 @@ func PossibleSourceControlTypeValues() []SourceControlType {
|
||||
type SourceRegistryLoginMode string
|
||||
|
||||
const (
|
||||
// Default ...
|
||||
Default SourceRegistryLoginMode = "Default"
|
||||
// None ...
|
||||
None SourceRegistryLoginMode = "None"
|
||||
// SourceRegistryLoginModeDefault ...
|
||||
SourceRegistryLoginModeDefault SourceRegistryLoginMode = "Default"
|
||||
// SourceRegistryLoginModeNone ...
|
||||
SourceRegistryLoginModeNone SourceRegistryLoginMode = "None"
|
||||
)
|
||||
|
||||
// PossibleSourceRegistryLoginModeValues returns an array of possible values for the SourceRegistryLoginMode const type.
|
||||
func PossibleSourceRegistryLoginModeValues() []SourceRegistryLoginMode {
|
||||
return []SourceRegistryLoginMode{Default, None}
|
||||
return []SourceRegistryLoginMode{SourceRegistryLoginModeDefault, SourceRegistryLoginModeNone}
|
||||
}
|
||||
|
||||
// SourceTriggerEvent enumerates the values for source trigger event.
|
||||
@ -652,6 +673,12 @@ type CustomRegistryCredentials struct {
|
||||
// Password - The password for logging into the custom registry. The password is a secret
|
||||
// object that allows multiple ways of providing the value for it.
|
||||
Password *SecretObject `json:"password,omitempty"`
|
||||
// Identity - Indicates the managed identity assigned to the custom credential. If a user-assigned identity
|
||||
// this value is the Client ID. If a system-assigned identity, the value will be `system`. In
|
||||
// the case of a system-assigned identity, the Client ID will be determined by the runner. This
|
||||
// identity may be used to authenticate to key vault to retrieve credentials or it may be the only
|
||||
// source of authentication used for accessing the registry.
|
||||
Identity *string `json:"identity,omitempty"`
|
||||
}
|
||||
|
||||
// DockerBuildRequest the parameters for a docker quick build.
|
||||
@ -1628,6 +1655,39 @@ func (ftsup FileTaskStepUpdateParameters) AsBasicTaskStepUpdateParameters() (Bas
|
||||
return &ftsup, true
|
||||
}
|
||||
|
||||
// IdentityProperties managed identity for the resource.
|
||||
type IdentityProperties struct {
|
||||
// PrincipalID - The principal ID of resource identity.
|
||||
PrincipalID *string `json:"principalId,omitempty"`
|
||||
// TenantID - The tenant ID of resource.
|
||||
TenantID *string `json:"tenantId,omitempty"`
|
||||
// Type - The identity type. Possible values include: 'SystemAssigned', 'UserAssigned', 'SystemAssignedUserAssigned', 'None'
|
||||
Type ResourceIdentityType `json:"type,omitempty"`
|
||||
// UserAssignedIdentities - The list of user identities associated with the resource. The user identity
|
||||
// dictionary key references will be ARM resource ids in the form:
|
||||
// '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/
|
||||
// providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
|
||||
UserAssignedIdentities map[string]*UserIdentityProperties `json:"userAssignedIdentities"`
|
||||
}
|
||||
|
||||
// MarshalJSON is the custom marshaler for IdentityProperties.
|
||||
func (IP IdentityProperties) MarshalJSON() ([]byte, error) {
|
||||
objectMap := make(map[string]interface{})
|
||||
if IP.PrincipalID != nil {
|
||||
objectMap["principalId"] = IP.PrincipalID
|
||||
}
|
||||
if IP.TenantID != nil {
|
||||
objectMap["tenantId"] = IP.TenantID
|
||||
}
|
||||
if IP.Type != "" {
|
||||
objectMap["type"] = IP.Type
|
||||
}
|
||||
if IP.UserAssignedIdentities != nil {
|
||||
objectMap["userAssignedIdentities"] = IP.UserAssignedIdentities
|
||||
}
|
||||
return json.Marshal(objectMap)
|
||||
}
|
||||
|
||||
// ImageDescriptor properties for a registry image.
|
||||
type ImageDescriptor struct {
|
||||
// Registry - The registry login server.
|
||||
@ -1990,6 +2050,16 @@ type PlatformUpdateParameters struct {
|
||||
Variant Variant `json:"variant,omitempty"`
|
||||
}
|
||||
|
||||
// Policies the policies for a container registry.
|
||||
type Policies struct {
|
||||
// QuarantinePolicy - The quarantine policy for a container registry.
|
||||
QuarantinePolicy *QuarantinePolicy `json:"quarantinePolicy,omitempty"`
|
||||
// TrustPolicy - The content trust policy for a container registry.
|
||||
TrustPolicy *TrustPolicy `json:"trustPolicy,omitempty"`
|
||||
// RetentionPolicy - The retention policy for a container registry.
|
||||
RetentionPolicy *RetentionPolicy `json:"retentionPolicy,omitempty"`
|
||||
}
|
||||
|
||||
// ProxyResource the resource model definition for a ARM proxy resource. It will have everything other than
|
||||
// required location and tags.
|
||||
type ProxyResource struct {
|
||||
@ -2001,7 +2071,7 @@ type ProxyResource struct {
|
||||
Type *string `json:"type,omitempty"`
|
||||
}
|
||||
|
||||
// QuarantinePolicy an object that represents quarantine policy for a container registry.
|
||||
// QuarantinePolicy the quarantine policy for a container registry.
|
||||
type QuarantinePolicy struct {
|
||||
// Status - The value that indicates whether the policy is enabled or not. Possible values include: 'Enabled', 'Disabled'
|
||||
Status PolicyStatus `json:"status,omitempty"`
|
||||
@ -2146,42 +2216,11 @@ func (future *RegistriesUpdateFuture) Result(client RegistriesClient) (r Registr
|
||||
return
|
||||
}
|
||||
|
||||
// RegistriesUpdatePoliciesFuture an abstraction for monitoring and retrieving the results of a
|
||||
// long-running operation.
|
||||
type RegistriesUpdatePoliciesFuture struct {
|
||||
azure.Future
|
||||
}
|
||||
|
||||
// Result returns the result of the asynchronous operation.
|
||||
// If the operation has not completed it will return an error.
|
||||
func (future *RegistriesUpdatePoliciesFuture) Result(client RegistriesClient) (rp RegistryPolicies, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "containerregistry.RegistriesUpdatePoliciesFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("containerregistry.RegistriesUpdatePoliciesFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if rp.Response.Response, err = future.GetResult(sender); err == nil && rp.Response.Response.StatusCode != http.StatusNoContent {
|
||||
rp, err = client.UpdatePoliciesResponder(rp.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "containerregistry.RegistriesUpdatePoliciesFuture", "Result", rp.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// Registry an object that represents a container registry.
|
||||
type Registry struct {
|
||||
autorest.Response `json:"-"`
|
||||
// Sku - The SKU of the container registry.
|
||||
Sku *Sku `json:"sku,omitempty"`
|
||||
// Identity - The identity of the container registry.
|
||||
Identity *RegistryIdentity `json:"identity,omitempty"`
|
||||
// RegistryProperties - The properties of the container registry.
|
||||
*RegistryProperties `json:"properties,omitempty"`
|
||||
// ID - READ-ONLY; The resource ID.
|
||||
@ -2202,9 +2241,6 @@ func (r Registry) MarshalJSON() ([]byte, error) {
|
||||
if r.Sku != nil {
|
||||
objectMap["sku"] = r.Sku
|
||||
}
|
||||
if r.Identity != nil {
|
||||
objectMap["identity"] = r.Identity
|
||||
}
|
||||
if r.RegistryProperties != nil {
|
||||
objectMap["properties"] = r.RegistryProperties
|
||||
}
|
||||
@ -2235,15 +2271,6 @@ func (r *Registry) UnmarshalJSON(body []byte) error {
|
||||
}
|
||||
r.Sku = &sku
|
||||
}
|
||||
case "identity":
|
||||
if v != nil {
|
||||
var identity RegistryIdentity
|
||||
err = json.Unmarshal(*v, &identity)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
r.Identity = &identity
|
||||
}
|
||||
case "properties":
|
||||
if v != nil {
|
||||
var registryProperties RegistryProperties
|
||||
@ -2304,16 +2331,6 @@ func (r *Registry) UnmarshalJSON(body []byte) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// RegistryIdentity the identity of the container registry.
|
||||
type RegistryIdentity struct {
|
||||
// Type - The type of identity used for the registry.
|
||||
Type *string `json:"type,omitempty"`
|
||||
// PrincipalID - The principal ID of registry identity.
|
||||
PrincipalID *string `json:"principalId,omitempty"`
|
||||
// TenantID - The tenant ID associated with the registry.
|
||||
TenantID *string `json:"tenantId,omitempty"`
|
||||
}
|
||||
|
||||
// RegistryListCredentialsResult the response from the ListCredentials operation.
|
||||
type RegistryListCredentialsResult struct {
|
||||
autorest.Response `json:"-"`
|
||||
@ -2496,15 +2513,6 @@ type RegistryPassword struct {
|
||||
Value *string `json:"value,omitempty"`
|
||||
}
|
||||
|
||||
// RegistryPolicies an object that represents policies for a container registry.
|
||||
type RegistryPolicies struct {
|
||||
autorest.Response `json:"-"`
|
||||
// QuarantinePolicy - An object that represents quarantine policy for a container registry.
|
||||
QuarantinePolicy *QuarantinePolicy `json:"quarantinePolicy,omitempty"`
|
||||
// TrustPolicy - An object that represents content trust policy for a container registry.
|
||||
TrustPolicy *TrustPolicy `json:"trustPolicy,omitempty"`
|
||||
}
|
||||
|
||||
// RegistryProperties the properties of a container registry.
|
||||
type RegistryProperties struct {
|
||||
// LoginServer - READ-ONLY; The URL that can be used to log into the container registry.
|
||||
@ -2521,16 +2529,18 @@ type RegistryProperties struct {
|
||||
StorageAccount *StorageAccountProperties `json:"storageAccount,omitempty"`
|
||||
// NetworkRuleSet - The network rule set for a container registry.
|
||||
NetworkRuleSet *NetworkRuleSet `json:"networkRuleSet,omitempty"`
|
||||
// Policies - The policies for a container registry.
|
||||
Policies *Policies `json:"policies,omitempty"`
|
||||
}
|
||||
|
||||
// RegistryPropertiesUpdateParameters the parameters for updating the properties of a container registry.
|
||||
type RegistryPropertiesUpdateParameters struct {
|
||||
// AdminUserEnabled - The value that indicates whether the admin user is enabled.
|
||||
AdminUserEnabled *bool `json:"adminUserEnabled,omitempty"`
|
||||
// StorageAccount - The parameters of a storage account for the container registry. Only applicable to Classic SKU. If specified, the storage account must be in the same physical location as the container registry.
|
||||
StorageAccount *StorageAccountProperties `json:"storageAccount,omitempty"`
|
||||
// NetworkRuleSet - The network rule set for a container registry.
|
||||
NetworkRuleSet *NetworkRuleSet `json:"networkRuleSet,omitempty"`
|
||||
// Policies - The policies for a container registry.
|
||||
Policies *Policies `json:"policies,omitempty"`
|
||||
}
|
||||
|
||||
// RegistryUpdateParameters the parameters for updating a container registry.
|
||||
@ -2539,8 +2549,6 @@ type RegistryUpdateParameters struct {
|
||||
Tags map[string]*string `json:"tags"`
|
||||
// Sku - The SKU of the container registry.
|
||||
Sku *Sku `json:"sku,omitempty"`
|
||||
// Identity - The identity of the container registry.
|
||||
Identity *RegistryIdentity `json:"identity,omitempty"`
|
||||
// RegistryPropertiesUpdateParameters - The properties that the container registry will be updated with.
|
||||
*RegistryPropertiesUpdateParameters `json:"properties,omitempty"`
|
||||
}
|
||||
@ -2554,9 +2562,6 @@ func (rup RegistryUpdateParameters) MarshalJSON() ([]byte, error) {
|
||||
if rup.Sku != nil {
|
||||
objectMap["sku"] = rup.Sku
|
||||
}
|
||||
if rup.Identity != nil {
|
||||
objectMap["identity"] = rup.Identity
|
||||
}
|
||||
if rup.RegistryPropertiesUpdateParameters != nil {
|
||||
objectMap["properties"] = rup.RegistryPropertiesUpdateParameters
|
||||
}
|
||||
@ -2590,15 +2595,6 @@ func (rup *RegistryUpdateParameters) UnmarshalJSON(body []byte) error {
|
||||
}
|
||||
rup.Sku = &sku
|
||||
}
|
||||
case "identity":
|
||||
if v != nil {
|
||||
var identity RegistryIdentity
|
||||
err = json.Unmarshal(*v, &identity)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
rup.Identity = &identity
|
||||
}
|
||||
case "properties":
|
||||
if v != nil {
|
||||
var registryPropertiesUpdateParameters RegistryPropertiesUpdateParameters
|
||||
@ -3024,6 +3020,16 @@ func (r Resource) MarshalJSON() ([]byte, error) {
|
||||
return json.Marshal(objectMap)
|
||||
}
|
||||
|
||||
// RetentionPolicy the retention policy for a container registry.
|
||||
type RetentionPolicy struct {
|
||||
// Days - The number of days to retain manifest before it expires.
|
||||
Days *int32 `json:"days,omitempty"`
|
||||
// LastUpdatedTime - READ-ONLY; The timestamp when the policy was last updated.
|
||||
LastUpdatedTime *date.Time `json:"lastUpdatedTime,omitempty"`
|
||||
// Status - The value that indicates whether the policy is enabled or not. Possible values include: 'Enabled', 'Disabled'
|
||||
Status PolicyStatus `json:"status,omitempty"`
|
||||
}
|
||||
|
||||
// Run run resource properties
|
||||
type Run struct {
|
||||
autorest.Response `json:"-"`
|
||||
@ -3309,6 +3315,8 @@ type RunProperties struct {
|
||||
ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
|
||||
// IsArchiveEnabled - The value that indicates whether archiving is enabled or not.
|
||||
IsArchiveEnabled *bool `json:"isArchiveEnabled,omitempty"`
|
||||
// TimerTrigger - The timer trigger that caused the run.
|
||||
TimerTrigger *TimerTriggerDescriptor `json:"timerTrigger,omitempty"`
|
||||
}
|
||||
|
||||
// BasicRunRequest the request parameters for scheduling a run.
|
||||
@ -3483,7 +3491,7 @@ type SecretObject struct {
|
||||
// used as is without any modification.
|
||||
Value *string `json:"value,omitempty"`
|
||||
// Type - The type of the secret object which determines how the value of the secret object has to be
|
||||
// interpreted. Possible values include: 'Opaque'
|
||||
// interpreted. Possible values include: 'Opaque', 'Vaultsecret'
|
||||
Type SecretObjectType `json:"type,omitempty"`
|
||||
}
|
||||
|
||||
@ -3531,7 +3539,7 @@ type SourceProperties struct {
|
||||
type SourceRegistryCredentials struct {
|
||||
// LoginMode - The authentication mode which determines the source registry login scope. The credentials for the source registry
|
||||
// will be generated using the given scope. These credentials will be used to login to
|
||||
// the source registry during the run. Possible values include: 'None', 'Default'
|
||||
// the source registry during the run. Possible values include: 'SourceRegistryLoginModeNone', 'SourceRegistryLoginModeDefault'
|
||||
LoginMode SourceRegistryLoginMode `json:"loginMode,omitempty"`
|
||||
}
|
||||
|
||||
@ -3642,6 +3650,8 @@ type Target struct {
|
||||
// The task will have all information to schedule a run against it.
|
||||
type Task struct {
|
||||
autorest.Response `json:"-"`
|
||||
// Identity - Identity for the resource.
|
||||
Identity *IdentityProperties `json:"identity,omitempty"`
|
||||
// TaskProperties - The properties of a task.
|
||||
*TaskProperties `json:"properties,omitempty"`
|
||||
// ID - READ-ONLY; The resource ID.
|
||||
@ -3659,6 +3669,9 @@ type Task struct {
|
||||
// MarshalJSON is the custom marshaler for Task.
|
||||
func (t Task) MarshalJSON() ([]byte, error) {
|
||||
objectMap := make(map[string]interface{})
|
||||
if t.Identity != nil {
|
||||
objectMap["identity"] = t.Identity
|
||||
}
|
||||
if t.TaskProperties != nil {
|
||||
objectMap["properties"] = t.TaskProperties
|
||||
}
|
||||
@ -3680,6 +3693,15 @@ func (t *Task) UnmarshalJSON(body []byte) error {
|
||||
}
|
||||
for k, v := range m {
|
||||
switch k {
|
||||
case "identity":
|
||||
if v != nil {
|
||||
var identity IdentityProperties
|
||||
err = json.Unmarshal(*v, &identity)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
t.Identity = &identity
|
||||
}
|
||||
case "properties":
|
||||
if v != nil {
|
||||
var taskProperties TaskProperties
|
||||
@ -4449,6 +4471,8 @@ func (future *TasksUpdateFuture) Result(client TasksClient) (t Task, err error)
|
||||
|
||||
// TaskUpdateParameters the parameters for updating a task.
|
||||
type TaskUpdateParameters struct {
|
||||
// Identity - Identity for the resource.
|
||||
Identity *IdentityProperties `json:"identity,omitempty"`
|
||||
// TaskPropertiesUpdateParameters - The properties for updating a task.
|
||||
*TaskPropertiesUpdateParameters `json:"properties,omitempty"`
|
||||
// Tags - The ARM resource tags.
|
||||
@ -4458,6 +4482,9 @@ type TaskUpdateParameters struct {
|
||||
// MarshalJSON is the custom marshaler for TaskUpdateParameters.
|
||||
func (tup TaskUpdateParameters) MarshalJSON() ([]byte, error) {
|
||||
objectMap := make(map[string]interface{})
|
||||
if tup.Identity != nil {
|
||||
objectMap["identity"] = tup.Identity
|
||||
}
|
||||
if tup.TaskPropertiesUpdateParameters != nil {
|
||||
objectMap["properties"] = tup.TaskPropertiesUpdateParameters
|
||||
}
|
||||
@ -4476,6 +4503,15 @@ func (tup *TaskUpdateParameters) UnmarshalJSON(body []byte) error {
|
||||
}
|
||||
for k, v := range m {
|
||||
switch k {
|
||||
case "identity":
|
||||
if v != nil {
|
||||
var identity IdentityProperties
|
||||
err = json.Unmarshal(*v, &identity)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
tup.Identity = &identity
|
||||
}
|
||||
case "properties":
|
||||
if v != nil {
|
||||
var taskPropertiesUpdateParameters TaskPropertiesUpdateParameters
|
||||
@ -4500,8 +4536,38 @@ func (tup *TaskUpdateParameters) UnmarshalJSON(body []byte) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// TimerTrigger the properties of a timer trigger.
|
||||
type TimerTrigger struct {
|
||||
// Schedule - The CRON expression for the task schedule
|
||||
Schedule *string `json:"schedule,omitempty"`
|
||||
// Status - The current status of trigger. Possible values include: 'TriggerStatusDisabled', 'TriggerStatusEnabled'
|
||||
Status TriggerStatus `json:"status,omitempty"`
|
||||
// Name - The name of the trigger.
|
||||
Name *string `json:"name,omitempty"`
|
||||
}
|
||||
|
||||
// TimerTriggerDescriptor ...
|
||||
type TimerTriggerDescriptor struct {
|
||||
// TimerTriggerName - The timer trigger name that caused the run.
|
||||
TimerTriggerName *string `json:"timerTriggerName,omitempty"`
|
||||
// ScheduleOccurrence - The occurrence that triggered the run.
|
||||
ScheduleOccurrence *string `json:"scheduleOccurrence,omitempty"`
|
||||
}
|
||||
|
||||
// TimerTriggerUpdateParameters the properties for updating a timer trigger.
|
||||
type TimerTriggerUpdateParameters struct {
|
||||
// Schedule - The CRON expression for the task schedule
|
||||
Schedule *string `json:"schedule,omitempty"`
|
||||
// Status - The current status of trigger. Possible values include: 'TriggerStatusDisabled', 'TriggerStatusEnabled'
|
||||
Status TriggerStatus `json:"status,omitempty"`
|
||||
// Name - The name of the trigger.
|
||||
Name *string `json:"name,omitempty"`
|
||||
}
|
||||
|
||||
// TriggerProperties the properties of a trigger.
|
||||
type TriggerProperties struct {
|
||||
// TimerTriggers - The collection of timer triggers.
|
||||
TimerTriggers *[]TimerTrigger `json:"timerTriggers,omitempty"`
|
||||
// SourceTriggers - The collection of triggers based on source code repository.
|
||||
SourceTriggers *[]SourceTrigger `json:"sourceTriggers,omitempty"`
|
||||
// BaseImageTrigger - The trigger based on base image dependencies.
|
||||
@ -4510,13 +4576,15 @@ type TriggerProperties struct {
|
||||
|
||||
// TriggerUpdateParameters the properties for updating triggers.
|
||||
type TriggerUpdateParameters struct {
|
||||
// TimerTriggers - The collection of timer triggers.
|
||||
TimerTriggers *[]TimerTriggerUpdateParameters `json:"timerTriggers,omitempty"`
|
||||
// SourceTriggers - The collection of triggers based on source code repository.
|
||||
SourceTriggers *[]SourceTriggerUpdateParameters `json:"sourceTriggers,omitempty"`
|
||||
// BaseImageTrigger - The trigger based on base image dependencies.
|
||||
BaseImageTrigger *BaseImageTriggerUpdateParameters `json:"baseImageTrigger,omitempty"`
|
||||
}
|
||||
|
||||
// TrustPolicy an object that represents content trust policy for a container registry.
|
||||
// TrustPolicy the content trust policy for a container registry.
|
||||
type TrustPolicy struct {
|
||||
// Type - The type of trust policy. Possible values include: 'Notary'
|
||||
Type TrustPolicyType `json:"type,omitempty"`
|
||||
@ -4524,6 +4592,14 @@ type TrustPolicy struct {
|
||||
Status PolicyStatus `json:"status,omitempty"`
|
||||
}
|
||||
|
||||
// UserIdentityProperties ...
|
||||
type UserIdentityProperties struct {
|
||||
// PrincipalID - The principal id of user assigned identity.
|
||||
PrincipalID *string `json:"principalId,omitempty"`
|
||||
// ClientID - The client id of user assigned identity.
|
||||
ClientID *string `json:"clientId,omitempty"`
|
||||
}
|
||||
|
||||
// VirtualNetworkRule virtual network rule.
|
||||
type VirtualNetworkRule struct {
|
||||
// Action - The action of virtual network rule. Possible values include: 'Allow'
|
@ -76,7 +76,7 @@ func (client OperationsClient) List(ctx context.Context) (result OperationListRe
|
||||
|
||||
// ListPreparer prepares the List request.
|
||||
func (client OperationsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -94,7 +94,7 @@ func (client RegistriesClient) CheckNameAvailabilityPreparer(ctx context.Context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -184,7 +184,7 @@ func (client RegistriesClient) CreatePreparer(ctx context.Context, resourceGroup
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -273,7 +273,7 @@ func (client RegistriesClient) DeletePreparer(ctx context.Context, resourceGroup
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -365,7 +365,7 @@ func (client RegistriesClient) GetPreparer(ctx context.Context, resourceGroupNam
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -452,7 +452,7 @@ func (client RegistriesClient) GetBuildSourceUploadURLPreparer(ctx context.Conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -540,7 +540,7 @@ func (client RegistriesClient) ImportImagePreparer(ctx context.Context, resource
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -620,7 +620,7 @@ func (client RegistriesClient) ListPreparer(ctx context.Context) (*http.Request,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -739,7 +739,7 @@ func (client RegistriesClient) ListByResourceGroupPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -863,7 +863,7 @@ func (client RegistriesClient) ListCredentialsPreparer(ctx context.Context, reso
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -896,93 +896,6 @@ func (client RegistriesClient) ListCredentialsResponder(resp *http.Response) (re
|
||||
return
|
||||
}
|
||||
|
||||
// ListPolicies lists the policies for the specified container registry.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group to which the container registry belongs.
|
||||
// registryName - the name of the container registry.
|
||||
func (client RegistriesClient) ListPolicies(ctx context.Context, resourceGroupName string, registryName string) (result RegistryPolicies, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.ListPolicies")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: resourceGroupName,
|
||||
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
|
||||
{TargetValue: registryName,
|
||||
Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
|
||||
{Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
|
||||
{Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
|
||||
return result, validation.NewError("containerregistry.RegistriesClient", "ListPolicies", err.Error())
|
||||
}
|
||||
|
||||
req, err := client.ListPoliciesPreparer(ctx, resourceGroupName, registryName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListPolicies", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListPoliciesSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListPolicies", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.ListPoliciesResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListPolicies", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListPoliciesPreparer prepares the ListPolicies request.
|
||||
func (client RegistriesClient) ListPoliciesPreparer(ctx context.Context, resourceGroupName string, registryName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"registryName": autorest.Encode("path", registryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/listPolicies", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListPoliciesSender sends the ListPolicies request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client RegistriesClient) ListPoliciesSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListPoliciesResponder handles the response to the ListPolicies request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client RegistriesClient) ListPoliciesResponder(resp *http.Response) (result RegistryPolicies, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// ListUsages gets the quota usages for the specified container registry.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group to which the container registry belongs.
|
||||
@ -1037,7 +950,7 @@ func (client RegistriesClient) ListUsagesPreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -1126,7 +1039,7 @@ func (client RegistriesClient) RegenerateCredentialPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -1210,7 +1123,7 @@ func (client RegistriesClient) ScheduleRunPreparer(ctx context.Context, resource
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -1300,7 +1213,7 @@ func (client RegistriesClient) UpdatePreparer(ctx context.Context, resourceGroup
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -1340,93 +1253,3 @@ func (client RegistriesClient) UpdateResponder(resp *http.Response) (result Regi
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// UpdatePolicies updates the policies for the specified container registry.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group to which the container registry belongs.
|
||||
// registryName - the name of the container registry.
|
||||
// registryPoliciesUpdateParameters - the parameters for updating policies of a container registry.
|
||||
func (client RegistriesClient) UpdatePolicies(ctx context.Context, resourceGroupName string, registryName string, registryPoliciesUpdateParameters RegistryPolicies) (result RegistriesUpdatePoliciesFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.UpdatePolicies")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: resourceGroupName,
|
||||
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
|
||||
{TargetValue: registryName,
|
||||
Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
|
||||
{Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
|
||||
{Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
|
||||
return result, validation.NewError("containerregistry.RegistriesClient", "UpdatePolicies", err.Error())
|
||||
}
|
||||
|
||||
req, err := client.UpdatePoliciesPreparer(ctx, resourceGroupName, registryName, registryPoliciesUpdateParameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "UpdatePolicies", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.UpdatePoliciesSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "UpdatePolicies", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// UpdatePoliciesPreparer prepares the UpdatePolicies request.
|
||||
func (client RegistriesClient) UpdatePoliciesPreparer(ctx context.Context, resourceGroupName string, registryName string, registryPoliciesUpdateParameters RegistryPolicies) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"registryName": autorest.Encode("path", registryName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPost(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/updatePolicies", pathParameters),
|
||||
autorest.WithJSON(registryPoliciesUpdateParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// UpdatePoliciesSender sends the UpdatePolicies request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client RegistriesClient) UpdatePoliciesSender(req *http.Request) (future RegistriesUpdatePoliciesFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdatePoliciesResponder handles the response to the UpdatePolicies request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client RegistriesClient) UpdatePoliciesResponder(resp *http.Response) (result RegistryPolicies, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
@ -96,7 +96,7 @@ func (client ReplicationsClient) CreatePreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -191,7 +191,7 @@ func (client ReplicationsClient) DeletePreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -289,7 +289,7 @@ func (client ReplicationsClient) GetPreparer(ctx context.Context, resourceGroupN
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -377,7 +377,7 @@ func (client ReplicationsClient) ListPreparer(ctx context.Context, resourceGroup
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -502,7 +502,7 @@ func (client ReplicationsClient) UpdatePreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -91,7 +91,7 @@ func (client RunsClient) CancelPreparer(ctx context.Context, resourceGroupName s
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -185,7 +185,7 @@ func (client RunsClient) GetPreparer(ctx context.Context, resourceGroupName stri
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -274,7 +274,7 @@ func (client RunsClient) GetLogSasURLPreparer(ctx context.Context, resourceGroup
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -365,7 +365,7 @@ func (client RunsClient) ListPreparer(ctx context.Context, resourceGroupName str
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -492,7 +492,7 @@ func (client RunsClient) UpdatePreparer(ctx context.Context, resourceGroupName s
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -109,7 +109,7 @@ func (client TasksClient) CreatePreparer(ctx context.Context, resourceGroupName
|
||||
"taskName": autorest.Encode("path", taskName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -204,7 +204,7 @@ func (client TasksClient) DeletePreparer(ctx context.Context, resourceGroupName
|
||||
"taskName": autorest.Encode("path", taskName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -302,7 +302,7 @@ func (client TasksClient) GetPreparer(ctx context.Context, resourceGroupName str
|
||||
"taskName": autorest.Encode("path", taskName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -395,7 +395,7 @@ func (client TasksClient) GetDetailsPreparer(ctx context.Context, resourceGroupN
|
||||
"taskName": autorest.Encode("path", taskName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -483,7 +483,7 @@ func (client TasksClient) ListPreparer(ctx context.Context, resourceGroupName st
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -608,7 +608,7 @@ func (client TasksClient) UpdatePreparer(ctx context.Context, resourceGroupName
|
||||
"taskName": autorest.Encode("path", taskName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-09-01"
|
||||
const APIVersion = "2019-04-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -21,7 +21,7 @@ import "github.com/Azure/azure-sdk-for-go/version"
|
||||
|
||||
// UserAgent returns the UserAgent string to use when sending http.Requests.
|
||||
func UserAgent() string {
|
||||
return "Azure-SDK-For-Go/" + version.Number + " containerregistry/2018-09-01"
|
||||
return "Azure-SDK-For-Go/" + version.Number + " containerregistry/2019-05-01"
|
||||
}
|
||||
|
||||
// Version returns the semantic version (see http://semver.org) of the client.
|
@ -102,7 +102,7 @@ func (client WebhooksClient) CreatePreparer(ctx context.Context, resourceGroupNa
|
||||
"webhookName": autorest.Encode("path", webhookName),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -197,7 +197,7 @@ func (client WebhooksClient) DeletePreparer(ctx context.Context, resourceGroupNa
|
||||
"webhookName": autorest.Encode("path", webhookName),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -295,7 +295,7 @@ func (client WebhooksClient) GetPreparer(ctx context.Context, resourceGroupName
|
||||
"webhookName": autorest.Encode("path", webhookName),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -388,7 +388,7 @@ func (client WebhooksClient) GetCallbackConfigPreparer(ctx context.Context, reso
|
||||
"webhookName": autorest.Encode("path", webhookName),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -476,7 +476,7 @@ func (client WebhooksClient) ListPreparer(ctx context.Context, resourceGroupName
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -607,7 +607,7 @@ func (client WebhooksClient) ListEventsPreparer(ctx context.Context, resourceGro
|
||||
"webhookName": autorest.Encode("path", webhookName),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -737,7 +737,7 @@ func (client WebhooksClient) PingPreparer(ctx context.Context, resourceGroupName
|
||||
"webhookName": autorest.Encode("path", webhookName),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -825,7 +825,7 @@ func (client WebhooksClient) UpdatePreparer(ctx context.Context, resourceGroupNa
|
||||
"webhookName": autorest.Encode("path", webhookName),
|
||||
}
|
||||
|
||||
const APIVersion = "2017-10-01"
|
||||
const APIVersion = "2019-05-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -7,12 +7,15 @@ go_library(
|
||||
"applicationsecuritygroups.go",
|
||||
"availabledelegations.go",
|
||||
"availableendpointservices.go",
|
||||
"availableprivateendpointtypes.go",
|
||||
"availableresourcegroupdelegations.go",
|
||||
"azurefirewallfqdntags.go",
|
||||
"azurefirewalls.go",
|
||||
"bastionhosts.go",
|
||||
"bgpservicecommunities.go",
|
||||
"client.go",
|
||||
"connectionmonitors.go",
|
||||
"ddoscustompolicies.go",
|
||||
"ddosprotectionplans.go",
|
||||
"defaultsecurityrules.go",
|
||||
"expressroutecircuitauthorizations.go",
|
||||
@ -29,7 +32,6 @@ go_library(
|
||||
"expressrouteserviceproviders.go",
|
||||
"hubvirtualnetworkconnections.go",
|
||||
"inboundnatrules.go",
|
||||
"interfaceendpoints.go",
|
||||
"interfaceipconfigurations.go",
|
||||
"interfaceloadbalancers.go",
|
||||
"interfacesgroup.go",
|
||||
@ -43,21 +45,28 @@ go_library(
|
||||
"loadbalancers.go",
|
||||
"localnetworkgateways.go",
|
||||
"models.go",
|
||||
"natgateways.go",
|
||||
"operations.go",
|
||||
"p2svpngateways.go",
|
||||
"p2svpnserverconfigurations.go",
|
||||
"packetcaptures.go",
|
||||
"peerexpressroutecircuitconnections.go",
|
||||
"privateendpoints.go",
|
||||
"privatelinkservices.go",
|
||||
"profiles.go",
|
||||
"publicipaddresses.go",
|
||||
"publicipprefixes.go",
|
||||
"resourcenavigationlinks.go",
|
||||
"routefilterrules.go",
|
||||
"routefilters.go",
|
||||
"routes.go",
|
||||
"routetables.go",
|
||||
"securitygroups.go",
|
||||
"securityrules.go",
|
||||
"serviceassociationlinks.go",
|
||||
"serviceendpointpolicies.go",
|
||||
"serviceendpointpolicydefinitions.go",
|
||||
"servicetags.go",
|
||||
"subnets.go",
|
||||
"usages.go",
|
||||
"version.go",
|
||||
@ -70,12 +79,16 @@ go_library(
|
||||
"virtualwans.go",
|
||||
"vpnconnections.go",
|
||||
"vpngateways.go",
|
||||
"vpnlinkconnections.go",
|
||||
"vpnsitelinkconnections.go",
|
||||
"vpnsitelinks.go",
|
||||
"vpnsites.go",
|
||||
"vpnsitesconfiguration.go",
|
||||
"watchers.go",
|
||||
"webapplicationfirewallpolicies.go",
|
||||
],
|
||||
importmap = "k8s.io/kubernetes/vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2018-08-01/network",
|
||||
importpath = "github.com/Azure/azure-sdk-for-go/services/network/mgmt/2018-08-01/network",
|
||||
importmap = "k8s.io/kubernetes/vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network",
|
||||
importpath = "github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network",
|
||||
visibility = ["//visibility:public"],
|
||||
deps = [
|
||||
"//vendor/github.com/Azure/azure-sdk-for-go/version:go_default_library",
|
@ -80,7 +80,7 @@ func (client ApplicationGatewaysClient) BackendHealthPreparer(ctx context.Contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -122,6 +122,91 @@ func (client ApplicationGatewaysClient) BackendHealthResponder(resp *http.Respon
|
||||
return
|
||||
}
|
||||
|
||||
// BackendHealthOnDemand gets the backend health for given combination of backend pool and http setting of the
|
||||
// specified application gateway in a resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// applicationGatewayName - the name of the application gateway.
|
||||
// probeRequest - request body for on-demand test probe operation.
|
||||
// expand - expands BackendAddressPool and BackendHttpSettings referenced in backend health.
|
||||
func (client ApplicationGatewaysClient) BackendHealthOnDemand(ctx context.Context, resourceGroupName string, applicationGatewayName string, probeRequest ApplicationGatewayOnDemandProbe, expand string) (result ApplicationGatewaysBackendHealthOnDemandFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ApplicationGatewaysClient.BackendHealthOnDemand")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.BackendHealthOnDemandPreparer(ctx, resourceGroupName, applicationGatewayName, probeRequest, expand)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "BackendHealthOnDemand", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.BackendHealthOnDemandSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "BackendHealthOnDemand", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// BackendHealthOnDemandPreparer prepares the BackendHealthOnDemand request.
|
||||
func (client ApplicationGatewaysClient) BackendHealthOnDemandPreparer(ctx context.Context, resourceGroupName string, applicationGatewayName string, probeRequest ApplicationGatewayOnDemandProbe, expand string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"applicationGatewayName": autorest.Encode("path", applicationGatewayName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
if len(expand) > 0 {
|
||||
queryParameters["$expand"] = autorest.Encode("query", expand)
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPost(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/applicationGateways/{applicationGatewayName}/getBackendHealthOnDemand", pathParameters),
|
||||
autorest.WithJSON(probeRequest),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// BackendHealthOnDemandSender sends the BackendHealthOnDemand request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ApplicationGatewaysClient) BackendHealthOnDemandSender(req *http.Request) (future ApplicationGatewaysBackendHealthOnDemandFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// BackendHealthOnDemandResponder handles the response to the BackendHealthOnDemand request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ApplicationGatewaysClient) BackendHealthOnDemandResponder(resp *http.Response) (result ApplicationGatewayBackendHealthOnDemand, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdate creates or updates the specified application gateway.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
@ -154,13 +239,13 @@ func (client ApplicationGatewaysClient) CreateOrUpdate(ctx context.Context, reso
|
||||
{Target: "parameters.ApplicationGatewayPropertiesFormat.WebApplicationFirewallConfiguration.MaxRequestBodySizeInKb", Name: validation.InclusiveMinimum, Rule: 8, Chain: nil},
|
||||
}},
|
||||
{Target: "parameters.ApplicationGatewayPropertiesFormat.WebApplicationFirewallConfiguration.FileUploadLimitInMb", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "parameters.ApplicationGatewayPropertiesFormat.WebApplicationFirewallConfiguration.FileUploadLimitInMb", Name: validation.InclusiveMaximum, Rule: int64(500), Chain: nil},
|
||||
{Target: "parameters.ApplicationGatewayPropertiesFormat.WebApplicationFirewallConfiguration.FileUploadLimitInMb", Name: validation.InclusiveMinimum, Rule: 0, Chain: nil},
|
||||
}},
|
||||
Chain: []validation.Constraint{{Target: "parameters.ApplicationGatewayPropertiesFormat.WebApplicationFirewallConfiguration.FileUploadLimitInMb", Name: validation.InclusiveMinimum, Rule: 0, Chain: nil}}},
|
||||
}},
|
||||
{Target: "parameters.ApplicationGatewayPropertiesFormat.AutoscaleConfiguration", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "parameters.ApplicationGatewayPropertiesFormat.AutoscaleConfiguration.MinCapacity", Name: validation.Null, Rule: true,
|
||||
Chain: []validation.Constraint{{Target: "parameters.ApplicationGatewayPropertiesFormat.AutoscaleConfiguration.MinCapacity", Name: validation.InclusiveMinimum, Rule: 2, Chain: nil}}},
|
||||
Chain: []validation.Constraint{{Target: "parameters.ApplicationGatewayPropertiesFormat.AutoscaleConfiguration.MinCapacity", Name: validation.InclusiveMinimum, Rule: 0, Chain: nil}}},
|
||||
{Target: "parameters.ApplicationGatewayPropertiesFormat.AutoscaleConfiguration.MaxCapacity", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "parameters.ApplicationGatewayPropertiesFormat.AutoscaleConfiguration.MaxCapacity", Name: validation.InclusiveMinimum, Rule: 2, Chain: nil}}},
|
||||
}},
|
||||
}}}}}); err != nil {
|
||||
return result, validation.NewError("network.ApplicationGatewaysClient", "CreateOrUpdate", err.Error())
|
||||
@ -189,7 +274,7 @@ func (client ApplicationGatewaysClient) CreateOrUpdatePreparer(ctx context.Conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -268,7 +353,7 @@ func (client ApplicationGatewaysClient) DeletePreparer(ctx context.Context, reso
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -350,7 +435,7 @@ func (client ApplicationGatewaysClient) GetPreparer(ctx context.Context, resourc
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -425,7 +510,7 @@ func (client ApplicationGatewaysClient) GetSslPredefinedPolicyPreparer(ctx conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -501,7 +586,7 @@ func (client ApplicationGatewaysClient) ListPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -611,7 +696,7 @@ func (client ApplicationGatewaysClient) ListAllPreparer(ctx context.Context) (*h
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -681,6 +766,222 @@ func (client ApplicationGatewaysClient) ListAllComplete(ctx context.Context) (re
|
||||
return
|
||||
}
|
||||
|
||||
// ListAvailableRequestHeaders lists all available request headers.
|
||||
func (client ApplicationGatewaysClient) ListAvailableRequestHeaders(ctx context.Context) (result ListString, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ApplicationGatewaysClient.ListAvailableRequestHeaders")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.ListAvailableRequestHeadersPreparer(ctx)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAvailableRequestHeaders", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListAvailableRequestHeadersSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAvailableRequestHeaders", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.ListAvailableRequestHeadersResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAvailableRequestHeaders", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListAvailableRequestHeadersPreparer prepares the ListAvailableRequestHeaders request.
|
||||
func (client ApplicationGatewaysClient) ListAvailableRequestHeadersPreparer(ctx context.Context) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Network/applicationGatewayAvailableRequestHeaders", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListAvailableRequestHeadersSender sends the ListAvailableRequestHeaders request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ApplicationGatewaysClient) ListAvailableRequestHeadersSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListAvailableRequestHeadersResponder handles the response to the ListAvailableRequestHeaders request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ApplicationGatewaysClient) ListAvailableRequestHeadersResponder(resp *http.Response) (result ListString, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result.Value),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// ListAvailableResponseHeaders lists all available response headers.
|
||||
func (client ApplicationGatewaysClient) ListAvailableResponseHeaders(ctx context.Context) (result ListString, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ApplicationGatewaysClient.ListAvailableResponseHeaders")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.ListAvailableResponseHeadersPreparer(ctx)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAvailableResponseHeaders", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListAvailableResponseHeadersSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAvailableResponseHeaders", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.ListAvailableResponseHeadersResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAvailableResponseHeaders", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListAvailableResponseHeadersPreparer prepares the ListAvailableResponseHeaders request.
|
||||
func (client ApplicationGatewaysClient) ListAvailableResponseHeadersPreparer(ctx context.Context) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Network/applicationGatewayAvailableResponseHeaders", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListAvailableResponseHeadersSender sends the ListAvailableResponseHeaders request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ApplicationGatewaysClient) ListAvailableResponseHeadersSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListAvailableResponseHeadersResponder handles the response to the ListAvailableResponseHeaders request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ApplicationGatewaysClient) ListAvailableResponseHeadersResponder(resp *http.Response) (result ListString, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result.Value),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// ListAvailableServerVariables lists all available server variables.
|
||||
func (client ApplicationGatewaysClient) ListAvailableServerVariables(ctx context.Context) (result ListString, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ApplicationGatewaysClient.ListAvailableServerVariables")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.ListAvailableServerVariablesPreparer(ctx)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAvailableServerVariables", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListAvailableServerVariablesSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAvailableServerVariables", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.ListAvailableServerVariablesResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAvailableServerVariables", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListAvailableServerVariablesPreparer prepares the ListAvailableServerVariables request.
|
||||
func (client ApplicationGatewaysClient) ListAvailableServerVariablesPreparer(ctx context.Context) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Network/applicationGatewayAvailableServerVariables", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListAvailableServerVariablesSender sends the ListAvailableServerVariables request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ApplicationGatewaysClient) ListAvailableServerVariablesSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListAvailableServerVariablesResponder handles the response to the ListAvailableServerVariables request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ApplicationGatewaysClient) ListAvailableServerVariablesResponder(resp *http.Response) (result ListString, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result.Value),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// ListAvailableSslOptions lists available Ssl options for configuring Ssl policy.
|
||||
func (client ApplicationGatewaysClient) ListAvailableSslOptions(ctx context.Context) (result ApplicationGatewayAvailableSslOptions, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
@ -720,7 +1021,7 @@ func (client ApplicationGatewaysClient) ListAvailableSslOptionsPreparer(ctx cont
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -793,7 +1094,7 @@ func (client ApplicationGatewaysClient) ListAvailableSslPredefinedPoliciesPrepar
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -902,7 +1203,7 @@ func (client ApplicationGatewaysClient) ListAvailableWafRuleSetsPreparer(ctx con
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -973,7 +1274,7 @@ func (client ApplicationGatewaysClient) StartPreparer(ctx context.Context, resou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -1049,7 +1350,7 @@ func (client ApplicationGatewaysClient) StopPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -1126,7 +1427,7 @@ func (client ApplicationGatewaysClient) UpdateTagsPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -79,7 +79,7 @@ func (client ApplicationSecurityGroupsClient) CreateOrUpdatePreparer(ctx context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -159,7 +159,7 @@ func (client ApplicationSecurityGroupsClient) DeletePreparer(ctx context.Context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -241,7 +241,7 @@ func (client ApplicationSecurityGroupsClient) GetPreparer(ctx context.Context, r
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -317,7 +317,7 @@ func (client ApplicationSecurityGroupsClient) ListPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -427,7 +427,7 @@ func (client ApplicationSecurityGroupsClient) ListAllPreparer(ctx context.Contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -496,3 +496,83 @@ func (client ApplicationSecurityGroupsClient) ListAllComplete(ctx context.Contex
|
||||
result.page, err = client.ListAll(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTags updates an application security group's tags.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// applicationSecurityGroupName - the name of the application security group.
|
||||
// parameters - parameters supplied to update application security group tags.
|
||||
func (client ApplicationSecurityGroupsClient) UpdateTags(ctx context.Context, resourceGroupName string, applicationSecurityGroupName string, parameters TagsObject) (result ApplicationSecurityGroupsUpdateTagsFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ApplicationSecurityGroupsClient.UpdateTags")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.UpdateTagsPreparer(ctx, resourceGroupName, applicationSecurityGroupName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationSecurityGroupsClient", "UpdateTags", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.UpdateTagsSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationSecurityGroupsClient", "UpdateTags", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTagsPreparer prepares the UpdateTags request.
|
||||
func (client ApplicationSecurityGroupsClient) UpdateTagsPreparer(ctx context.Context, resourceGroupName string, applicationSecurityGroupName string, parameters TagsObject) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"applicationSecurityGroupName": autorest.Encode("path", applicationSecurityGroupName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPatch(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/applicationSecurityGroups/{applicationSecurityGroupName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// UpdateTagsSender sends the UpdateTags request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ApplicationSecurityGroupsClient) UpdateTagsSender(req *http.Request) (future ApplicationSecurityGroupsUpdateTagsFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTagsResponder handles the response to the UpdateTags request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ApplicationSecurityGroupsClient) UpdateTagsResponder(resp *http.Response) (result ApplicationSecurityGroup, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
@ -83,7 +83,7 @@ func (client AvailableDelegationsClient) ListPreparer(ctx context.Context, locat
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -83,7 +83,7 @@ func (client AvailableEndpointServicesClient) ListPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
271
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/availableprivateendpointtypes.go
generated
vendored
Normal file
271
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/availableprivateendpointtypes.go
generated
vendored
Normal file
@ -0,0 +1,271 @@
|
||||
package network
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/tracing"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// AvailablePrivateEndpointTypesClient is the network Client
|
||||
type AvailablePrivateEndpointTypesClient struct {
|
||||
BaseClient
|
||||
}
|
||||
|
||||
// NewAvailablePrivateEndpointTypesClient creates an instance of the AvailablePrivateEndpointTypesClient client.
|
||||
func NewAvailablePrivateEndpointTypesClient(subscriptionID string) AvailablePrivateEndpointTypesClient {
|
||||
return NewAvailablePrivateEndpointTypesClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewAvailablePrivateEndpointTypesClientWithBaseURI creates an instance of the AvailablePrivateEndpointTypesClient
|
||||
// client.
|
||||
func NewAvailablePrivateEndpointTypesClientWithBaseURI(baseURI string, subscriptionID string) AvailablePrivateEndpointTypesClient {
|
||||
return AvailablePrivateEndpointTypesClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// List returns all of the resource types that can be linked to a Private Endpoint in this subscription in this region.
|
||||
// Parameters:
|
||||
// location - the location of the domain name.
|
||||
func (client AvailablePrivateEndpointTypesClient) List(ctx context.Context, location string) (result AvailablePrivateEndpointTypesResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/AvailablePrivateEndpointTypesClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.apetr.Response.Response != nil {
|
||||
sc = result.apetr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listNextResults
|
||||
req, err := client.ListPreparer(ctx, location)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "List", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.apetr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "List", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.apetr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "List", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListPreparer prepares the List request.
|
||||
func (client AvailablePrivateEndpointTypesClient) ListPreparer(ctx context.Context, location string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"location": autorest.Encode("path", location),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Network/locations/{location}/availablePrivateEndpointTypes", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListSender sends the List request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client AvailablePrivateEndpointTypesClient) ListSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListResponder handles the response to the List request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client AvailablePrivateEndpointTypesClient) ListResponder(resp *http.Response) (result AvailablePrivateEndpointTypesResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listNextResults retrieves the next set of results, if any.
|
||||
func (client AvailablePrivateEndpointTypesClient) listNextResults(ctx context.Context, lastResults AvailablePrivateEndpointTypesResult) (result AvailablePrivateEndpointTypesResult, err error) {
|
||||
req, err := lastResults.availablePrivateEndpointTypesResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "listNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "listNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "listNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client AvailablePrivateEndpointTypesClient) ListComplete(ctx context.Context, location string) (result AvailablePrivateEndpointTypesResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/AvailablePrivateEndpointTypesClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.List(ctx, location)
|
||||
return
|
||||
}
|
||||
|
||||
// ListByResourceGroup returns all of the resource types that can be linked to a Private Endpoint in this subscription
|
||||
// in this region.
|
||||
// Parameters:
|
||||
// location - the location of the domain name.
|
||||
// resourceGroupName - the name of the resource group.
|
||||
func (client AvailablePrivateEndpointTypesClient) ListByResourceGroup(ctx context.Context, location string, resourceGroupName string) (result AvailablePrivateEndpointTypesResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/AvailablePrivateEndpointTypesClient.ListByResourceGroup")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.apetr.Response.Response != nil {
|
||||
sc = result.apetr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listByResourceGroupNextResults
|
||||
req, err := client.ListByResourceGroupPreparer(ctx, location, resourceGroupName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "ListByResourceGroup", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListByResourceGroupSender(req)
|
||||
if err != nil {
|
||||
result.apetr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "ListByResourceGroup", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.apetr, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
|
||||
func (client AvailablePrivateEndpointTypesClient) ListByResourceGroupPreparer(ctx context.Context, location string, resourceGroupName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"location": autorest.Encode("path", location),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/locations/{location}/availablePrivateEndpointTypes", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client AvailablePrivateEndpointTypesClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client AvailablePrivateEndpointTypesClient) ListByResourceGroupResponder(resp *http.Response) (result AvailablePrivateEndpointTypesResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listByResourceGroupNextResults retrieves the next set of results, if any.
|
||||
func (client AvailablePrivateEndpointTypesClient) listByResourceGroupNextResults(ctx context.Context, lastResults AvailablePrivateEndpointTypesResult) (result AvailablePrivateEndpointTypesResult, err error) {
|
||||
req, err := lastResults.availablePrivateEndpointTypesResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListByResourceGroupSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.AvailablePrivateEndpointTypesClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client AvailablePrivateEndpointTypesClient) ListByResourceGroupComplete(ctx context.Context, location string, resourceGroupName string) (result AvailablePrivateEndpointTypesResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/AvailablePrivateEndpointTypesClient.ListByResourceGroup")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.ListByResourceGroup(ctx, location, resourceGroupName)
|
||||
return
|
||||
}
|
@ -87,7 +87,7 @@ func (client AvailableResourceGroupDelegationsClient) ListPreparer(ctx context.C
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -80,7 +80,7 @@ func (client AzureFirewallFqdnTagsClient) ListAllPreparer(ctx context.Context) (
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -79,7 +79,7 @@ func (client AzureFirewallsClient) CreateOrUpdatePreparer(ctx context.Context, r
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -159,7 +159,7 @@ func (client AzureFirewallsClient) DeletePreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -241,7 +241,7 @@ func (client AzureFirewallsClient) GetPreparer(ctx context.Context, resourceGrou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -317,7 +317,7 @@ func (client AzureFirewallsClient) ListPreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -427,7 +427,7 @@ func (client AzureFirewallsClient) ListAllPreparer(ctx context.Context) (*http.R
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -496,3 +496,84 @@ func (client AzureFirewallsClient) ListAllComplete(ctx context.Context) (result
|
||||
result.page, err = client.ListAll(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTags updates tags for an Azure Firewall resource.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// azureFirewallName - the name of the Azure Firewall.
|
||||
// parameters - parameters supplied to the create or update Azure Firewall operation.
|
||||
func (client AzureFirewallsClient) UpdateTags(ctx context.Context, resourceGroupName string, azureFirewallName string, parameters AzureFirewall) (result AzureFirewall, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/AzureFirewallsClient.UpdateTags")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.UpdateTagsPreparer(ctx, resourceGroupName, azureFirewallName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.AzureFirewallsClient", "UpdateTags", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.UpdateTagsSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.AzureFirewallsClient", "UpdateTags", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.UpdateTagsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.AzureFirewallsClient", "UpdateTags", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTagsPreparer prepares the UpdateTags request.
|
||||
func (client AzureFirewallsClient) UpdateTagsPreparer(ctx context.Context, resourceGroupName string, azureFirewallName string, parameters AzureFirewall) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"azureFirewallName": autorest.Encode("path", azureFirewallName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
parameters.Etag = nil
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPatch(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/azureFirewalls/{azureFirewallName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// UpdateTagsSender sends the UpdateTags request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client AzureFirewallsClient) UpdateTagsSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// UpdateTagsResponder handles the response to the UpdateTags request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client AzureFirewallsClient) UpdateTagsResponder(resp *http.Response) (result AzureFirewall, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
498
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/bastionhosts.go
generated
vendored
Normal file
498
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/bastionhosts.go
generated
vendored
Normal file
@ -0,0 +1,498 @@
|
||||
package network
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/tracing"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// BastionHostsClient is the network Client
|
||||
type BastionHostsClient struct {
|
||||
BaseClient
|
||||
}
|
||||
|
||||
// NewBastionHostsClient creates an instance of the BastionHostsClient client.
|
||||
func NewBastionHostsClient(subscriptionID string) BastionHostsClient {
|
||||
return NewBastionHostsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewBastionHostsClientWithBaseURI creates an instance of the BastionHostsClient client.
|
||||
func NewBastionHostsClientWithBaseURI(baseURI string, subscriptionID string) BastionHostsClient {
|
||||
return BastionHostsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// CreateOrUpdate creates or updates the specified Bastion Host.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// bastionHostName - the name of the Bastion Host.
|
||||
// parameters - parameters supplied to the create or update Bastion Host operation.
|
||||
func (client BastionHostsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, bastionHostName string, parameters BastionHost) (result BastionHostsCreateOrUpdateFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/BastionHostsClient.CreateOrUpdate")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, bastionHostName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "CreateOrUpdate", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
|
||||
func (client BastionHostsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, bastionHostName string, parameters BastionHost) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"bastionHostName": autorest.Encode("path", bastionHostName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
parameters.Etag = nil
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/bastionHosts/{bastionHostName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client BastionHostsClient) CreateOrUpdateSender(req *http.Request) (future BastionHostsCreateOrUpdateFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client BastionHostsClient) CreateOrUpdateResponder(resp *http.Response) (result BastionHost, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// Delete deletes the specified Bastion Host.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// bastionHostName - the name of the Bastion Host.
|
||||
func (client BastionHostsClient) Delete(ctx context.Context, resourceGroupName string, bastionHostName string) (result BastionHostsDeleteFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/BastionHostsClient.Delete")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.DeletePreparer(ctx, resourceGroupName, bastionHostName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "Delete", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "Delete", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// DeletePreparer prepares the Delete request.
|
||||
func (client BastionHostsClient) DeletePreparer(ctx context.Context, resourceGroupName string, bastionHostName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"bastionHostName": autorest.Encode("path", bastionHostName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsDelete(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/bastionHosts/{bastionHostName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// DeleteSender sends the Delete request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client BastionHostsClient) DeleteSender(req *http.Request) (future BastionHostsDeleteFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// DeleteResponder handles the response to the Delete request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client BastionHostsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
|
||||
autorest.ByClosing())
|
||||
result.Response = resp
|
||||
return
|
||||
}
|
||||
|
||||
// Get gets the specified Bastion Host.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// bastionHostName - the name of the Bastion Host.
|
||||
func (client BastionHostsClient) Get(ctx context.Context, resourceGroupName string, bastionHostName string) (result BastionHost, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/BastionHostsClient.Get")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.GetPreparer(ctx, resourceGroupName, bastionHostName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "Get", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.GetSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "Get", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "Get", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// GetPreparer prepares the Get request.
|
||||
func (client BastionHostsClient) GetPreparer(ctx context.Context, resourceGroupName string, bastionHostName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"bastionHostName": autorest.Encode("path", bastionHostName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/bastionHosts/{bastionHostName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// GetSender sends the Get request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client BastionHostsClient) GetSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// GetResponder handles the response to the Get request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client BastionHostsClient) GetResponder(resp *http.Response) (result BastionHost, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// List lists all Bastion Hosts in a subscription.
|
||||
func (client BastionHostsClient) List(ctx context.Context) (result BastionHostListResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/BastionHostsClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.bhlr.Response.Response != nil {
|
||||
sc = result.bhlr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listNextResults
|
||||
req, err := client.ListPreparer(ctx)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "List", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.bhlr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "List", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.bhlr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "List", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListPreparer prepares the List request.
|
||||
func (client BastionHostsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Network/bastionHosts", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListSender sends the List request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client BastionHostsClient) ListSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListResponder handles the response to the List request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client BastionHostsClient) ListResponder(resp *http.Response) (result BastionHostListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listNextResults retrieves the next set of results, if any.
|
||||
func (client BastionHostsClient) listNextResults(ctx context.Context, lastResults BastionHostListResult) (result BastionHostListResult, err error) {
|
||||
req, err := lastResults.bastionHostListResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.BastionHostsClient", "listNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.BastionHostsClient", "listNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "listNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client BastionHostsClient) ListComplete(ctx context.Context) (result BastionHostListResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/BastionHostsClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.List(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
// ListByResourceGroup lists all Bastion Hosts in a resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
func (client BastionHostsClient) ListByResourceGroup(ctx context.Context, resourceGroupName string) (result BastionHostListResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/BastionHostsClient.ListByResourceGroup")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.bhlr.Response.Response != nil {
|
||||
sc = result.bhlr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listByResourceGroupNextResults
|
||||
req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "ListByResourceGroup", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListByResourceGroupSender(req)
|
||||
if err != nil {
|
||||
result.bhlr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "ListByResourceGroup", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.bhlr, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
|
||||
func (client BastionHostsClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/bastionHosts", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client BastionHostsClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client BastionHostsClient) ListByResourceGroupResponder(resp *http.Response) (result BastionHostListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listByResourceGroupNextResults retrieves the next set of results, if any.
|
||||
func (client BastionHostsClient) listByResourceGroupNextResults(ctx context.Context, lastResults BastionHostListResult) (result BastionHostListResult, err error) {
|
||||
req, err := lastResults.bastionHostListResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.BastionHostsClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListByResourceGroupSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.BastionHostsClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BastionHostsClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client BastionHostsClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result BastionHostListResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/BastionHostsClient.ListByResourceGroup")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
|
||||
return
|
||||
}
|
@ -80,7 +80,7 @@ func (client BgpServiceCommunitiesClient) ListPreparer(ctx context.Context) (*ht
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -98,7 +98,7 @@ func (client BaseClient) CheckDNSNameAvailabilityPreparer(ctx context.Context, l
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
"domainNameLabel": autorest.Encode("query", domainNameLabel),
|
||||
@ -176,7 +176,7 @@ func (client BaseClient) SupportedSecurityProvidersPreparer(ctx context.Context,
|
||||
"virtualWANName": autorest.Encode("path", virtualWANName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -92,7 +92,7 @@ func (client ConnectionMonitorsClient) CreateOrUpdatePreparer(ctx context.Contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -173,7 +173,7 @@ func (client ConnectionMonitorsClient) DeletePreparer(ctx context.Context, resou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -257,7 +257,7 @@ func (client ConnectionMonitorsClient) GetPreparer(ctx context.Context, resource
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -334,7 +334,7 @@ func (client ConnectionMonitorsClient) ListPreparer(ctx context.Context, resourc
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -407,7 +407,7 @@ func (client ConnectionMonitorsClient) QueryPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -486,7 +486,7 @@ func (client ConnectionMonitorsClient) StartPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -564,7 +564,7 @@ func (client ConnectionMonitorsClient) StopPreparer(ctx context.Context, resourc
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
355
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/ddoscustompolicies.go
generated
vendored
Normal file
355
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/ddoscustompolicies.go
generated
vendored
Normal file
@ -0,0 +1,355 @@
|
||||
package network
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/tracing"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// DdosCustomPoliciesClient is the network Client
|
||||
type DdosCustomPoliciesClient struct {
|
||||
BaseClient
|
||||
}
|
||||
|
||||
// NewDdosCustomPoliciesClient creates an instance of the DdosCustomPoliciesClient client.
|
||||
func NewDdosCustomPoliciesClient(subscriptionID string) DdosCustomPoliciesClient {
|
||||
return NewDdosCustomPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewDdosCustomPoliciesClientWithBaseURI creates an instance of the DdosCustomPoliciesClient client.
|
||||
func NewDdosCustomPoliciesClientWithBaseURI(baseURI string, subscriptionID string) DdosCustomPoliciesClient {
|
||||
return DdosCustomPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// CreateOrUpdate creates or updates a DDoS custom policy.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// ddosCustomPolicyName - the name of the DDoS custom policy.
|
||||
// parameters - parameters supplied to the create or update operation.
|
||||
func (client DdosCustomPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, ddosCustomPolicyName string, parameters DdosCustomPolicy) (result DdosCustomPoliciesCreateOrUpdateFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/DdosCustomPoliciesClient.CreateOrUpdate")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, ddosCustomPolicyName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosCustomPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosCustomPoliciesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
|
||||
func (client DdosCustomPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, ddosCustomPolicyName string, parameters DdosCustomPolicy) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"ddosCustomPolicyName": autorest.Encode("path", ddosCustomPolicyName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
parameters.Etag = nil
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/ddosCustomPolicies/{ddosCustomPolicyName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client DdosCustomPoliciesClient) CreateOrUpdateSender(req *http.Request) (future DdosCustomPoliciesCreateOrUpdateFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client DdosCustomPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result DdosCustomPolicy, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// Delete deletes the specified DDoS custom policy.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// ddosCustomPolicyName - the name of the DDoS custom policy.
|
||||
func (client DdosCustomPoliciesClient) Delete(ctx context.Context, resourceGroupName string, ddosCustomPolicyName string) (result DdosCustomPoliciesDeleteFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/DdosCustomPoliciesClient.Delete")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.DeletePreparer(ctx, resourceGroupName, ddosCustomPolicyName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosCustomPoliciesClient", "Delete", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosCustomPoliciesClient", "Delete", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// DeletePreparer prepares the Delete request.
|
||||
func (client DdosCustomPoliciesClient) DeletePreparer(ctx context.Context, resourceGroupName string, ddosCustomPolicyName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"ddosCustomPolicyName": autorest.Encode("path", ddosCustomPolicyName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsDelete(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/ddosCustomPolicies/{ddosCustomPolicyName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// DeleteSender sends the Delete request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client DdosCustomPoliciesClient) DeleteSender(req *http.Request) (future DdosCustomPoliciesDeleteFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// DeleteResponder handles the response to the Delete request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client DdosCustomPoliciesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
|
||||
autorest.ByClosing())
|
||||
result.Response = resp
|
||||
return
|
||||
}
|
||||
|
||||
// Get gets information about the specified DDoS custom policy.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// ddosCustomPolicyName - the name of the DDoS custom policy.
|
||||
func (client DdosCustomPoliciesClient) Get(ctx context.Context, resourceGroupName string, ddosCustomPolicyName string) (result DdosCustomPolicy, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/DdosCustomPoliciesClient.Get")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.GetPreparer(ctx, resourceGroupName, ddosCustomPolicyName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosCustomPoliciesClient", "Get", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.GetSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.DdosCustomPoliciesClient", "Get", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosCustomPoliciesClient", "Get", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// GetPreparer prepares the Get request.
|
||||
func (client DdosCustomPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, ddosCustomPolicyName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"ddosCustomPolicyName": autorest.Encode("path", ddosCustomPolicyName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/ddosCustomPolicies/{ddosCustomPolicyName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// GetSender sends the Get request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client DdosCustomPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// GetResponder handles the response to the Get request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client DdosCustomPoliciesClient) GetResponder(resp *http.Response) (result DdosCustomPolicy, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTags update a DDoS custom policy tags.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// ddosCustomPolicyName - the name of the DDoS custom policy.
|
||||
// parameters - parameters supplied to the update DDoS custom policy resource tags.
|
||||
func (client DdosCustomPoliciesClient) UpdateTags(ctx context.Context, resourceGroupName string, ddosCustomPolicyName string, parameters TagsObject) (result DdosCustomPoliciesUpdateTagsFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/DdosCustomPoliciesClient.UpdateTags")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.UpdateTagsPreparer(ctx, resourceGroupName, ddosCustomPolicyName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosCustomPoliciesClient", "UpdateTags", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.UpdateTagsSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosCustomPoliciesClient", "UpdateTags", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTagsPreparer prepares the UpdateTags request.
|
||||
func (client DdosCustomPoliciesClient) UpdateTagsPreparer(ctx context.Context, resourceGroupName string, ddosCustomPolicyName string, parameters TagsObject) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"ddosCustomPolicyName": autorest.Encode("path", ddosCustomPolicyName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPatch(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/ddosCustomPolicies/{ddosCustomPolicyName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// UpdateTagsSender sends the UpdateTags request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client DdosCustomPoliciesClient) UpdateTagsSender(req *http.Request) (future DdosCustomPoliciesUpdateTagsFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTagsResponder handles the response to the UpdateTags request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client DdosCustomPoliciesClient) UpdateTagsResponder(resp *http.Response) (result DdosCustomPolicy, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
@ -79,7 +79,7 @@ func (client DdosProtectionPlansClient) CreateOrUpdatePreparer(ctx context.Conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -162,7 +162,7 @@ func (client DdosProtectionPlansClient) DeletePreparer(ctx context.Context, reso
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -244,7 +244,7 @@ func (client DdosProtectionPlansClient) GetPreparer(ctx context.Context, resourc
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -317,7 +317,7 @@ func (client DdosProtectionPlansClient) ListPreparer(ctx context.Context) (*http
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -430,7 +430,7 @@ func (client DdosProtectionPlansClient) ListByResourceGroupPreparer(ctx context.
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -499,3 +499,83 @@ func (client DdosProtectionPlansClient) ListByResourceGroupComplete(ctx context.
|
||||
result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTags update a DDoS protection plan tags.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// ddosProtectionPlanName - the name of the DDoS protection plan.
|
||||
// parameters - parameters supplied to the update DDoS protection plan resource tags.
|
||||
func (client DdosProtectionPlansClient) UpdateTags(ctx context.Context, resourceGroupName string, ddosProtectionPlanName string, parameters TagsObject) (result DdosProtectionPlansUpdateTagsFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/DdosProtectionPlansClient.UpdateTags")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.UpdateTagsPreparer(ctx, resourceGroupName, ddosProtectionPlanName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosProtectionPlansClient", "UpdateTags", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.UpdateTagsSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.DdosProtectionPlansClient", "UpdateTags", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTagsPreparer prepares the UpdateTags request.
|
||||
func (client DdosProtectionPlansClient) UpdateTagsPreparer(ctx context.Context, resourceGroupName string, ddosProtectionPlanName string, parameters TagsObject) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"ddosProtectionPlanName": autorest.Encode("path", ddosProtectionPlanName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPatch(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/ddosProtectionPlans/{ddosProtectionPlanName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// UpdateTagsSender sends the UpdateTags request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client DdosProtectionPlansClient) UpdateTagsSender(req *http.Request) (future DdosProtectionPlansUpdateTagsFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTagsResponder handles the response to the UpdateTags request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client DdosProtectionPlansClient) UpdateTagsResponder(resp *http.Response) (result DdosProtectionPlan, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
@ -86,7 +86,7 @@ func (client DefaultSecurityRulesClient) GetPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -164,7 +164,7 @@ func (client DefaultSecurityRulesClient) ListPreparer(ctx context.Context, resou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -84,12 +84,13 @@ func (client ExpressRouteCircuitAuthorizationsClient) CreateOrUpdatePreparer(ctx
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
authorizationParameters.Etag = nil
|
||||
authorizationParameters.Type = nil
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
@ -166,7 +167,7 @@ func (client ExpressRouteCircuitAuthorizationsClient) DeletePreparer(ctx context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -250,7 +251,7 @@ func (client ExpressRouteCircuitAuthorizationsClient) GetPreparer(ctx context.Co
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -328,7 +329,7 @@ func (client ExpressRouteCircuitAuthorizationsClient) ListPreparer(ctx context.C
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -85,12 +85,13 @@ func (client ExpressRouteCircuitConnectionsClient) CreateOrUpdatePreparer(ctx co
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
expressRouteCircuitConnectionParameters.Etag = nil
|
||||
expressRouteCircuitConnectionParameters.Type = nil
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
@ -169,7 +170,7 @@ func (client ExpressRouteCircuitConnectionsClient) DeletePreparer(ctx context.Co
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -255,7 +256,7 @@ func (client ExpressRouteCircuitConnectionsClient) GetPreparer(ctx context.Conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -287,3 +288,120 @@ func (client ExpressRouteCircuitConnectionsClient) GetResponder(resp *http.Respo
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// List gets all global reach connections associated with a private peering in an express route circuit.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// circuitName - the name of the circuit.
|
||||
// peeringName - the name of the peering.
|
||||
func (client ExpressRouteCircuitConnectionsClient) List(ctx context.Context, resourceGroupName string, circuitName string, peeringName string) (result ExpressRouteCircuitConnectionListResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ExpressRouteCircuitConnectionsClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.ercclr.Response.Response != nil {
|
||||
sc = result.ercclr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listNextResults
|
||||
req, err := client.ListPreparer(ctx, resourceGroupName, circuitName, peeringName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitConnectionsClient", "List", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.ercclr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitConnectionsClient", "List", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.ercclr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitConnectionsClient", "List", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListPreparer prepares the List request.
|
||||
func (client ExpressRouteCircuitConnectionsClient) ListPreparer(ctx context.Context, resourceGroupName string, circuitName string, peeringName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"circuitName": autorest.Encode("path", circuitName),
|
||||
"peeringName": autorest.Encode("path", peeringName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/expressRouteCircuits/{circuitName}/peerings/{peeringName}/connections", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListSender sends the List request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ExpressRouteCircuitConnectionsClient) ListSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListResponder handles the response to the List request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ExpressRouteCircuitConnectionsClient) ListResponder(resp *http.Response) (result ExpressRouteCircuitConnectionListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listNextResults retrieves the next set of results, if any.
|
||||
func (client ExpressRouteCircuitConnectionsClient) listNextResults(ctx context.Context, lastResults ExpressRouteCircuitConnectionListResult) (result ExpressRouteCircuitConnectionListResult, err error) {
|
||||
req, err := lastResults.expressRouteCircuitConnectionListResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.ExpressRouteCircuitConnectionsClient", "listNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.ExpressRouteCircuitConnectionsClient", "listNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitConnectionsClient", "listNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client ExpressRouteCircuitConnectionsClient) ListComplete(ctx context.Context, resourceGroupName string, circuitName string, peeringName string) (result ExpressRouteCircuitConnectionListResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ExpressRouteCircuitConnectionsClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.List(ctx, resourceGroupName, circuitName, peeringName)
|
||||
return
|
||||
}
|
@ -93,12 +93,13 @@ func (client ExpressRouteCircuitPeeringsClient) CreateOrUpdatePreparer(ctx conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
peeringParameters.Etag = nil
|
||||
peeringParameters.Type = nil
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
@ -175,7 +176,7 @@ func (client ExpressRouteCircuitPeeringsClient) DeletePreparer(ctx context.Conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -259,7 +260,7 @@ func (client ExpressRouteCircuitPeeringsClient) GetPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -337,7 +338,7 @@ func (client ExpressRouteCircuitPeeringsClient) ListPreparer(ctx context.Context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -79,7 +79,7 @@ func (client ExpressRouteCircuitsClient) CreateOrUpdatePreparer(ctx context.Cont
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -159,7 +159,7 @@ func (client ExpressRouteCircuitsClient) DeletePreparer(ctx context.Context, res
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -241,7 +241,7 @@ func (client ExpressRouteCircuitsClient) GetPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -320,7 +320,7 @@ func (client ExpressRouteCircuitsClient) GetPeeringStatsPreparer(ctx context.Con
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -397,7 +397,7 @@ func (client ExpressRouteCircuitsClient) GetStatsPreparer(ctx context.Context, r
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -473,7 +473,7 @@ func (client ExpressRouteCircuitsClient) ListPreparer(ctx context.Context, resou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -583,7 +583,7 @@ func (client ExpressRouteCircuitsClient) ListAllPreparer(ctx context.Context) (*
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -695,7 +695,7 @@ func (client ExpressRouteCircuitsClient) ListArpTablePreparer(ctx context.Contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -777,7 +777,7 @@ func (client ExpressRouteCircuitsClient) ListRoutesTablePreparer(ctx context.Con
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -859,7 +859,7 @@ func (client ExpressRouteCircuitsClient) ListRoutesTableSummaryPreparer(ctx cont
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -937,7 +937,7 @@ func (client ExpressRouteCircuitsClient) UpdateTagsPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -90,7 +90,7 @@ func (client ExpressRouteConnectionsClient) CreateOrUpdatePreparer(ctx context.C
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -171,7 +171,7 @@ func (client ExpressRouteConnectionsClient) DeletePreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -255,7 +255,7 @@ func (client ExpressRouteConnectionsClient) GetPreparer(ctx context.Context, res
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -332,7 +332,7 @@ func (client ExpressRouteConnectionsClient) ListPreparer(ctx context.Context, re
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -96,7 +96,7 @@ func (client ExpressRouteCrossConnectionPeeringsClient) CreateOrUpdatePreparer(c
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -178,7 +178,7 @@ func (client ExpressRouteCrossConnectionPeeringsClient) DeletePreparer(ctx conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -262,7 +262,7 @@ func (client ExpressRouteCrossConnectionPeeringsClient) GetPreparer(ctx context.
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -340,7 +340,7 @@ func (client ExpressRouteCrossConnectionPeeringsClient) ListPreparer(ctx context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -80,7 +80,7 @@ func (client ExpressRouteCrossConnectionsClient) CreateOrUpdatePreparer(ctx cont
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -166,7 +166,7 @@ func (client ExpressRouteCrossConnectionsClient) GetPreparer(ctx context.Context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -239,7 +239,7 @@ func (client ExpressRouteCrossConnectionsClient) ListPreparer(ctx context.Contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -315,7 +315,7 @@ func (client ExpressRouteCrossConnectionsClient) ListComplete(ctx context.Contex
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// crossConnectionName - the name of the ExpressRouteCrossConnection.
|
||||
// peeringName - the name of the peering.
|
||||
// devicePath - the path of the device
|
||||
// devicePath - the path of the device.
|
||||
func (client ExpressRouteCrossConnectionsClient) ListArpTable(ctx context.Context, resourceGroupName string, crossConnectionName string, peeringName string, devicePath string) (result ExpressRouteCrossConnectionsListArpTableFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ExpressRouteCrossConnectionsClient.ListArpTable")
|
||||
@ -352,7 +352,7 @@ func (client ExpressRouteCrossConnectionsClient) ListArpTablePreparer(ctx contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -434,7 +434,7 @@ func (client ExpressRouteCrossConnectionsClient) ListByResourceGroupPreparer(ctx
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -547,7 +547,7 @@ func (client ExpressRouteCrossConnectionsClient) ListRoutesTablePreparer(ctx con
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -629,7 +629,7 @@ func (client ExpressRouteCrossConnectionsClient) ListRoutesTableSummaryPreparer(
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -707,7 +707,7 @@ func (client ExpressRouteCrossConnectionsClient) UpdateTagsPreparer(ctx context.
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -87,7 +87,7 @@ func (client ExpressRouteGatewaysClient) CreateOrUpdatePreparer(ctx context.Cont
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -168,7 +168,7 @@ func (client ExpressRouteGatewaysClient) DeletePreparer(ctx context.Context, res
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -250,7 +250,7 @@ func (client ExpressRouteGatewaysClient) GetPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -325,7 +325,7 @@ func (client ExpressRouteGatewaysClient) ListByResourceGroupPreparer(ctx context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -397,7 +397,7 @@ func (client ExpressRouteGatewaysClient) ListBySubscriptionPreparer(ctx context.
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -86,7 +86,7 @@ func (client ExpressRouteLinksClient) GetPreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -164,7 +164,7 @@ func (client ExpressRouteLinksClient) ListPreparer(ctx context.Context, resource
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -79,7 +79,7 @@ func (client ExpressRoutePortsClient) CreateOrUpdatePreparer(ctx context.Context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -159,7 +159,7 @@ func (client ExpressRoutePortsClient) DeletePreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -241,7 +241,7 @@ func (client ExpressRoutePortsClient) GetPreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -274,7 +274,7 @@ func (client ExpressRoutePortsClient) GetResponder(resp *http.Response) (result
|
||||
return
|
||||
}
|
||||
|
||||
// List list all the ExpressRoutePort resources in the specified subscription
|
||||
// List list all the ExpressRoutePort resources in the specified subscription.
|
||||
func (client ExpressRoutePortsClient) List(ctx context.Context) (result ExpressRoutePortListResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ExpressRoutePortsClient.List")
|
||||
@ -314,7 +314,7 @@ func (client ExpressRoutePortsClient) ListPreparer(ctx context.Context) (*http.R
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -427,7 +427,7 @@ func (client ExpressRoutePortsClient) ListByResourceGroupPreparer(ctx context.Co
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -497,7 +497,7 @@ func (client ExpressRoutePortsClient) ListByResourceGroupComplete(ctx context.Co
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTags update ExpressRoutePort tags
|
||||
// UpdateTags update ExpressRoutePort tags.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// expressRoutePortName - the name of the ExpressRoutePort resource.
|
||||
@ -536,7 +536,7 @@ func (client ExpressRoutePortsClient) UpdateTagsPreparer(ctx context.Context, re
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -83,7 +83,7 @@ func (client ExpressRoutePortsLocationsClient) GetPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -157,7 +157,7 @@ func (client ExpressRoutePortsLocationsClient) ListPreparer(ctx context.Context)
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -81,7 +81,7 @@ func (client ExpressRouteServiceProvidersClient) ListPreparer(ctx context.Contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -87,7 +87,7 @@ func (client HubVirtualNetworkConnectionsClient) GetPreparer(ctx context.Context
|
||||
"virtualHubName": autorest.Encode("path", virtualHubName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -165,7 +165,7 @@ func (client HubVirtualNetworkConnectionsClient) ListPreparer(ctx context.Contex
|
||||
"virtualHubName": autorest.Encode("path", virtualHubName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -101,11 +101,12 @@ func (client InboundNatRulesClient) CreateOrUpdatePreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
inboundNatRuleParameters.Type = nil
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
@ -182,7 +183,7 @@ func (client InboundNatRulesClient) DeletePreparer(ctx context.Context, resource
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -267,7 +268,7 @@ func (client InboundNatRulesClient) GetPreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -348,7 +349,7 @@ func (client InboundNatRulesClient) ListPreparer(ctx context.Context, resourceGr
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -86,7 +86,7 @@ func (client InterfaceIPConfigurationsClient) GetPreparer(ctx context.Context, r
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -119,7 +119,7 @@ func (client InterfaceIPConfigurationsClient) GetResponder(resp *http.Response)
|
||||
return
|
||||
}
|
||||
|
||||
// List get all ip configurations in a network interface
|
||||
// List get all ip configurations in a network interface.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// networkInterfaceName - the name of the network interface.
|
||||
@ -164,7 +164,7 @@ func (client InterfaceIPConfigurationsClient) ListPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -85,7 +85,7 @@ func (client InterfaceLoadBalancersClient) ListPreparer(ctx context.Context, res
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -79,7 +79,7 @@ func (client InterfacesClient) CreateOrUpdatePreparer(ctx context.Context, resou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -158,7 +158,7 @@ func (client InterfacesClient) DeletePreparer(ctx context.Context, resourceGroup
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -241,7 +241,7 @@ func (client InterfacesClient) GetPreparer(ctx context.Context, resourceGroupNam
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -315,7 +315,7 @@ func (client InterfacesClient) GetEffectiveRouteTablePreparer(ctx context.Contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -570,7 +570,7 @@ func (client InterfacesClient) ListPreparer(ctx context.Context, resourceGroupNa
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -680,7 +680,7 @@ func (client InterfacesClient) ListAllPreparer(ctx context.Context) (*http.Reque
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -788,7 +788,7 @@ func (client InterfacesClient) ListEffectiveNetworkSecurityGroupsPreparer(ctx co
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -1223,7 +1223,7 @@ func (client InterfacesClient) UpdateTagsPreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -117,7 +117,7 @@ func (client InterfaceTapConfigurationsClient) CreateOrUpdatePreparer(ctx contex
|
||||
"tapConfigurationName": autorest.Encode("path", tapConfigurationName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -199,7 +199,7 @@ func (client InterfaceTapConfigurationsClient) DeletePreparer(ctx context.Contex
|
||||
"tapConfigurationName": autorest.Encode("path", tapConfigurationName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -283,7 +283,7 @@ func (client InterfaceTapConfigurationsClient) GetPreparer(ctx context.Context,
|
||||
"tapConfigurationName": autorest.Encode("path", tapConfigurationName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -316,7 +316,7 @@ func (client InterfaceTapConfigurationsClient) GetResponder(resp *http.Response)
|
||||
return
|
||||
}
|
||||
|
||||
// List get all Tap configurations in a network interface
|
||||
// List get all Tap configurations in a network interface.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// networkInterfaceName - the name of the network interface.
|
||||
@ -361,7 +361,7 @@ func (client InterfaceTapConfigurationsClient) ListPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -87,7 +87,7 @@ func (client LoadBalancerBackendAddressPoolsClient) GetPreparer(ctx context.Cont
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -165,7 +165,7 @@ func (client LoadBalancerBackendAddressPoolsClient) ListPreparer(ctx context.Con
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -88,7 +88,7 @@ func (client LoadBalancerFrontendIPConfigurationsClient) GetPreparer(ctx context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -166,7 +166,7 @@ func (client LoadBalancerFrontendIPConfigurationsClient) ListPreparer(ctx contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -87,7 +87,7 @@ func (client LoadBalancerLoadBalancingRulesClient) GetPreparer(ctx context.Conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -165,7 +165,7 @@ func (client LoadBalancerLoadBalancingRulesClient) ListPreparer(ctx context.Cont
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -86,7 +86,7 @@ func (client LoadBalancerNetworkInterfacesClient) ListPreparer(ctx context.Conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -86,7 +86,7 @@ func (client LoadBalancerOutboundRulesClient) GetPreparer(ctx context.Context, r
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -164,7 +164,7 @@ func (client LoadBalancerOutboundRulesClient) ListPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -86,7 +86,7 @@ func (client LoadBalancerProbesClient) GetPreparer(ctx context.Context, resource
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -164,7 +164,7 @@ func (client LoadBalancerProbesClient) ListPreparer(ctx context.Context, resourc
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -79,7 +79,7 @@ func (client LoadBalancersClient) CreateOrUpdatePreparer(ctx context.Context, re
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -158,7 +158,7 @@ func (client LoadBalancersClient) DeletePreparer(ctx context.Context, resourceGr
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -241,7 +241,7 @@ func (client LoadBalancersClient) GetPreparer(ctx context.Context, resourceGroup
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -320,7 +320,7 @@ func (client LoadBalancersClient) ListPreparer(ctx context.Context, resourceGrou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -430,7 +430,7 @@ func (client LoadBalancersClient) ListAllPreparer(ctx context.Context) (*http.Re
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -539,7 +539,7 @@ func (client LoadBalancersClient) UpdateTagsPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -88,7 +88,7 @@ func (client LocalNetworkGatewaysClient) CreateOrUpdatePreparer(ctx context.Cont
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -173,7 +173,7 @@ func (client LocalNetworkGatewaysClient) DeletePreparer(ctx context.Context, res
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -261,7 +261,7 @@ func (client LocalNetworkGatewaysClient) GetPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -337,7 +337,7 @@ func (client LocalNetworkGatewaysClient) ListPreparer(ctx context.Context, resou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -452,7 +452,7 @@ func (client LocalNetworkGatewaysClient) UpdateTagsPreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
File diff suppressed because it is too large
Load Diff
581
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/natgateways.go
generated
vendored
Normal file
581
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/natgateways.go
generated
vendored
Normal file
@ -0,0 +1,581 @@
|
||||
package network
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/tracing"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// NatGatewaysClient is the network Client
|
||||
type NatGatewaysClient struct {
|
||||
BaseClient
|
||||
}
|
||||
|
||||
// NewNatGatewaysClient creates an instance of the NatGatewaysClient client.
|
||||
func NewNatGatewaysClient(subscriptionID string) NatGatewaysClient {
|
||||
return NewNatGatewaysClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewNatGatewaysClientWithBaseURI creates an instance of the NatGatewaysClient client.
|
||||
func NewNatGatewaysClientWithBaseURI(baseURI string, subscriptionID string) NatGatewaysClient {
|
||||
return NatGatewaysClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// CreateOrUpdate creates or updates a nat gateway.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// natGatewayName - the name of the nat gateway.
|
||||
// parameters - parameters supplied to the create or update nat gateway operation.
|
||||
func (client NatGatewaysClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, natGatewayName string, parameters NatGateway) (result NatGatewaysCreateOrUpdateFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/NatGatewaysClient.CreateOrUpdate")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, natGatewayName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "CreateOrUpdate", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
|
||||
func (client NatGatewaysClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, natGatewayName string, parameters NatGateway) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"natGatewayName": autorest.Encode("path", natGatewayName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/natGateways/{natGatewayName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client NatGatewaysClient) CreateOrUpdateSender(req *http.Request) (future NatGatewaysCreateOrUpdateFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client NatGatewaysClient) CreateOrUpdateResponder(resp *http.Response) (result NatGateway, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// Delete deletes the specified nat gateway.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// natGatewayName - the name of the nat gateway.
|
||||
func (client NatGatewaysClient) Delete(ctx context.Context, resourceGroupName string, natGatewayName string) (result NatGatewaysDeleteFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/NatGatewaysClient.Delete")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.DeletePreparer(ctx, resourceGroupName, natGatewayName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "Delete", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "Delete", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// DeletePreparer prepares the Delete request.
|
||||
func (client NatGatewaysClient) DeletePreparer(ctx context.Context, resourceGroupName string, natGatewayName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"natGatewayName": autorest.Encode("path", natGatewayName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsDelete(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/natGateways/{natGatewayName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// DeleteSender sends the Delete request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client NatGatewaysClient) DeleteSender(req *http.Request) (future NatGatewaysDeleteFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// DeleteResponder handles the response to the Delete request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client NatGatewaysClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
|
||||
autorest.ByClosing())
|
||||
result.Response = resp
|
||||
return
|
||||
}
|
||||
|
||||
// Get gets the specified nat gateway in a specified resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// natGatewayName - the name of the nat gateway.
|
||||
// expand - expands referenced resources.
|
||||
func (client NatGatewaysClient) Get(ctx context.Context, resourceGroupName string, natGatewayName string, expand string) (result NatGateway, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/NatGatewaysClient.Get")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.GetPreparer(ctx, resourceGroupName, natGatewayName, expand)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "Get", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.GetSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "Get", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "Get", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// GetPreparer prepares the Get request.
|
||||
func (client NatGatewaysClient) GetPreparer(ctx context.Context, resourceGroupName string, natGatewayName string, expand string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"natGatewayName": autorest.Encode("path", natGatewayName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
if len(expand) > 0 {
|
||||
queryParameters["$expand"] = autorest.Encode("query", expand)
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/natGateways/{natGatewayName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// GetSender sends the Get request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client NatGatewaysClient) GetSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// GetResponder handles the response to the Get request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client NatGatewaysClient) GetResponder(resp *http.Response) (result NatGateway, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// List gets all nat gateways in a resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
func (client NatGatewaysClient) List(ctx context.Context, resourceGroupName string) (result NatGatewayListResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/NatGatewaysClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.nglr.Response.Response != nil {
|
||||
sc = result.nglr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listNextResults
|
||||
req, err := client.ListPreparer(ctx, resourceGroupName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "List", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.nglr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "List", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.nglr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "List", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListPreparer prepares the List request.
|
||||
func (client NatGatewaysClient) ListPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/natGateways", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListSender sends the List request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client NatGatewaysClient) ListSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListResponder handles the response to the List request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client NatGatewaysClient) ListResponder(resp *http.Response) (result NatGatewayListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listNextResults retrieves the next set of results, if any.
|
||||
func (client NatGatewaysClient) listNextResults(ctx context.Context, lastResults NatGatewayListResult) (result NatGatewayListResult, err error) {
|
||||
req, err := lastResults.natGatewayListResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.NatGatewaysClient", "listNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.NatGatewaysClient", "listNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "listNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client NatGatewaysClient) ListComplete(ctx context.Context, resourceGroupName string) (result NatGatewayListResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/NatGatewaysClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.List(ctx, resourceGroupName)
|
||||
return
|
||||
}
|
||||
|
||||
// ListAll gets all the Nat Gateways in a subscription.
|
||||
func (client NatGatewaysClient) ListAll(ctx context.Context) (result NatGatewayListResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/NatGatewaysClient.ListAll")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.nglr.Response.Response != nil {
|
||||
sc = result.nglr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listAllNextResults
|
||||
req, err := client.ListAllPreparer(ctx)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "ListAll", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListAllSender(req)
|
||||
if err != nil {
|
||||
result.nglr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "ListAll", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.nglr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "ListAll", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListAllPreparer prepares the ListAll request.
|
||||
func (client NatGatewaysClient) ListAllPreparer(ctx context.Context) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Network/natGateways", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListAllSender sends the ListAll request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client NatGatewaysClient) ListAllSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListAllResponder handles the response to the ListAll request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client NatGatewaysClient) ListAllResponder(resp *http.Response) (result NatGatewayListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listAllNextResults retrieves the next set of results, if any.
|
||||
func (client NatGatewaysClient) listAllNextResults(ctx context.Context, lastResults NatGatewayListResult) (result NatGatewayListResult, err error) {
|
||||
req, err := lastResults.natGatewayListResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.NatGatewaysClient", "listAllNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListAllSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.NatGatewaysClient", "listAllNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "listAllNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListAllComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client NatGatewaysClient) ListAllComplete(ctx context.Context) (result NatGatewayListResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/NatGatewaysClient.ListAll")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.ListAll(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTags updates nat gateway tags.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// natGatewayName - the name of the nat gateway.
|
||||
// parameters - parameters supplied to update nat gateway tags.
|
||||
func (client NatGatewaysClient) UpdateTags(ctx context.Context, resourceGroupName string, natGatewayName string, parameters TagsObject) (result NatGateway, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/NatGatewaysClient.UpdateTags")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.UpdateTagsPreparer(ctx, resourceGroupName, natGatewayName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "UpdateTags", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.UpdateTagsSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "UpdateTags", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.UpdateTagsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.NatGatewaysClient", "UpdateTags", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// UpdateTagsPreparer prepares the UpdateTags request.
|
||||
func (client NatGatewaysClient) UpdateTagsPreparer(ctx context.Context, resourceGroupName string, natGatewayName string, parameters TagsObject) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"natGatewayName": autorest.Encode("path", natGatewayName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPatch(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/natGateways/{natGatewayName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// UpdateTagsSender sends the UpdateTags request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client NatGatewaysClient) UpdateTagsSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// UpdateTagsResponder handles the response to the UpdateTags request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client NatGatewaysClient) UpdateTagsResponder(resp *http.Response) (result NatGateway, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
@ -76,7 +76,7 @@ func (client OperationsClient) List(ctx context.Context) (result OperationListRe
|
||||
|
||||
// ListPreparer prepares the List request.
|
||||
func (client OperationsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -79,7 +79,7 @@ func (client P2sVpnGatewaysClient) CreateOrUpdatePreparer(ctx context.Context, r
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -159,7 +159,7 @@ func (client P2sVpnGatewaysClient) DeletePreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -236,7 +236,7 @@ func (client P2sVpnGatewaysClient) GenerateVpnProfilePreparer(ctx context.Contex
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -321,7 +321,7 @@ func (client P2sVpnGatewaysClient) GetPreparer(ctx context.Context, resourceGrou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -354,6 +354,84 @@ func (client P2sVpnGatewaysClient) GetResponder(resp *http.Response) (result P2S
|
||||
return
|
||||
}
|
||||
|
||||
// GetP2sVpnConnectionHealth gets the connection health of P2S clients of the virtual wan P2SVpnGateway in the
|
||||
// specified resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// gatewayName - the name of the P2SVpnGateway.
|
||||
func (client P2sVpnGatewaysClient) GetP2sVpnConnectionHealth(ctx context.Context, resourceGroupName string, gatewayName string) (result P2sVpnGatewaysGetP2sVpnConnectionHealthFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/P2sVpnGatewaysClient.GetP2sVpnConnectionHealth")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
sc = result.Response().StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.GetP2sVpnConnectionHealthPreparer(ctx, resourceGroupName, gatewayName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.P2sVpnGatewaysClient", "GetP2sVpnConnectionHealth", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.GetP2sVpnConnectionHealthSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.P2sVpnGatewaysClient", "GetP2sVpnConnectionHealth", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// GetP2sVpnConnectionHealthPreparer prepares the GetP2sVpnConnectionHealth request.
|
||||
func (client P2sVpnGatewaysClient) GetP2sVpnConnectionHealthPreparer(ctx context.Context, resourceGroupName string, gatewayName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"gatewayName": autorest.Encode("path", gatewayName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsPost(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/p2svpnGateways/{gatewayName}/getP2sVpnConnectionHealth", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// GetP2sVpnConnectionHealthSender sends the GetP2sVpnConnectionHealth request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client P2sVpnGatewaysClient) GetP2sVpnConnectionHealthSender(req *http.Request) (future P2sVpnGatewaysGetP2sVpnConnectionHealthFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
return
|
||||
}
|
||||
|
||||
// GetP2sVpnConnectionHealthResponder handles the response to the GetP2sVpnConnectionHealth request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client P2sVpnGatewaysClient) GetP2sVpnConnectionHealthResponder(resp *http.Response) (result P2SVpnGateway, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// List lists all the P2SVpnGateways in a subscription.
|
||||
func (client P2sVpnGatewaysClient) List(ctx context.Context) (result ListP2SVpnGatewaysResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
@ -394,7 +472,7 @@ func (client P2sVpnGatewaysClient) ListPreparer(ctx context.Context) (*http.Requ
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -507,7 +585,7 @@ func (client P2sVpnGatewaysClient) ListByResourceGroupPreparer(ctx context.Conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -616,7 +694,7 @@ func (client P2sVpnGatewaysClient) UpdateTagsPreparer(ctx context.Context, resou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -82,7 +82,7 @@ func (client P2sVpnServerConfigurationsClient) CreateOrUpdatePreparer(ctx contex
|
||||
"virtualWanName": autorest.Encode("path", virtualWanName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -164,7 +164,7 @@ func (client P2sVpnServerConfigurationsClient) DeletePreparer(ctx context.Contex
|
||||
"virtualWanName": autorest.Encode("path", virtualWanName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -248,7 +248,7 @@ func (client P2sVpnServerConfigurationsClient) GetPreparer(ctx context.Context,
|
||||
"virtualWanName": autorest.Encode("path", virtualWanName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -326,7 +326,7 @@ func (client P2sVpnServerConfigurationsClient) ListByVirtualWanPreparer(ctx cont
|
||||
"virtualWanName": autorest.Encode("path", virtualWanName),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -91,7 +91,7 @@ func (client PacketCapturesClient) CreatePreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -172,7 +172,7 @@ func (client PacketCapturesClient) DeletePreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -256,7 +256,7 @@ func (client PacketCapturesClient) GetPreparer(ctx context.Context, resourceGrou
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -329,7 +329,7 @@ func (client PacketCapturesClient) GetStatusPreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -412,7 +412,7 @@ func (client PacketCapturesClient) ListPreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -485,7 +485,7 @@ func (client PacketCapturesClient) StopPreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
241
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/peerexpressroutecircuitconnections.go
generated
vendored
Normal file
241
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/peerexpressroutecircuitconnections.go
generated
vendored
Normal file
@ -0,0 +1,241 @@
|
||||
package network
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/tracing"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// PeerExpressRouteCircuitConnectionsClient is the network Client
|
||||
type PeerExpressRouteCircuitConnectionsClient struct {
|
||||
BaseClient
|
||||
}
|
||||
|
||||
// NewPeerExpressRouteCircuitConnectionsClient creates an instance of the PeerExpressRouteCircuitConnectionsClient
|
||||
// client.
|
||||
func NewPeerExpressRouteCircuitConnectionsClient(subscriptionID string) PeerExpressRouteCircuitConnectionsClient {
|
||||
return NewPeerExpressRouteCircuitConnectionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewPeerExpressRouteCircuitConnectionsClientWithBaseURI creates an instance of the
|
||||
// PeerExpressRouteCircuitConnectionsClient client.
|
||||
func NewPeerExpressRouteCircuitConnectionsClientWithBaseURI(baseURI string, subscriptionID string) PeerExpressRouteCircuitConnectionsClient {
|
||||
return PeerExpressRouteCircuitConnectionsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// Get gets the specified Peer Express Route Circuit Connection from the specified express route circuit.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// circuitName - the name of the express route circuit.
|
||||
// peeringName - the name of the peering.
|
||||
// connectionName - the name of the peer express route circuit connection.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) Get(ctx context.Context, resourceGroupName string, circuitName string, peeringName string, connectionName string) (result PeerExpressRouteCircuitConnection, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PeerExpressRouteCircuitConnectionsClient.Get")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.GetPreparer(ctx, resourceGroupName, circuitName, peeringName, connectionName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PeerExpressRouteCircuitConnectionsClient", "Get", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.GetSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.PeerExpressRouteCircuitConnectionsClient", "Get", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PeerExpressRouteCircuitConnectionsClient", "Get", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// GetPreparer prepares the Get request.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) GetPreparer(ctx context.Context, resourceGroupName string, circuitName string, peeringName string, connectionName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"circuitName": autorest.Encode("path", circuitName),
|
||||
"connectionName": autorest.Encode("path", connectionName),
|
||||
"peeringName": autorest.Encode("path", peeringName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/expressRouteCircuits/{circuitName}/peerings/{peeringName}/peerConnections/{connectionName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// GetSender sends the Get request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) GetSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// GetResponder handles the response to the Get request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) GetResponder(resp *http.Response) (result PeerExpressRouteCircuitConnection, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// List gets all global reach peer connections associated with a private peering in an express route circuit.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// circuitName - the name of the circuit.
|
||||
// peeringName - the name of the peering.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) List(ctx context.Context, resourceGroupName string, circuitName string, peeringName string) (result PeerExpressRouteCircuitConnectionListResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PeerExpressRouteCircuitConnectionsClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.percclr.Response.Response != nil {
|
||||
sc = result.percclr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.fn = client.listNextResults
|
||||
req, err := client.ListPreparer(ctx, resourceGroupName, circuitName, peeringName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PeerExpressRouteCircuitConnectionsClient", "List", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.percclr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.PeerExpressRouteCircuitConnectionsClient", "List", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.percclr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PeerExpressRouteCircuitConnectionsClient", "List", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListPreparer prepares the List request.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) ListPreparer(ctx context.Context, resourceGroupName string, circuitName string, peeringName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"circuitName": autorest.Encode("path", circuitName),
|
||||
"peeringName": autorest.Encode("path", peeringName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/expressRouteCircuits/{circuitName}/peerings/{peeringName}/peerConnections", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListSender sends the List request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) ListSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListResponder handles the response to the List request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) ListResponder(resp *http.Response) (result PeerExpressRouteCircuitConnectionListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// listNextResults retrieves the next set of results, if any.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) listNextResults(ctx context.Context, lastResults PeerExpressRouteCircuitConnectionListResult) (result PeerExpressRouteCircuitConnectionListResult, err error) {
|
||||
req, err := lastResults.peerExpressRouteCircuitConnectionListResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.PeerExpressRouteCircuitConnectionsClient", "listNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.PeerExpressRouteCircuitConnectionsClient", "listNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PeerExpressRouteCircuitConnectionsClient", "listNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client PeerExpressRouteCircuitConnectionsClient) ListComplete(ctx context.Context, resourceGroupName string, circuitName string, peeringName string) (result PeerExpressRouteCircuitConnectionListResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PeerExpressRouteCircuitConnectionsClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
sc = result.page.Response().Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
result.page, err = client.List(ctx, resourceGroupName, circuitName, peeringName)
|
||||
return
|
||||
}
|
@ -25,29 +25,29 @@ import (
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// InterfaceEndpointsClient is the network Client
|
||||
type InterfaceEndpointsClient struct {
|
||||
// PrivateEndpointsClient is the network Client
|
||||
type PrivateEndpointsClient struct {
|
||||
BaseClient
|
||||
}
|
||||
|
||||
// NewInterfaceEndpointsClient creates an instance of the InterfaceEndpointsClient client.
|
||||
func NewInterfaceEndpointsClient(subscriptionID string) InterfaceEndpointsClient {
|
||||
return NewInterfaceEndpointsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
// NewPrivateEndpointsClient creates an instance of the PrivateEndpointsClient client.
|
||||
func NewPrivateEndpointsClient(subscriptionID string) PrivateEndpointsClient {
|
||||
return NewPrivateEndpointsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewInterfaceEndpointsClientWithBaseURI creates an instance of the InterfaceEndpointsClient client.
|
||||
func NewInterfaceEndpointsClientWithBaseURI(baseURI string, subscriptionID string) InterfaceEndpointsClient {
|
||||
return InterfaceEndpointsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
// NewPrivateEndpointsClientWithBaseURI creates an instance of the PrivateEndpointsClient client.
|
||||
func NewPrivateEndpointsClientWithBaseURI(baseURI string, subscriptionID string) PrivateEndpointsClient {
|
||||
return PrivateEndpointsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// CreateOrUpdate creates or updates an interface endpoint in the specified resource group.
|
||||
// CreateOrUpdate creates or updates an private endpoint in the specified resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// interfaceEndpointName - the name of the interface endpoint.
|
||||
// parameters - parameters supplied to the create or update interface endpoint operation
|
||||
func (client InterfaceEndpointsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, interfaceEndpointName string, parameters InterfaceEndpoint) (result InterfaceEndpointsCreateOrUpdateFuture, err error) {
|
||||
// privateEndpointName - the name of the private endpoint.
|
||||
// parameters - parameters supplied to the create or update private endpoint operation.
|
||||
func (client PrivateEndpointsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, privateEndpointName string, parameters PrivateEndpoint) (result PrivateEndpointsCreateOrUpdateFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/InterfaceEndpointsClient.CreateOrUpdate")
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PrivateEndpointsClient.CreateOrUpdate")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
@ -56,15 +56,15 @@ func (client InterfaceEndpointsClient) CreateOrUpdate(ctx context.Context, resou
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, interfaceEndpointName, parameters)
|
||||
req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, privateEndpointName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "CreateOrUpdate", nil, "Failure preparing request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "CreateOrUpdate", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
@ -72,14 +72,14 @@ func (client InterfaceEndpointsClient) CreateOrUpdate(ctx context.Context, resou
|
||||
}
|
||||
|
||||
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
|
||||
func (client InterfaceEndpointsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, interfaceEndpointName string, parameters InterfaceEndpoint) (*http.Request, error) {
|
||||
func (client PrivateEndpointsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, privateEndpointName string, parameters PrivateEndpoint) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"interfaceEndpointName": autorest.Encode("path", interfaceEndpointName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
"privateEndpointName": autorest.Encode("path", privateEndpointName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -88,7 +88,7 @@ func (client InterfaceEndpointsClient) CreateOrUpdatePreparer(ctx context.Contex
|
||||
autorest.AsContentType("application/json; charset=utf-8"),
|
||||
autorest.AsPut(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/interfaceEndpoints/{interfaceEndpointName}", pathParameters),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/privateEndpoints/{privateEndpointName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
@ -96,7 +96,7 @@ func (client InterfaceEndpointsClient) CreateOrUpdatePreparer(ctx context.Contex
|
||||
|
||||
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client InterfaceEndpointsClient) CreateOrUpdateSender(req *http.Request) (future InterfaceEndpointsCreateOrUpdateFuture, err error) {
|
||||
func (client PrivateEndpointsClient) CreateOrUpdateSender(req *http.Request) (future PrivateEndpointsCreateOrUpdateFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
@ -109,7 +109,7 @@ func (client InterfaceEndpointsClient) CreateOrUpdateSender(req *http.Request) (
|
||||
|
||||
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client InterfaceEndpointsClient) CreateOrUpdateResponder(resp *http.Response) (result InterfaceEndpoint, err error) {
|
||||
func (client PrivateEndpointsClient) CreateOrUpdateResponder(resp *http.Response) (result PrivateEndpoint, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
@ -120,13 +120,13 @@ func (client InterfaceEndpointsClient) CreateOrUpdateResponder(resp *http.Respon
|
||||
return
|
||||
}
|
||||
|
||||
// Delete deletes the specified interface endpoint.
|
||||
// Delete deletes the specified private endpoint.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// interfaceEndpointName - the name of the interface endpoint.
|
||||
func (client InterfaceEndpointsClient) Delete(ctx context.Context, resourceGroupName string, interfaceEndpointName string) (result InterfaceEndpointsDeleteFuture, err error) {
|
||||
// privateEndpointName - the name of the private endpoint.
|
||||
func (client PrivateEndpointsClient) Delete(ctx context.Context, resourceGroupName string, privateEndpointName string) (result PrivateEndpointsDeleteFuture, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/InterfaceEndpointsClient.Delete")
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PrivateEndpointsClient.Delete")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response() != nil {
|
||||
@ -135,15 +135,15 @@ func (client InterfaceEndpointsClient) Delete(ctx context.Context, resourceGroup
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.DeletePreparer(ctx, resourceGroupName, interfaceEndpointName)
|
||||
req, err := client.DeletePreparer(ctx, resourceGroupName, privateEndpointName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "Delete", nil, "Failure preparing request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "Delete", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "Delete", result.Response(), "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
@ -151,14 +151,14 @@ func (client InterfaceEndpointsClient) Delete(ctx context.Context, resourceGroup
|
||||
}
|
||||
|
||||
// DeletePreparer prepares the Delete request.
|
||||
func (client InterfaceEndpointsClient) DeletePreparer(ctx context.Context, resourceGroupName string, interfaceEndpointName string) (*http.Request, error) {
|
||||
func (client PrivateEndpointsClient) DeletePreparer(ctx context.Context, resourceGroupName string, privateEndpointName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"interfaceEndpointName": autorest.Encode("path", interfaceEndpointName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
"privateEndpointName": autorest.Encode("path", privateEndpointName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -166,14 +166,14 @@ func (client InterfaceEndpointsClient) DeletePreparer(ctx context.Context, resou
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsDelete(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/interfaceEndpoints/{interfaceEndpointName}", pathParameters),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/privateEndpoints/{privateEndpointName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// DeleteSender sends the Delete request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client InterfaceEndpointsClient) DeleteSender(req *http.Request) (future InterfaceEndpointsDeleteFuture, err error) {
|
||||
func (client PrivateEndpointsClient) DeleteSender(req *http.Request) (future PrivateEndpointsDeleteFuture, err error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
var resp *http.Response
|
||||
resp, err = autorest.SendWithSender(client, req, sd...)
|
||||
@ -186,7 +186,7 @@ func (client InterfaceEndpointsClient) DeleteSender(req *http.Request) (future I
|
||||
|
||||
// DeleteResponder handles the response to the Delete request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client InterfaceEndpointsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
|
||||
func (client PrivateEndpointsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
@ -196,14 +196,14 @@ func (client InterfaceEndpointsClient) DeleteResponder(resp *http.Response) (res
|
||||
return
|
||||
}
|
||||
|
||||
// Get gets the specified interface endpoint by resource group.
|
||||
// Get gets the specified private endpoint by resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// interfaceEndpointName - the name of the interface endpoint.
|
||||
// privateEndpointName - the name of the private endpoint.
|
||||
// expand - expands referenced resources.
|
||||
func (client InterfaceEndpointsClient) Get(ctx context.Context, resourceGroupName string, interfaceEndpointName string, expand string) (result InterfaceEndpoint, err error) {
|
||||
func (client PrivateEndpointsClient) Get(ctx context.Context, resourceGroupName string, privateEndpointName string, expand string) (result PrivateEndpoint, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/InterfaceEndpointsClient.Get")
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PrivateEndpointsClient.Get")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
@ -212,36 +212,36 @@ func (client InterfaceEndpointsClient) Get(ctx context.Context, resourceGroupNam
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.GetPreparer(ctx, resourceGroupName, interfaceEndpointName, expand)
|
||||
req, err := client.GetPreparer(ctx, resourceGroupName, privateEndpointName, expand)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "Get", nil, "Failure preparing request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "Get", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.GetSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "Get", resp, "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "Get", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "Get", resp, "Failure responding to request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "Get", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// GetPreparer prepares the Get request.
|
||||
func (client InterfaceEndpointsClient) GetPreparer(ctx context.Context, resourceGroupName string, interfaceEndpointName string, expand string) (*http.Request, error) {
|
||||
func (client PrivateEndpointsClient) GetPreparer(ctx context.Context, resourceGroupName string, privateEndpointName string, expand string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"interfaceEndpointName": autorest.Encode("path", interfaceEndpointName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
"privateEndpointName": autorest.Encode("path", privateEndpointName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -252,21 +252,21 @@ func (client InterfaceEndpointsClient) GetPreparer(ctx context.Context, resource
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/interfaceEndpoints/{interfaceEndpointName}", pathParameters),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/privateEndpoints/{privateEndpointName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// GetSender sends the Get request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client InterfaceEndpointsClient) GetSender(req *http.Request) (*http.Response, error) {
|
||||
func (client PrivateEndpointsClient) GetSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// GetResponder handles the response to the Get request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client InterfaceEndpointsClient) GetResponder(resp *http.Response) (result InterfaceEndpoint, err error) {
|
||||
func (client PrivateEndpointsClient) GetResponder(resp *http.Response) (result PrivateEndpoint, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
@ -277,16 +277,16 @@ func (client InterfaceEndpointsClient) GetResponder(resp *http.Response) (result
|
||||
return
|
||||
}
|
||||
|
||||
// List gets all interface endpoints in a resource group.
|
||||
// List gets all private endpoints in a resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
func (client InterfaceEndpointsClient) List(ctx context.Context, resourceGroupName string) (result InterfaceEndpointListResultPage, err error) {
|
||||
func (client PrivateEndpointsClient) List(ctx context.Context, resourceGroupName string) (result PrivateEndpointListResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/InterfaceEndpointsClient.List")
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PrivateEndpointsClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.ielr.Response.Response != nil {
|
||||
sc = result.ielr.Response.Response.StatusCode
|
||||
if result.pelr.Response.Response != nil {
|
||||
sc = result.pelr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
@ -294,33 +294,33 @@ func (client InterfaceEndpointsClient) List(ctx context.Context, resourceGroupNa
|
||||
result.fn = client.listNextResults
|
||||
req, err := client.ListPreparer(ctx, resourceGroupName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "List", nil, "Failure preparing request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "List", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.ielr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "List", resp, "Failure sending request")
|
||||
result.pelr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "List", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.ielr, err = client.ListResponder(resp)
|
||||
result.pelr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "List", resp, "Failure responding to request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "List", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListPreparer prepares the List request.
|
||||
func (client InterfaceEndpointsClient) ListPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
|
||||
func (client PrivateEndpointsClient) ListPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -328,21 +328,21 @@ func (client InterfaceEndpointsClient) ListPreparer(ctx context.Context, resourc
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/interfaceEndpoints", pathParameters),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/privateEndpoints", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListSender sends the List request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client InterfaceEndpointsClient) ListSender(req *http.Request) (*http.Response, error) {
|
||||
func (client PrivateEndpointsClient) ListSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListResponder handles the response to the List request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client InterfaceEndpointsClient) ListResponder(resp *http.Response) (result InterfaceEndpointListResult, err error) {
|
||||
func (client PrivateEndpointsClient) ListResponder(resp *http.Response) (result PrivateEndpointListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
@ -354,10 +354,10 @@ func (client InterfaceEndpointsClient) ListResponder(resp *http.Response) (resul
|
||||
}
|
||||
|
||||
// listNextResults retrieves the next set of results, if any.
|
||||
func (client InterfaceEndpointsClient) listNextResults(ctx context.Context, lastResults InterfaceEndpointListResult) (result InterfaceEndpointListResult, err error) {
|
||||
req, err := lastResults.interfaceEndpointListResultPreparer(ctx)
|
||||
func (client PrivateEndpointsClient) listNextResults(ctx context.Context, lastResults PrivateEndpointListResult) (result PrivateEndpointListResult, err error) {
|
||||
req, err := lastResults.privateEndpointListResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "listNextResults", nil, "Failure preparing next results request")
|
||||
return result, autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "listNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
@ -365,19 +365,19 @@ func (client InterfaceEndpointsClient) listNextResults(ctx context.Context, last
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "listNextResults", resp, "Failure sending next results request")
|
||||
return result, autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "listNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "listNextResults", resp, "Failure responding to next results request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "listNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client InterfaceEndpointsClient) ListComplete(ctx context.Context, resourceGroupName string) (result InterfaceEndpointListResultIterator, err error) {
|
||||
func (client PrivateEndpointsClient) ListComplete(ctx context.Context, resourceGroupName string) (result PrivateEndpointListResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/InterfaceEndpointsClient.List")
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PrivateEndpointsClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
||||
@ -390,14 +390,14 @@ func (client InterfaceEndpointsClient) ListComplete(ctx context.Context, resourc
|
||||
return
|
||||
}
|
||||
|
||||
// ListBySubscription gets all interface endpoints in a subscription.
|
||||
func (client InterfaceEndpointsClient) ListBySubscription(ctx context.Context) (result InterfaceEndpointListResultPage, err error) {
|
||||
// ListBySubscription gets all private endpoints in a subscription.
|
||||
func (client PrivateEndpointsClient) ListBySubscription(ctx context.Context) (result PrivateEndpointListResultPage, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/InterfaceEndpointsClient.ListBySubscription")
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PrivateEndpointsClient.ListBySubscription")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.ielr.Response.Response != nil {
|
||||
sc = result.ielr.Response.Response.StatusCode
|
||||
if result.pelr.Response.Response != nil {
|
||||
sc = result.pelr.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
@ -405,32 +405,32 @@ func (client InterfaceEndpointsClient) ListBySubscription(ctx context.Context) (
|
||||
result.fn = client.listBySubscriptionNextResults
|
||||
req, err := client.ListBySubscriptionPreparer(ctx)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "ListBySubscription", nil, "Failure preparing request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "ListBySubscription", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListBySubscriptionSender(req)
|
||||
if err != nil {
|
||||
result.ielr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "ListBySubscription", resp, "Failure sending request")
|
||||
result.pelr.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "ListBySubscription", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result.ielr, err = client.ListBySubscriptionResponder(resp)
|
||||
result.pelr, err = client.ListBySubscriptionResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "ListBySubscription", resp, "Failure responding to request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "ListBySubscription", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListBySubscriptionPreparer prepares the ListBySubscription request.
|
||||
func (client InterfaceEndpointsClient) ListBySubscriptionPreparer(ctx context.Context) (*http.Request, error) {
|
||||
func (client PrivateEndpointsClient) ListBySubscriptionPreparer(ctx context.Context) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -438,21 +438,21 @@ func (client InterfaceEndpointsClient) ListBySubscriptionPreparer(ctx context.Co
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Network/interfaceEndpoints", pathParameters),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Network/privateEndpoints", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListBySubscriptionSender sends the ListBySubscription request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client InterfaceEndpointsClient) ListBySubscriptionSender(req *http.Request) (*http.Response, error) {
|
||||
func (client PrivateEndpointsClient) ListBySubscriptionSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListBySubscriptionResponder handles the response to the ListBySubscription request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client InterfaceEndpointsClient) ListBySubscriptionResponder(resp *http.Response) (result InterfaceEndpointListResult, err error) {
|
||||
func (client PrivateEndpointsClient) ListBySubscriptionResponder(resp *http.Response) (result PrivateEndpointListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
@ -464,10 +464,10 @@ func (client InterfaceEndpointsClient) ListBySubscriptionResponder(resp *http.Re
|
||||
}
|
||||
|
||||
// listBySubscriptionNextResults retrieves the next set of results, if any.
|
||||
func (client InterfaceEndpointsClient) listBySubscriptionNextResults(ctx context.Context, lastResults InterfaceEndpointListResult) (result InterfaceEndpointListResult, err error) {
|
||||
req, err := lastResults.interfaceEndpointListResultPreparer(ctx)
|
||||
func (client PrivateEndpointsClient) listBySubscriptionNextResults(ctx context.Context, lastResults PrivateEndpointListResult) (result PrivateEndpointListResult, err error) {
|
||||
req, err := lastResults.privateEndpointListResultPreparer(ctx)
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "listBySubscriptionNextResults", nil, "Failure preparing next results request")
|
||||
return result, autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "listBySubscriptionNextResults", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
@ -475,19 +475,19 @@ func (client InterfaceEndpointsClient) listBySubscriptionNextResults(ctx context
|
||||
resp, err := client.ListBySubscriptionSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "listBySubscriptionNextResults", resp, "Failure sending next results request")
|
||||
return result, autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "listBySubscriptionNextResults", resp, "Failure sending next results request")
|
||||
}
|
||||
result, err = client.ListBySubscriptionResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsClient", "listBySubscriptionNextResults", resp, "Failure responding to next results request")
|
||||
err = autorest.NewErrorWithError(err, "network.PrivateEndpointsClient", "listBySubscriptionNextResults", resp, "Failure responding to next results request")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ListBySubscriptionComplete enumerates all values, automatically crossing page boundaries as required.
|
||||
func (client InterfaceEndpointsClient) ListBySubscriptionComplete(ctx context.Context) (result InterfaceEndpointListResultIterator, err error) {
|
||||
func (client PrivateEndpointsClient) ListBySubscriptionComplete(ctx context.Context) (result PrivateEndpointListResultIterator, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/InterfaceEndpointsClient.ListBySubscription")
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/PrivateEndpointsClient.ListBySubscription")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response().Response.Response != nil {
|
1050
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/privatelinkservices.go
generated
vendored
Normal file
1050
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/privatelinkservices.go
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
@ -85,7 +85,7 @@ func (client ProfilesClient) CreateOrUpdatePreparer(ctx context.Context, resourc
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -158,7 +158,7 @@ func (client ProfilesClient) DeletePreparer(ctx context.Context, resourceGroupNa
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -199,7 +199,7 @@ func (client ProfilesClient) DeleteResponder(resp *http.Response) (result autore
|
||||
// Get gets the specified network profile in a specified resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// networkProfileName - the name of the Public IP Prefix.
|
||||
// networkProfileName - the name of the public IP prefix.
|
||||
// expand - expands referenced resources.
|
||||
func (client ProfilesClient) Get(ctx context.Context, resourceGroupName string, networkProfileName string, expand string) (result Profile, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
@ -241,7 +241,7 @@ func (client ProfilesClient) GetPreparer(ctx context.Context, resourceGroupName
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -320,7 +320,7 @@ func (client ProfilesClient) ListPreparer(ctx context.Context, resourceGroupName
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -430,7 +430,7 @@ func (client ProfilesClient) ListAllPreparer(ctx context.Context) (*http.Request
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -545,7 +545,7 @@ func (client ProfilesClient) UpdateTagsPreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -91,7 +91,7 @@ func (client PublicIPAddressesClient) CreateOrUpdatePreparer(ctx context.Context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -170,7 +170,7 @@ func (client PublicIPAddressesClient) DeletePreparer(ctx context.Context, resour
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -253,7 +253,7 @@ func (client PublicIPAddressesClient) GetPreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -421,7 +421,7 @@ func (client PublicIPAddressesClient) ListPreparer(ctx context.Context, resource
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -531,7 +531,7 @@ func (client PublicIPAddressesClient) ListAllPreparer(ctx context.Context) (*htt
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -878,7 +878,7 @@ func (client PublicIPAddressesClient) UpdateTagsPreparer(ctx context.Context, re
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -79,7 +79,7 @@ func (client PublicIPPrefixesClient) CreateOrUpdatePreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -158,7 +158,7 @@ func (client PublicIPPrefixesClient) DeletePreparer(ctx context.Context, resourc
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -199,7 +199,7 @@ func (client PublicIPPrefixesClient) DeleteResponder(resp *http.Response) (resul
|
||||
// Get gets the specified public IP prefix in a specified resource group.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// publicIPPrefixName - the name of the Public IP Prefix.
|
||||
// publicIPPrefixName - the name of the public IP prefix.
|
||||
// expand - expands referenced resources.
|
||||
func (client PublicIPPrefixesClient) Get(ctx context.Context, resourceGroupName string, publicIPPrefixName string, expand string) (result PublicIPPrefix, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
@ -241,7 +241,7 @@ func (client PublicIPPrefixesClient) GetPreparer(ctx context.Context, resourceGr
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -320,7 +320,7 @@ func (client PublicIPPrefixesClient) ListPreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -430,7 +430,7 @@ func (client PublicIPPrefixesClient) ListAllPreparer(ctx context.Context) (*http
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -539,7 +539,7 @@ func (client PublicIPPrefixesClient) UpdateTagsPreparer(ctx context.Context, res
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
120
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/resourcenavigationlinks.go
generated
vendored
Normal file
120
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2019-06-01/network/resourcenavigationlinks.go
generated
vendored
Normal file
@ -0,0 +1,120 @@
|
||||
package network
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/tracing"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// ResourceNavigationLinksClient is the network Client
|
||||
type ResourceNavigationLinksClient struct {
|
||||
BaseClient
|
||||
}
|
||||
|
||||
// NewResourceNavigationLinksClient creates an instance of the ResourceNavigationLinksClient client.
|
||||
func NewResourceNavigationLinksClient(subscriptionID string) ResourceNavigationLinksClient {
|
||||
return NewResourceNavigationLinksClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewResourceNavigationLinksClientWithBaseURI creates an instance of the ResourceNavigationLinksClient client.
|
||||
func NewResourceNavigationLinksClientWithBaseURI(baseURI string, subscriptionID string) ResourceNavigationLinksClient {
|
||||
return ResourceNavigationLinksClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// List gets a list of resource navigation links for a subnet.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// virtualNetworkName - the name of the virtual network.
|
||||
// subnetName - the name of the subnet.
|
||||
func (client ResourceNavigationLinksClient) List(ctx context.Context, resourceGroupName string, virtualNetworkName string, subnetName string) (result ResourceNavigationLinksListResult, err error) {
|
||||
if tracing.IsEnabled() {
|
||||
ctx = tracing.StartSpan(ctx, fqdn+"/ResourceNavigationLinksClient.List")
|
||||
defer func() {
|
||||
sc := -1
|
||||
if result.Response.Response != nil {
|
||||
sc = result.Response.Response.StatusCode
|
||||
}
|
||||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
req, err := client.ListPreparer(ctx, resourceGroupName, virtualNetworkName, subnetName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ResourceNavigationLinksClient", "List", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "network.ResourceNavigationLinksClient", "List", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ResourceNavigationLinksClient", "List", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListPreparer prepares the List request.
|
||||
func (client ResourceNavigationLinksClient) ListPreparer(ctx context.Context, resourceGroupName string, virtualNetworkName string, subnetName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subnetName": autorest.Encode("path", subnetName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
"virtualNetworkName": autorest.Encode("path", virtualNetworkName),
|
||||
}
|
||||
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualNetworks/{virtualNetworkName}/subnets/{subnetName}/ResourceNavigationLinks", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare((&http.Request{}).WithContext(ctx))
|
||||
}
|
||||
|
||||
// ListSender sends the List request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ResourceNavigationLinksClient) ListSender(req *http.Request) (*http.Response, error) {
|
||||
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
|
||||
return autorest.SendWithSender(client, req, sd...)
|
||||
}
|
||||
|
||||
// ListResponder handles the response to the List request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ResourceNavigationLinksClient) ListResponder(resp *http.Response) (result ResourceNavigationLinksListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
@ -91,7 +91,7 @@ func (client RouteFilterRulesClient) CreateOrUpdatePreparer(ctx context.Context,
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -173,7 +173,7 @@ func (client RouteFilterRulesClient) DeletePreparer(ctx context.Context, resourc
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -257,7 +257,7 @@ func (client RouteFilterRulesClient) GetPreparer(ctx context.Context, resourceGr
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -335,7 +335,7 @@ func (client RouteFilterRulesClient) ListByRouteFilterPreparer(ctx context.Conte
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -446,7 +446,7 @@ func (client RouteFilterRulesClient) UpdatePreparer(ctx context.Context, resourc
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -79,7 +79,7 @@ func (client RouteFiltersClient) CreateOrUpdatePreparer(ctx context.Context, res
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -159,7 +159,7 @@ func (client RouteFiltersClient) DeletePreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -242,7 +242,7 @@ func (client RouteFiltersClient) GetPreparer(ctx context.Context, resourceGroupN
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -318,7 +318,7 @@ func (client RouteFiltersClient) ListPreparer(ctx context.Context) (*http.Reques
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -431,7 +431,7 @@ func (client RouteFiltersClient) ListByResourceGroupPreparer(ctx context.Context
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -540,7 +540,7 @@ func (client RouteFiltersClient) UpdatePreparer(ctx context.Context, resourceGro
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
@ -81,7 +81,7 @@ func (client RoutesClient) CreateOrUpdatePreparer(ctx context.Context, resourceG
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -162,7 +162,7 @@ func (client RoutesClient) DeletePreparer(ctx context.Context, resourceGroupName
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -246,7 +246,7 @@ func (client RoutesClient) GetPreparer(ctx context.Context, resourceGroupName st
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
@ -324,7 +324,7 @@ func (client RoutesClient) ListPreparer(ctx context.Context, resourceGroupName s
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2018-08-01"
|
||||
const APIVersion = "2019-06-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user