...

Source file src/github.com/Azure/azure-sdk-for-go/services/preview/resources/mgmt/2019-06-01-preview/templatespecs/client.go

Documentation: github.com/Azure/azure-sdk-for-go/services/preview/resources/mgmt/2019-06-01-preview/templatespecs

     1  // Deprecated: Please note, this package has been deprecated. A replacement package is available [github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/resources/armtemplatespecs](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/resources/armtemplatespecs). We strongly encourage you to upgrade to continue receiving updates. See [Migration Guide](https://aka.ms/azsdk/golang/t2/migration) for guidance on upgrading. Refer to our [deprecation policy](https://azure.github.io/azure-sdk/policies_support.html) for more details.
     2  //
     3  // Package templatespecs implements the Azure ARM Templatespecs service API version 2019-06-01-preview.
     4  //
     5  // The APIs listed in this specification can be used to manage Template Spec resources through the Azure Resource
     6  // Manager.
     7  package templatespecs
     8  
     9  // Copyright (c) Microsoft Corporation. All rights reserved.
    10  // Licensed under the MIT License. See License.txt in the project root for license information.
    11  //
    12  // Code generated by Microsoft (R) AutoRest Code Generator.
    13  // Changes may cause incorrect behavior and will be lost if the code is regenerated.
    14  
    15  import (
    16  	"github.com/Azure/go-autorest/autorest"
    17  )
    18  
    19  const (
    20  	// DefaultBaseURI is the default URI used for the service Templatespecs
    21  	DefaultBaseURI = "https://management.azure.com"
    22  )
    23  
    24  // BaseClient is the base client for Templatespecs.
    25  type BaseClient struct {
    26  	autorest.Client
    27  	BaseURI        string
    28  	SubscriptionID string
    29  }
    30  
    31  // New creates an instance of the BaseClient client.
    32  func New(subscriptionID string) BaseClient {
    33  	return NewWithBaseURI(DefaultBaseURI, subscriptionID)
    34  }
    35  
    36  // NewWithBaseURI creates an instance of the BaseClient client using a custom endpoint.  Use this when interacting with
    37  // an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
    38  func NewWithBaseURI(baseURI string, subscriptionID string) BaseClient {
    39  	return BaseClient{
    40  		Client:         autorest.NewClientWithUserAgent(UserAgent()),
    41  		BaseURI:        baseURI,
    42  		SubscriptionID: subscriptionID,
    43  	}
    44  }
    45  

View as plain text