virtualnetworklinks

package
v0.20240320.1143605 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2024 License: MPL-2.0 Imports: 11 Imported by: 1

README

The virtualnetworklinks SDK allows for interaction with the Azure Resource Manager Service privatedns (API Version 2020-06-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/privatedns/2020-06-01/virtualnetworklinks"

Client Initialization

client := virtualnetworklinks.NewVirtualNetworkLinksClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: VirtualNetworkLinksClient.CreateOrUpdate

ctx := context.TODO()
id := virtualnetworklinks.NewVirtualNetworkLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "privateDnsZoneValue", "virtualNetworkLinkValue")

payload := virtualnetworklinks.VirtualNetworkLink{
	// ...
}


if err := client.CreateOrUpdateThenPoll(ctx, id, payload, virtualnetworklinks.DefaultCreateOrUpdateOperationOptions()); err != nil {
	// handle the error
}

Example Usage: VirtualNetworkLinksClient.Delete

ctx := context.TODO()
id := virtualnetworklinks.NewVirtualNetworkLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "privateDnsZoneValue", "virtualNetworkLinkValue")

if err := client.DeleteThenPoll(ctx, id, virtualnetworklinks.DefaultDeleteOperationOptions()); err != nil {
	// handle the error
}

Example Usage: VirtualNetworkLinksClient.Get

ctx := context.TODO()
id := virtualnetworklinks.NewVirtualNetworkLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "privateDnsZoneValue", "virtualNetworkLinkValue")

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

Example Usage: VirtualNetworkLinksClient.List

ctx := context.TODO()
id := virtualnetworklinks.NewPrivateDnsZoneID("12345678-1234-9876-4563-123456789012", "example-resource-group", "privateDnsZoneValue")

// alternatively `client.List(ctx, id, virtualnetworklinks.DefaultListOperationOptions())` can be used to do batched pagination
items, err := client.ListComplete(ctx, id, virtualnetworklinks.DefaultListOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: VirtualNetworkLinksClient.Update

ctx := context.TODO()
id := virtualnetworklinks.NewVirtualNetworkLinkID("12345678-1234-9876-4563-123456789012", "example-resource-group", "privateDnsZoneValue", "virtualNetworkLinkValue")

payload := virtualnetworklinks.VirtualNetworkLink{
	// ...
}


if err := client.UpdateThenPoll(ctx, id, payload, virtualnetworklinks.DefaultUpdateOperationOptions()); err != nil {
	// handle the error
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForProvisioningState

func PossibleValuesForProvisioningState() []string

func PossibleValuesForVirtualNetworkLinkState

func PossibleValuesForVirtualNetworkLinkState() []string

func ValidatePrivateDnsZoneID

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

ValidatePrivateDnsZoneID checks that 'input' can be parsed as a Private Dns Zone ID

func ValidateVirtualNetworkLinkID

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

ValidateVirtualNetworkLinkID checks that 'input' can be parsed as a Virtual Network Link ID

Types

type CreateOrUpdateOperationOptions

type CreateOrUpdateOperationOptions struct {
	IfMatch     *string
	IfNoneMatch *string
}

func DefaultCreateOrUpdateOperationOptions

func DefaultCreateOrUpdateOperationOptions() CreateOrUpdateOperationOptions

func (CreateOrUpdateOperationOptions) ToHeaders

func (CreateOrUpdateOperationOptions) ToOData

func (CreateOrUpdateOperationOptions) ToQuery

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *VirtualNetworkLink
}

type DeleteOperationOptions

type DeleteOperationOptions struct {
	IfMatch *string
}

func DefaultDeleteOperationOptions

func DefaultDeleteOperationOptions() DeleteOperationOptions

func (DeleteOperationOptions) ToHeaders

func (o DeleteOperationOptions) ToHeaders() *client.Headers

func (DeleteOperationOptions) ToOData

func (o DeleteOperationOptions) ToOData() *odata.Query

func (DeleteOperationOptions) ToQuery

type DeleteOperationResponse

type DeleteOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
}

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *VirtualNetworkLink
}

type ListCompleteResult

type ListCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []VirtualNetworkLink
}

type ListOperationOptions

type ListOperationOptions struct {
	Top *int64
}

func DefaultListOperationOptions

func DefaultListOperationOptions() ListOperationOptions

func (ListOperationOptions) ToHeaders

func (o ListOperationOptions) ToHeaders() *client.Headers

func (ListOperationOptions) ToOData

func (o ListOperationOptions) ToOData() *odata.Query

func (ListOperationOptions) ToQuery

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]VirtualNetworkLink
}

type PrivateDnsZoneId

type PrivateDnsZoneId struct {
	SubscriptionId     string
	ResourceGroupName  string
	PrivateDnsZoneName string
}

PrivateDnsZoneId is a struct representing the Resource ID for a Private Dns Zone

func NewPrivateDnsZoneID

func NewPrivateDnsZoneID(subscriptionId string, resourceGroupName string, privateDnsZoneName string) PrivateDnsZoneId

NewPrivateDnsZoneID returns a new PrivateDnsZoneId struct

func ParsePrivateDnsZoneID

func ParsePrivateDnsZoneID(input string) (*PrivateDnsZoneId, error)

ParsePrivateDnsZoneID parses 'input' into a PrivateDnsZoneId

func ParsePrivateDnsZoneIDInsensitively

func ParsePrivateDnsZoneIDInsensitively(input string) (*PrivateDnsZoneId, error)

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

func (*PrivateDnsZoneId) FromParseResult

func (id *PrivateDnsZoneId) FromParseResult(input resourceids.ParseResult) error

func (PrivateDnsZoneId) ID

func (id PrivateDnsZoneId) ID() string

ID returns the formatted Private Dns Zone ID

func (PrivateDnsZoneId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Private Dns Zone ID

func (PrivateDnsZoneId) String

func (id PrivateDnsZoneId) String() string

String returns a human-readable description of this Private Dns Zone ID

type ProvisioningState

type ProvisioningState string
const (
	ProvisioningStateCanceled  ProvisioningState = "Canceled"
	ProvisioningStateCreating  ProvisioningState = "Creating"
	ProvisioningStateDeleting  ProvisioningState = "Deleting"
	ProvisioningStateFailed    ProvisioningState = "Failed"
	ProvisioningStateSucceeded ProvisioningState = "Succeeded"
	ProvisioningStateUpdating  ProvisioningState = "Updating"
)

func (*ProvisioningState) UnmarshalJSON

func (s *ProvisioningState) UnmarshalJSON(bytes []byte) error

type SubResource

type SubResource struct {
	Id *string `json:"id,omitempty"`
}

type UpdateOperationOptions

type UpdateOperationOptions struct {
	IfMatch *string
}

func DefaultUpdateOperationOptions

func DefaultUpdateOperationOptions() UpdateOperationOptions

func (UpdateOperationOptions) ToHeaders

func (o UpdateOperationOptions) ToHeaders() *client.Headers

func (UpdateOperationOptions) ToOData

func (o UpdateOperationOptions) ToOData() *odata.Query

func (UpdateOperationOptions) ToQuery

type UpdateOperationResponse

type UpdateOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *VirtualNetworkLink
}
type VirtualNetworkLink struct {
	Etag       *string                       `json:"etag,omitempty"`
	Id         *string                       `json:"id,omitempty"`
	Location   *string                       `json:"location,omitempty"`
	Name       *string                       `json:"name,omitempty"`
	Properties *VirtualNetworkLinkProperties `json:"properties,omitempty"`
	Tags       *map[string]string            `json:"tags,omitempty"`
	Type       *string                       `json:"type,omitempty"`
}

type VirtualNetworkLinkId

type VirtualNetworkLinkId struct {
	SubscriptionId         string
	ResourceGroupName      string
	PrivateDnsZoneName     string
	VirtualNetworkLinkName string
}

VirtualNetworkLinkId is a struct representing the Resource ID for a Virtual Network Link

func NewVirtualNetworkLinkID

func NewVirtualNetworkLinkID(subscriptionId string, resourceGroupName string, privateDnsZoneName string, virtualNetworkLinkName string) VirtualNetworkLinkId

NewVirtualNetworkLinkID returns a new VirtualNetworkLinkId struct

func ParseVirtualNetworkLinkID

func ParseVirtualNetworkLinkID(input string) (*VirtualNetworkLinkId, error)

ParseVirtualNetworkLinkID parses 'input' into a VirtualNetworkLinkId

func ParseVirtualNetworkLinkIDInsensitively

func ParseVirtualNetworkLinkIDInsensitively(input string) (*VirtualNetworkLinkId, error)

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

func (*VirtualNetworkLinkId) FromParseResult

func (id *VirtualNetworkLinkId) FromParseResult(input resourceids.ParseResult) error

func (VirtualNetworkLinkId) ID

func (id VirtualNetworkLinkId) ID() string

ID returns the formatted Virtual Network Link ID

func (VirtualNetworkLinkId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Virtual Network Link ID

func (VirtualNetworkLinkId) String

func (id VirtualNetworkLinkId) String() string

String returns a human-readable description of this Virtual Network Link ID

type VirtualNetworkLinkOperationPredicate

type VirtualNetworkLinkOperationPredicate struct {
	Etag     *string
	Id       *string
	Location *string
	Name     *string
	Type     *string
}

func (VirtualNetworkLinkOperationPredicate) Matches

type VirtualNetworkLinkProperties

type VirtualNetworkLinkProperties struct {
	ProvisioningState       *ProvisioningState       `json:"provisioningState,omitempty"`
	RegistrationEnabled     *bool                    `json:"registrationEnabled,omitempty"`
	VirtualNetwork          *SubResource             `json:"virtualNetwork,omitempty"`
	VirtualNetworkLinkState *VirtualNetworkLinkState `json:"virtualNetworkLinkState,omitempty"`
}

type VirtualNetworkLinkState

type VirtualNetworkLinkState string
const (
	VirtualNetworkLinkStateCompleted  VirtualNetworkLinkState = "Completed"
	VirtualNetworkLinkStateInProgress VirtualNetworkLinkState = "InProgress"
)

func (*VirtualNetworkLinkState) UnmarshalJSON

func (s *VirtualNetworkLinkState) UnmarshalJSON(bytes []byte) error

type VirtualNetworkLinksClient

type VirtualNetworkLinksClient struct {
	Client *resourcemanager.Client
}

func NewVirtualNetworkLinksClientWithBaseURI

func NewVirtualNetworkLinksClientWithBaseURI(sdkApi sdkEnv.Api) (*VirtualNetworkLinksClient, error)

func (VirtualNetworkLinksClient) CreateOrUpdate

CreateOrUpdate ...

func (VirtualNetworkLinksClient) CreateOrUpdateThenPoll

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (VirtualNetworkLinksClient) Delete

Delete ...

func (VirtualNetworkLinksClient) DeleteThenPoll

DeleteThenPoll performs Delete then polls until it's completed

func (VirtualNetworkLinksClient) Get

Get ...

func (VirtualNetworkLinksClient) List

List ...

func (VirtualNetworkLinksClient) ListComplete

ListComplete retrieves all the results into a single object

func (VirtualNetworkLinksClient) ListCompleteMatchingPredicate

func (c VirtualNetworkLinksClient) ListCompleteMatchingPredicate(ctx context.Context, id PrivateDnsZoneId, options ListOperationOptions, predicate VirtualNetworkLinkOperationPredicate) (result ListCompleteResult, err error)

ListCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (VirtualNetworkLinksClient) Update

Update ...

func (VirtualNetworkLinksClient) UpdateThenPoll

UpdateThenPoll performs Update then polls until it's completed

Jump to

Keyboard shortcuts

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