updates

package
v0.20230530.1074937 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 30, 2023 License: MPL-2.0 Imports: 9 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/maintenance/2021-05-01/updates Documentation

The updates SDK allows for interaction with the Azure Resource Manager Service maintenance (API Version 2021-05-01).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/maintenance/2021-05-01/updates"

Client Initialization

client := updates.NewUpdatesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: UpdatesClient.List

ctx := context.TODO()
id := updates.NewProviderID("12345678-1234-9876-4563-123456789012", "example-resource-group", "providerValue", "resourceTypeValue", "resourceValue")

read, err := client.List(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: UpdatesClient.ListParent

ctx := context.TODO()
id := updates.NewResourceGroupProviderID("12345678-1234-9876-4563-123456789012", "example-resource-group", "providerValue", "resourceParentTypeValue", "resourceParentValue", "resourceTypeValue", "resourceValue")

read, err := client.ListParent(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForImpactType

func PossibleValuesForImpactType() []string

func PossibleValuesForMaintenanceScope

func PossibleValuesForMaintenanceScope() []string

func PossibleValuesForUpdateStatus

func PossibleValuesForUpdateStatus() []string

func ValidateProviderID

func ValidateProviderID(input interface{}, key string) (warnings []string, errors []error)

ValidateProviderID checks that 'input' can be parsed as a Provider ID

func ValidateResourceGroupProviderID

func ValidateResourceGroupProviderID(input interface{}, key string) (warnings []string, errors []error)

ValidateResourceGroupProviderID checks that 'input' can be parsed as a Resource Group Provider ID

Types

type ImpactType

type ImpactType string
const (
	ImpactTypeFreeze   ImpactType = "Freeze"
	ImpactTypeNone     ImpactType = "None"
	ImpactTypeRedeploy ImpactType = "Redeploy"
	ImpactTypeRestart  ImpactType = "Restart"
)

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	Model        *ListUpdatesResult
}

type ListParentOperationResponse

type ListParentOperationResponse struct {
	HttpResponse *http.Response
	Model        *ListUpdatesResult
}

type ListUpdatesResult

type ListUpdatesResult struct {
	Value *[]Update `json:"value,omitempty"`
}

type MaintenanceScope

type MaintenanceScope string
const (
	MaintenanceScopeExtension          MaintenanceScope = "Extension"
	MaintenanceScopeHost               MaintenanceScope = "Host"
	MaintenanceScopeInGuestPatch       MaintenanceScope = "InGuestPatch"
	MaintenanceScopeOSImage            MaintenanceScope = "OSImage"
	MaintenanceScopeSQLDB              MaintenanceScope = "SQLDB"
	MaintenanceScopeSQLManagedInstance MaintenanceScope = "SQLManagedInstance"
)

type ProviderId

type ProviderId struct {
	SubscriptionId    string
	ResourceGroupName string
	ProviderName      string
	ResourceType      string
	ResourceName      string
}

ProviderId is a struct representing the Resource ID for a Provider

func NewProviderID

func NewProviderID(subscriptionId string, resourceGroupName string, providerName string, resourceType string, resourceName string) ProviderId

NewProviderID returns a new ProviderId struct

func ParseProviderID

func ParseProviderID(input string) (*ProviderId, error)

ParseProviderID parses 'input' into a ProviderId

func ParseProviderIDInsensitively

func ParseProviderIDInsensitively(input string) (*ProviderId, error)

ParseProviderIDInsensitively parses 'input' case-insensitively into a ProviderId note: this method should only be used for API response data and not user input

func (ProviderId) ID

func (id ProviderId) ID() string

ID returns the formatted Provider ID

func (ProviderId) Segments

func (id ProviderId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Provider ID

func (ProviderId) String

func (id ProviderId) String() string

String returns a human-readable description of this Provider ID

type ResourceGroupProviderId

type ResourceGroupProviderId struct {
	SubscriptionId     string
	ResourceGroupName  string
	ProviderName       string
	ResourceParentType string
	ResourceParentName string
	ResourceType       string
	ResourceName       string
}

ResourceGroupProviderId is a struct representing the Resource ID for a Resource Group Provider

func NewResourceGroupProviderID

func NewResourceGroupProviderID(subscriptionId string, resourceGroupName string, providerName string, resourceParentType string, resourceParentName string, resourceType string, resourceName string) ResourceGroupProviderId

NewResourceGroupProviderID returns a new ResourceGroupProviderId struct

func ParseResourceGroupProviderID

func ParseResourceGroupProviderID(input string) (*ResourceGroupProviderId, error)

ParseResourceGroupProviderID parses 'input' into a ResourceGroupProviderId

func ParseResourceGroupProviderIDInsensitively

func ParseResourceGroupProviderIDInsensitively(input string) (*ResourceGroupProviderId, error)

ParseResourceGroupProviderIDInsensitively parses 'input' case-insensitively into a ResourceGroupProviderId note: this method should only be used for API response data and not user input

func (ResourceGroupProviderId) ID

ID returns the formatted Resource Group Provider ID

func (ResourceGroupProviderId) Segments

Segments returns a slice of Resource ID Segments which comprise this Resource Group Provider ID

func (ResourceGroupProviderId) String

func (id ResourceGroupProviderId) String() string

String returns a human-readable description of this Resource Group Provider ID

type Update

type Update struct {
	ImpactDurationInSec *int64            `json:"impactDurationInSec,omitempty"`
	ImpactType          *ImpactType       `json:"impactType,omitempty"`
	MaintenanceScope    *MaintenanceScope `json:"maintenanceScope,omitempty"`
	NotBefore           *string           `json:"notBefore,omitempty"`
	Properties          *UpdateProperties `json:"properties,omitempty"`
	Status              *UpdateStatus     `json:"status,omitempty"`
}

func (*Update) GetNotBeforeAsTime

func (o *Update) GetNotBeforeAsTime() (*time.Time, error)

func (*Update) SetNotBeforeAsTime

func (o *Update) SetNotBeforeAsTime(input time.Time)

type UpdateProperties

type UpdateProperties struct {
	ResourceId *string `json:"resourceId,omitempty"`
}

type UpdateStatus

type UpdateStatus string
const (
	UpdateStatusCompleted  UpdateStatus = "Completed"
	UpdateStatusInProgress UpdateStatus = "InProgress"
	UpdateStatusPending    UpdateStatus = "Pending"
	UpdateStatusRetryLater UpdateStatus = "RetryLater"
	UpdateStatusRetryNow   UpdateStatus = "RetryNow"
)

type UpdatesClient

type UpdatesClient struct {
	Client autorest.Client
	// contains filtered or unexported fields
}

func NewUpdatesClientWithBaseURI

func NewUpdatesClientWithBaseURI(endpoint string) UpdatesClient

func (UpdatesClient) List

func (c UpdatesClient) List(ctx context.Context, id ProviderId) (result ListOperationResponse, err error)

List ...

func (UpdatesClient) ListParent

ListParent ...

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL