README ¶
github.com/hashicorp/go-azure-sdk/resource-manager/desktopvirtualization/2021-09-03-preview/desktop
Documentation
The desktop
SDK allows for interaction with the Azure Resource Manager Service desktopvirtualization
(API Version 2021-09-03-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/desktopvirtualization/2021-09-03-preview/desktop"
Client Initialization
client := desktop.NewDesktopClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer
Example Usage: DesktopClient.Get
ctx := context.TODO()
id := desktop.NewDesktopID("12345678-1234-9876-4563-123456789012", "example-resource-group", "applicationGroupValue", "desktopValue")
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: DesktopClient.List
ctx := context.TODO()
id := desktop.NewApplicationGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group", "applicationGroupValue")
// alternatively `client.List(ctx, id)` can be used to do batched pagination
items, err := client.ListComplete(ctx, id)
if err != nil {
// handle the error
}
for _, item := range items {
// do something
}
Example Usage: DesktopClient.Update
ctx := context.TODO()
id := desktop.NewDesktopID("12345678-1234-9876-4563-123456789012", "example-resource-group", "applicationGroupValue", "desktopValue")
payload := desktop.DesktopPatch{
// ...
}
read, err := client.Update(ctx, id, payload)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Documentation ¶
Index ¶
- func ValidateApplicationGroupID(input interface{}, key string) (warnings []string, errors []error)
- func ValidateDesktopID(input interface{}, key string) (warnings []string, errors []error)
- type ApplicationGroupId
- type Desktop
- type DesktopClient
- func (c DesktopClient) Get(ctx context.Context, id DesktopId) (result GetOperationResponse, err error)
- func (c DesktopClient) List(ctx context.Context, id ApplicationGroupId) (result ListOperationResponse, err error)
- func (c DesktopClient) ListComplete(ctx context.Context, id ApplicationGroupId) (ListCompleteResult, error)
- func (c DesktopClient) ListCompleteMatchingPredicate(ctx context.Context, id ApplicationGroupId, ...) (result ListCompleteResult, err error)
- func (c DesktopClient) Update(ctx context.Context, id DesktopId, input DesktopPatch) (result UpdateOperationResponse, err error)
- type DesktopId
- type DesktopOperationPredicate
- type DesktopPatch
- type DesktopPatchProperties
- type DesktopProperties
- type GetOperationResponse
- type ListCompleteResult
- type ListOperationResponse
- type UpdateOperationResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ValidateApplicationGroupID ¶
ValidateApplicationGroupID checks that 'input' can be parsed as a Application Group ID
func ValidateDesktopID ¶
ValidateDesktopID checks that 'input' can be parsed as a Desktop ID
Types ¶
type ApplicationGroupId ¶
type ApplicationGroupId struct { SubscriptionId string ResourceGroupName string ApplicationGroupName string }
ApplicationGroupId is a struct representing the Resource ID for a Application Group
func NewApplicationGroupID ¶
func NewApplicationGroupID(subscriptionId string, resourceGroupName string, applicationGroupName string) ApplicationGroupId
NewApplicationGroupID returns a new ApplicationGroupId struct
func ParseApplicationGroupID ¶
func ParseApplicationGroupID(input string) (*ApplicationGroupId, error)
ParseApplicationGroupID parses 'input' into a ApplicationGroupId
func ParseApplicationGroupIDInsensitively ¶
func ParseApplicationGroupIDInsensitively(input string) (*ApplicationGroupId, error)
ParseApplicationGroupIDInsensitively parses 'input' case-insensitively into a ApplicationGroupId note: this method should only be used for API response data and not user input
func (*ApplicationGroupId) FromParseResult ¶
func (id *ApplicationGroupId) FromParseResult(input resourceids.ParseResult) error
func (ApplicationGroupId) ID ¶
func (id ApplicationGroupId) ID() string
ID returns the formatted Application Group ID
func (ApplicationGroupId) Segments ¶
func (id ApplicationGroupId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this Application Group ID
func (ApplicationGroupId) String ¶
func (id ApplicationGroupId) String() string
String returns a human-readable description of this Application Group ID
type Desktop ¶
type Desktop struct { Id *string `json:"id,omitempty"` Name *string `json:"name,omitempty"` Properties *DesktopProperties `json:"properties,omitempty"` SystemData *systemdata.SystemData `json:"systemData,omitempty"` Type *string `json:"type,omitempty"` }
type DesktopClient ¶
type DesktopClient struct {
Client *resourcemanager.Client
}
func NewDesktopClientWithBaseURI ¶
func NewDesktopClientWithBaseURI(sdkApi sdkEnv.Api) (*DesktopClient, error)
func (DesktopClient) Get ¶
func (c DesktopClient) Get(ctx context.Context, id DesktopId) (result GetOperationResponse, err error)
Get ...
func (DesktopClient) List ¶
func (c DesktopClient) List(ctx context.Context, id ApplicationGroupId) (result ListOperationResponse, err error)
List ...
func (DesktopClient) ListComplete ¶
func (c DesktopClient) ListComplete(ctx context.Context, id ApplicationGroupId) (ListCompleteResult, error)
ListComplete retrieves all the results into a single object
func (DesktopClient) ListCompleteMatchingPredicate ¶
func (c DesktopClient) ListCompleteMatchingPredicate(ctx context.Context, id ApplicationGroupId, predicate DesktopOperationPredicate) (result ListCompleteResult, err error)
ListCompleteMatchingPredicate retrieves all the results and then applies the predicate
func (DesktopClient) Update ¶
func (c DesktopClient) Update(ctx context.Context, id DesktopId, input DesktopPatch) (result UpdateOperationResponse, err error)
Update ...
type DesktopId ¶
type DesktopId struct { SubscriptionId string ResourceGroupName string ApplicationGroupName string DesktopName string }
DesktopId is a struct representing the Resource ID for a Desktop
func NewDesktopID ¶
func NewDesktopID(subscriptionId string, resourceGroupName string, applicationGroupName string, desktopName string) DesktopId
NewDesktopID returns a new DesktopId struct
func ParseDesktopID ¶
ParseDesktopID parses 'input' into a DesktopId
func ParseDesktopIDInsensitively ¶
ParseDesktopIDInsensitively parses 'input' case-insensitively into a DesktopId note: this method should only be used for API response data and not user input
func (*DesktopId) FromParseResult ¶
func (id *DesktopId) FromParseResult(input resourceids.ParseResult) error
func (DesktopId) Segments ¶
func (id DesktopId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this Desktop ID
type DesktopOperationPredicate ¶
func (DesktopOperationPredicate) Matches ¶
func (p DesktopOperationPredicate) Matches(input Desktop) bool
type DesktopPatch ¶
type DesktopPatch struct { Properties *DesktopPatchProperties `json:"properties,omitempty"` Tags *map[string]string `json:"tags,omitempty"` }