const ( // DefaultBaseURI is the default URI used for the service Softwareplan DefaultBaseURI = "https://management.azure.com" )
func UserAgent() string
UserAgent returns the UserAgent string to use when sending http.Requests.
func Version() string
Version returns the semantic version (see http://semver.org) of the client.
AzureEntityResource the resource model definition for an Azure Resource Manager resource with an etag.
type AzureEntityResource struct { // Etag - READ-ONLY; Resource Etag. Etag *string `json:"etag,omitempty"` // ID - READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty"` // Name - READ-ONLY; The name of the resource Name *string `json:"name,omitempty"` // Type - READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty"` }
func (aer AzureEntityResource) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for AzureEntityResource.
BaseClient is the base client for Softwareplan.
type BaseClient struct { autorest.Client BaseURI string SubscriptionID string }
func New(subscriptionID string) BaseClient
New creates an instance of the BaseClient client.
func NewWithBaseURI(baseURI string, subscriptionID string) BaseClient
NewWithBaseURI creates an instance of the BaseClient client using a custom endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
Client is the azure software plans let users create and manage licenses for various software used in Azure.
type Client struct { BaseClient }
func NewClient(subscriptionID string) Client
NewClient creates an instance of the Client client.
func NewClientWithBaseURI(baseURI string, subscriptionID string) Client
NewClientWithBaseURI creates an instance of the Client client using a custom endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
func (client Client) Register(ctx context.Context) (result autorest.Response, err error)
Register register to Microsoft.SoftwarePlan resource provider.
func (client Client) RegisterPreparer(ctx context.Context) (*http.Request, error)
RegisterPreparer prepares the Register request.
func (client Client) RegisterResponder(resp *http.Response) (result autorest.Response, err error)
RegisterResponder handles the response to the Register request. The method always closes the http.Response Body.
func (client Client) RegisterSender(req *http.Request) (*http.Response, error)
RegisterSender sends the Register request. The method will close the http.Response Body if it receives an error.
Error error object returned by the RP
type Error struct { // Code - Error code. Possible values include: 'InvalidRequestParameter', 'MissingRequestParameter' Code ErrorCode `json:"code,omitempty"` // Message - A user readable error message. Localized based on x-ms-effective-locale header in the request Message *string `json:"message,omitempty"` }
ErrorCode enumerates the values for error code.
type ErrorCode string
const ( // InvalidRequestParameter ... InvalidRequestParameter ErrorCode = "InvalidRequestParameter" // MissingRequestParameter ... MissingRequestParameter ErrorCode = "MissingRequestParameter" )
func PossibleErrorCodeValues() []ErrorCode
PossibleErrorCodeValues returns an array of possible values for the ErrorCode const type.
HybridUseBenefitClient is the azure software plans let users create and manage licenses for various software used in Azure.
type HybridUseBenefitClient struct { BaseClient }
func NewHybridUseBenefitClient(subscriptionID string) HybridUseBenefitClient
NewHybridUseBenefitClient creates an instance of the HybridUseBenefitClient client.
func NewHybridUseBenefitClientWithBaseURI(baseURI string, subscriptionID string) HybridUseBenefitClient
NewHybridUseBenefitClientWithBaseURI creates an instance of the HybridUseBenefitClient client using a custom endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
func (client HybridUseBenefitClient) Create(ctx context.Context, scope string, planID string, body HybridUseBenefitModel) (result HybridUseBenefitModel, err error)
Create create a new hybrid use benefit under a given scope Parameters: scope - the scope at which the operation is performed. This is limited to Microsoft.Compute/virtualMachines and Microsoft.Compute/hostGroups/hosts for now planID - this is a unique identifier for a plan. Should be a guid. body - request body for creating a hybrid use benefit
func (client HybridUseBenefitClient) CreatePreparer(ctx context.Context, scope string, planID string, body HybridUseBenefitModel) (*http.Request, error)
CreatePreparer prepares the Create request.
func (client HybridUseBenefitClient) CreateResponder(resp *http.Response) (result HybridUseBenefitModel, err error)
CreateResponder handles the response to the Create request. The method always closes the http.Response Body.
func (client HybridUseBenefitClient) CreateSender(req *http.Request) (*http.Response, error)
CreateSender sends the Create request. The method will close the http.Response Body if it receives an error.
func (client HybridUseBenefitClient) Delete(ctx context.Context, scope string, planID string) (result autorest.Response, err error)
Delete deletes a given plan ID Parameters: scope - the scope at which the operation is performed. This is limited to Microsoft.Compute/virtualMachines and Microsoft.Compute/hostGroups/hosts for now planID - this is a unique identifier for a plan. Should be a guid.
func (client HybridUseBenefitClient) DeletePreparer(ctx context.Context, scope string, planID string) (*http.Request, error)
DeletePreparer prepares the Delete request.
func (client HybridUseBenefitClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error)
DeleteResponder handles the response to the Delete request. The method always closes the http.Response Body.
func (client HybridUseBenefitClient) DeleteSender(req *http.Request) (*http.Response, error)
DeleteSender sends the Delete request. The method will close the http.Response Body if it receives an error.
func (client HybridUseBenefitClient) Get(ctx context.Context, scope string, planID string) (result HybridUseBenefitModel, err error)
Get gets a given plan ID Parameters: scope - the scope at which the operation is performed. This is limited to Microsoft.Compute/virtualMachines and Microsoft.Compute/hostGroups/hosts for now planID - this is a unique identifier for a plan. Should be a guid.
func (client HybridUseBenefitClient) GetPreparer(ctx context.Context, scope string, planID string) (*http.Request, error)
GetPreparer prepares the Get request.
func (client HybridUseBenefitClient) GetResponder(resp *http.Response) (result HybridUseBenefitModel, err error)
GetResponder handles the response to the Get request. The method always closes the http.Response Body.
func (client HybridUseBenefitClient) GetSender(req *http.Request) (*http.Response, error)
GetSender sends the Get request. The method will close the http.Response Body if it receives an error.
func (client HybridUseBenefitClient) List(ctx context.Context, scope string, filter string) (result HybridUseBenefitListResultPage, err error)
List get all hybrid use benefits associated with an ARM resource. Parameters: scope - the scope at which the operation is performed. This is limited to Microsoft.Compute/virtualMachines and Microsoft.Compute/hostGroups/hosts for now filter - supports applying filter on the type of SKU
func (client HybridUseBenefitClient) ListComplete(ctx context.Context, scope string, filter string) (result HybridUseBenefitListResultIterator, err error)
ListComplete enumerates all values, automatically crossing page boundaries as required.
func (client HybridUseBenefitClient) ListPreparer(ctx context.Context, scope string, filter string) (*http.Request, error)
ListPreparer prepares the List request.
func (client HybridUseBenefitClient) ListResponder(resp *http.Response) (result HybridUseBenefitListResult, err error)
ListResponder handles the response to the List request. The method always closes the http.Response Body.
func (client HybridUseBenefitClient) ListSender(req *http.Request) (*http.Response, error)
ListSender sends the List request. The method will close the http.Response Body if it receives an error.
func (client HybridUseBenefitClient) Update(ctx context.Context, scope string, planID string, body HybridUseBenefitModel) (result HybridUseBenefitModel, err error)
Update updates an existing hybrid use benefit Parameters: scope - the scope at which the operation is performed. This is limited to Microsoft.Compute/virtualMachines and Microsoft.Compute/hostGroups/hosts for now planID - this is a unique identifier for a plan. Should be a guid. body - request body for creating a hybrid use benefit
func (client HybridUseBenefitClient) UpdatePreparer(ctx context.Context, scope string, planID string, body HybridUseBenefitModel) (*http.Request, error)
UpdatePreparer prepares the Update request.
func (client HybridUseBenefitClient) UpdateResponder(resp *http.Response) (result HybridUseBenefitModel, err error)
UpdateResponder handles the response to the Update request. The method always closes the http.Response Body.
func (client HybridUseBenefitClient) UpdateSender(req *http.Request) (*http.Response, error)
UpdateSender sends the Update request. The method will close the http.Response Body if it receives an error.
HybridUseBenefitListResult list of hybrid use benefits
type HybridUseBenefitListResult struct { autorest.Response `json:"-"` // Value - List of hybrid use benefits Value *[]HybridUseBenefitModel `json:"value,omitempty"` // NextLink - Url to get the next page of items. NextLink *string `json:"nextLink,omitempty"` }
func (hublr HybridUseBenefitListResult) IsEmpty() bool
IsEmpty returns true if the ListResult contains no values.
HybridUseBenefitListResultIterator provides access to a complete listing of HybridUseBenefitModel values.
type HybridUseBenefitListResultIterator struct {
// contains filtered or unexported fields
}
func NewHybridUseBenefitListResultIterator(page HybridUseBenefitListResultPage) HybridUseBenefitListResultIterator
Creates a new instance of the HybridUseBenefitListResultIterator type.
func (iter *HybridUseBenefitListResultIterator) Next() error
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 *HybridUseBenefitListResultIterator) NextWithContext(ctx context.Context) (err error)
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 HybridUseBenefitListResultIterator) NotDone() bool
NotDone returns true if the enumeration should be started or is not yet complete.
func (iter HybridUseBenefitListResultIterator) Response() HybridUseBenefitListResult
Response returns the raw server response from the last page request.
func (iter HybridUseBenefitListResultIterator) Value() HybridUseBenefitModel
Value returns the current value or a zero-initialized value if the iterator has advanced beyond the end of the collection.
HybridUseBenefitListResultPage contains a page of HybridUseBenefitModel values.
type HybridUseBenefitListResultPage struct {
// contains filtered or unexported fields
}
func NewHybridUseBenefitListResultPage(cur HybridUseBenefitListResult, getNextPage func(context.Context, HybridUseBenefitListResult) (HybridUseBenefitListResult, error)) HybridUseBenefitListResultPage
Creates a new instance of the HybridUseBenefitListResultPage type.
func (page *HybridUseBenefitListResultPage) Next() error
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 *HybridUseBenefitListResultPage) NextWithContext(ctx context.Context) (err error)
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 HybridUseBenefitListResultPage) NotDone() bool
NotDone returns true if the page enumeration should be started or is not yet complete.
func (page HybridUseBenefitListResultPage) Response() HybridUseBenefitListResult
Response returns the raw server response from the last page request.
func (page HybridUseBenefitListResultPage) Values() []HybridUseBenefitModel
Values returns the slice of values for the current page or nil if there are no values.
HybridUseBenefitModel response on GET of a hybrid use benefit
type HybridUseBenefitModel struct { autorest.Response `json:"-"` // Sku - Hybrid use benefit SKU Sku *Sku `json:"sku,omitempty"` // Etag - READ-ONLY; Indicates the revision of the hybrid use benefit Etag *int32 `json:"etag,omitempty"` // HybridUseBenefitProperties - Property bag for a hybrid use benefit response *HybridUseBenefitProperties `json:"properties,omitempty"` // ID - READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty"` // Name - READ-ONLY; The name of the resource Name *string `json:"name,omitempty"` // Type - READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty"` }
func (hubm HybridUseBenefitModel) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for HybridUseBenefitModel.
func (hubm *HybridUseBenefitModel) UnmarshalJSON(body []byte) error
UnmarshalJSON is the custom unmarshaler for HybridUseBenefitModel struct.
HybridUseBenefitProperties hybrid use benefit properties
type HybridUseBenefitProperties struct { // ProvisioningState - READ-ONLY; Provisioning state. Possible values include: 'Succeeded', 'Cancelled', 'Failed' ProvisioningState ProvisioningState `json:"provisioningState,omitempty"` // CreatedDate - READ-ONLY; Created date CreatedDate *date.Time `json:"createdDate,omitempty"` // LastUpdatedDate - READ-ONLY; Last updated date LastUpdatedDate *date.Time `json:"lastUpdatedDate,omitempty"` }
func (hubp HybridUseBenefitProperties) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for HybridUseBenefitProperties.
HybridUseBenefitRevisionClient is the azure software plans let users create and manage licenses for various software used in Azure.
type HybridUseBenefitRevisionClient struct { BaseClient }
func NewHybridUseBenefitRevisionClient(subscriptionID string) HybridUseBenefitRevisionClient
NewHybridUseBenefitRevisionClient creates an instance of the HybridUseBenefitRevisionClient client.
func NewHybridUseBenefitRevisionClientWithBaseURI(baseURI string, subscriptionID string) HybridUseBenefitRevisionClient
NewHybridUseBenefitRevisionClientWithBaseURI creates an instance of the HybridUseBenefitRevisionClient client using a custom endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
func (client HybridUseBenefitRevisionClient) List(ctx context.Context, scope string, planID string) (result HybridUseBenefitListResultPage, err error)
List gets the version history of a hybrid use benefit Parameters: scope - the scope at which the operation is performed. This is limited to Microsoft.Compute/virtualMachines and Microsoft.Compute/hostGroups/hosts for now planID - this is a unique identifier for a plan. Should be a guid.
func (client HybridUseBenefitRevisionClient) ListComplete(ctx context.Context, scope string, planID string) (result HybridUseBenefitListResultIterator, err error)
ListComplete enumerates all values, automatically crossing page boundaries as required.
func (client HybridUseBenefitRevisionClient) ListPreparer(ctx context.Context, scope string, planID string) (*http.Request, error)
ListPreparer prepares the List request.
func (client HybridUseBenefitRevisionClient) ListResponder(resp *http.Response) (result HybridUseBenefitListResult, err error)
ListResponder handles the response to the List request. The method always closes the http.Response Body.
func (client HybridUseBenefitRevisionClient) ListSender(req *http.Request) (*http.Response, error)
ListSender sends the List request. The method will close the http.Response Body if it receives an error.
OperationDisplay display fields for an operation.
type OperationDisplay struct { // Provider - Resource Provider name Provider *string `json:"provider,omitempty"` // Resource - Resource that is acted upon Resource *string `json:"resource,omitempty"` // Operation - Operation to be performed Operation *string `json:"operation,omitempty"` // Description - Description of the operation Description *string `json:"description,omitempty"` }
OperationList list all the operations.
type OperationList struct { autorest.Response `json:"-"` // Value - List of all operations Value *[]OperationResponse `json:"value,omitempty"` // NextLink - Url to get the next page of items. NextLink *string `json:"nextLink,omitempty"` }
func (ol OperationList) IsEmpty() bool
IsEmpty returns true if the ListResult contains no values.
OperationListIterator provides access to a complete listing of OperationResponse values.
type OperationListIterator struct {
// contains filtered or unexported fields
}
func NewOperationListIterator(page OperationListPage) OperationListIterator
Creates a new instance of the OperationListIterator type.
func (iter *OperationListIterator) Next() error
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 *OperationListIterator) NextWithContext(ctx context.Context) (err error)
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 OperationListIterator) NotDone() bool
NotDone returns true if the enumeration should be started or is not yet complete.
func (iter OperationListIterator) Response() OperationList
Response returns the raw server response from the last page request.
func (iter OperationListIterator) Value() OperationResponse
Value returns the current value or a zero-initialized value if the iterator has advanced beyond the end of the collection.
OperationListPage contains a page of OperationResponse values.
type OperationListPage struct {
// contains filtered or unexported fields
}
func NewOperationListPage(cur OperationList, getNextPage func(context.Context, OperationList) (OperationList, error)) OperationListPage
Creates a new instance of the OperationListPage type.
func (page *OperationListPage) Next() error
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 *OperationListPage) NextWithContext(ctx context.Context) (err error)
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 OperationListPage) NotDone() bool
NotDone returns true if the page enumeration should be started or is not yet complete.
func (page OperationListPage) Response() OperationList
Response returns the raw server response from the last page request.
func (page OperationListPage) Values() []OperationResponse
Values returns the slice of values for the current page or nil if there are no values.
OperationResponse operation response.
type OperationResponse struct { // Name - Name of the operation Name *string `json:"name,omitempty"` // Display - Display properties for the operation Display *OperationDisplay `json:"display,omitempty"` // Origin - Origin of the response Origin *string `json:"origin,omitempty"` }
OperationsClient is the azure software plans let users create and manage licenses for various software used in Azure.
type OperationsClient struct { BaseClient }
func NewOperationsClient(subscriptionID string) OperationsClient
NewOperationsClient creates an instance of the OperationsClient client.
func NewOperationsClientWithBaseURI(baseURI string, subscriptionID string) OperationsClient
NewOperationsClientWithBaseURI creates an instance of the OperationsClient client using a custom endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
func (client OperationsClient) List(ctx context.Context, scope string) (result OperationListPage, err error)
List list all the operations. Parameters: scope - the scope at which the operation is performed. This is limited to Microsoft.Compute/virtualMachines and Microsoft.Compute/hostGroups/hosts for now
func (client OperationsClient) ListComplete(ctx context.Context, scope string) (result OperationListIterator, err error)
ListComplete enumerates all values, automatically crossing page boundaries as required.
func (client OperationsClient) ListPreparer(ctx context.Context, scope string) (*http.Request, error)
ListPreparer prepares the List request.
func (client OperationsClient) ListResponder(resp *http.Response) (result OperationList, err error)
ListResponder handles the response to the List request. The method always closes the http.Response Body.
func (client OperationsClient) ListSender(req *http.Request) (*http.Response, error)
ListSender sends the List request. The method will close the http.Response Body if it receives an error.
ProvisioningState enumerates the values for provisioning state.
type ProvisioningState string
const ( // Cancelled ... Cancelled ProvisioningState = "Cancelled" // Failed ... Failed ProvisioningState = "Failed" // Succeeded ... Succeeded ProvisioningState = "Succeeded" )
func PossibleProvisioningStateValues() []ProvisioningState
PossibleProvisioningStateValues returns an array of possible values for the ProvisioningState const type.
ProxyResource the resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location
type ProxyResource struct { // ID - READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty"` // Name - READ-ONLY; The name of the resource Name *string `json:"name,omitempty"` // Type - READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty"` }
func (pr ProxyResource) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for ProxyResource.
Resource common fields that are returned in the response for all Azure Resource Manager resources
type Resource struct { // ID - READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty"` // Name - READ-ONLY; The name of the resource Name *string `json:"name,omitempty"` // Type - READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty"` }
func (r Resource) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for Resource.
Sku the SKU to be applied for this resource
type Sku struct { // Name - Name of the SKU to be applied Name *string `json:"name,omitempty"` }
TrackedResource the resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location'
type TrackedResource struct { // Tags - Resource tags. Tags map[string]*string `json:"tags"` // Location - The geo-location where the resource lives Location *string `json:"location,omitempty"` // ID - READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty"` // Name - READ-ONLY; The name of the resource Name *string `json:"name,omitempty"` // Type - READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty"` }
func (tr TrackedResource) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for TrackedResource.
Name | Synopsis |
---|---|
.. | |
softwareplanapi |