Categorygithub.com/hashicorp/go-azure-sdk/resource-managerpostgresql2023-06-01-previewvirtualendpoints
package
0.20240715.1103416
Repository: https://github.com/hashicorp/go-azure-sdk.git
Documentation: pkg.go.dev
# README
github.com/hashicorp/go-azure-sdk/resource-manager/postgresql/2023-06-01-preview/virtualendpoints
Documentation
The virtualendpoints
SDK allows for interaction with the Azure Resource Manager Service postgresql
(API Version 2023-06-01-preview
).
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/postgresql/2023-06-01-preview/virtualendpoints"
Client Initialization
client := virtualendpoints.NewVirtualEndpointsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer
Example Usage: VirtualEndpointsClient.Create
ctx := context.TODO()
id := virtualendpoints.NewVirtualEndpointID("12345678-1234-9876-4563-123456789012", "example-resource-group", "flexibleServerValue", "virtualEndpointValue")
payload := virtualendpoints.VirtualEndpointResource{
// ...
}
if err := client.CreateThenPoll(ctx, id, payload); err != nil {
// handle the error
}
Example Usage: VirtualEndpointsClient.Delete
ctx := context.TODO()
id := virtualendpoints.NewVirtualEndpointID("12345678-1234-9876-4563-123456789012", "example-resource-group", "flexibleServerValue", "virtualEndpointValue")
if err := client.DeleteThenPoll(ctx, id); err != nil {
// handle the error
}
Example Usage: VirtualEndpointsClient.Get
ctx := context.TODO()
id := virtualendpoints.NewVirtualEndpointID("12345678-1234-9876-4563-123456789012", "example-resource-group", "flexibleServerValue", "virtualEndpointValue")
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: VirtualEndpointsClient.ListByServer
ctx := context.TODO()
id := virtualendpoints.NewFlexibleServerID("12345678-1234-9876-4563-123456789012", "example-resource-group", "flexibleServerValue")
// alternatively `client.ListByServer(ctx, id)` can be used to do batched pagination
items, err := client.ListByServerComplete(ctx, id)
if err != nil {
// handle the error
}
for _, item := range items {
// do something
}
Example Usage: VirtualEndpointsClient.Update
ctx := context.TODO()
id := virtualendpoints.NewVirtualEndpointID("12345678-1234-9876-4563-123456789012", "example-resource-group", "flexibleServerValue", "virtualEndpointValue")
payload := virtualendpoints.VirtualEndpointResourceForPatch{
// ...
}
if err := client.UpdateThenPoll(ctx, id, payload); err != nil {
// handle the error
}
# Functions
NewFlexibleServerID returns a new FlexibleServerId struct.
NewVirtualEndpointID returns a new VirtualEndpointId struct.
No description provided by the author
ParseFlexibleServerID parses 'input' into a FlexibleServerId.
ParseFlexibleServerIDInsensitively parses 'input' case-insensitively into a FlexibleServerId note: this method should only be used for API response data and not user input.
ParseVirtualEndpointID parses 'input' into a VirtualEndpointId.
ParseVirtualEndpointIDInsensitively parses 'input' case-insensitively into a VirtualEndpointId note: this method should only be used for API response data and not user input.
No description provided by the author
ValidateFlexibleServerID checks that 'input' can be parsed as a Flexible Server ID.
ValidateVirtualEndpointID checks that 'input' can be parsed as a Virtual Endpoint ID.
# Constants
No description provided by the author
# Structs
No description provided by the author
No description provided by the author
FlexibleServerId is a struct representing the Resource ID for a Flexible Server.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
VirtualEndpointId is a struct representing the Resource ID for a Virtual Endpoint.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
# Type aliases
No description provided by the author