scalingplanpersonalschedule

package
v0.20250127.1142050 Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2025 License: MPL-2.0 Imports: 12 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/desktopvirtualization/2024-04-03/scalingplanpersonalschedule Documentation

The scalingplanpersonalschedule SDK allows for interaction with Azure Resource Manager desktopvirtualization (API Version 2024-04-03).

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/2024-04-03/scalingplanpersonalschedule"

Client Initialization

client := scalingplanpersonalschedule.NewScalingPlanPersonalScheduleClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ScalingPlanPersonalScheduleClient.Create

ctx := context.TODO()
id := scalingplanpersonalschedule.NewPersonalScheduleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "scalingPlanName", "personalScheduleName")

payload := scalingplanpersonalschedule.ScalingPlanPersonalSchedule{
	// ...
}


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

Example Usage: ScalingPlanPersonalScheduleClient.Delete

ctx := context.TODO()
id := scalingplanpersonalschedule.NewPersonalScheduleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "scalingPlanName", "personalScheduleName")

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

Example Usage: ScalingPlanPersonalScheduleClient.Get

ctx := context.TODO()
id := scalingplanpersonalschedule.NewPersonalScheduleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "scalingPlanName", "personalScheduleName")

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: ScalingPlanPersonalScheduleClient.List

ctx := context.TODO()
id := scalingplanpersonalschedule.NewScalingPlanID("12345678-1234-9876-4563-123456789012", "example-resource-group", "scalingPlanName")

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

Example Usage: ScalingPlanPersonalScheduleClient.Update

ctx := context.TODO()
id := scalingplanpersonalschedule.NewPersonalScheduleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "scalingPlanName", "personalScheduleName")

payload := scalingplanpersonalschedule.ScalingPlanPersonalSchedulePatch{
	// ...
}


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

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForDayOfWeek

func PossibleValuesForDayOfWeek() []string

func PossibleValuesForSessionHandlingOperation

func PossibleValuesForSessionHandlingOperation() []string

func PossibleValuesForSetStartVMOnConnect

func PossibleValuesForSetStartVMOnConnect() []string

func PossibleValuesForStartupBehavior

func PossibleValuesForStartupBehavior() []string

func ValidatePersonalScheduleID

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

ValidatePersonalScheduleID checks that 'input' can be parsed as a Personal Schedule ID

func ValidateScalingPlanID

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

ValidateScalingPlanID checks that 'input' can be parsed as a Scaling Plan ID

Types

type CreateOperationResponse

type CreateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ScalingPlanPersonalSchedule
}

type DayOfWeek

type DayOfWeek string
const (
	DayOfWeekFriday    DayOfWeek = "Friday"
	DayOfWeekMonday    DayOfWeek = "Monday"
	DayOfWeekSaturday  DayOfWeek = "Saturday"
	DayOfWeekSunday    DayOfWeek = "Sunday"
	DayOfWeekThursday  DayOfWeek = "Thursday"
	DayOfWeekTuesday   DayOfWeek = "Tuesday"
	DayOfWeekWednesday DayOfWeek = "Wednesday"
)

func (*DayOfWeek) UnmarshalJSON

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

type DeleteOperationResponse

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

type GetOperationResponse

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

type ListCompleteResult

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

type ListCustomPager

type ListCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListCustomPager) NextPageLink() *odata.Link

type ListOperationOptions

type ListOperationOptions struct {
	InitialSkip  *int64
	IsDescending *bool
	PageSize     *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        *[]ScalingPlanPersonalSchedule
}

type PersonalScheduleId

type PersonalScheduleId struct {
	SubscriptionId       string
	ResourceGroupName    string
	ScalingPlanName      string
	PersonalScheduleName string
}

PersonalScheduleId is a struct representing the Resource ID for a Personal Schedule

func NewPersonalScheduleID

func NewPersonalScheduleID(subscriptionId string, resourceGroupName string, scalingPlanName string, personalScheduleName string) PersonalScheduleId

NewPersonalScheduleID returns a new PersonalScheduleId struct

func ParsePersonalScheduleID

func ParsePersonalScheduleID(input string) (*PersonalScheduleId, error)

ParsePersonalScheduleID parses 'input' into a PersonalScheduleId

func ParsePersonalScheduleIDInsensitively

func ParsePersonalScheduleIDInsensitively(input string) (*PersonalScheduleId, error)

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

func (*PersonalScheduleId) FromParseResult

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

func (PersonalScheduleId) ID

func (id PersonalScheduleId) ID() string

ID returns the formatted Personal Schedule ID

func (PersonalScheduleId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Personal Schedule ID

func (PersonalScheduleId) String

func (id PersonalScheduleId) String() string

String returns a human-readable description of this Personal Schedule ID

type ScalingPlanId

type ScalingPlanId struct {
	SubscriptionId    string
	ResourceGroupName string
	ScalingPlanName   string
}

ScalingPlanId is a struct representing the Resource ID for a Scaling Plan

func NewScalingPlanID

func NewScalingPlanID(subscriptionId string, resourceGroupName string, scalingPlanName string) ScalingPlanId

NewScalingPlanID returns a new ScalingPlanId struct

func ParseScalingPlanID

func ParseScalingPlanID(input string) (*ScalingPlanId, error)

ParseScalingPlanID parses 'input' into a ScalingPlanId

func ParseScalingPlanIDInsensitively

func ParseScalingPlanIDInsensitively(input string) (*ScalingPlanId, error)

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

func (*ScalingPlanId) FromParseResult

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

func (ScalingPlanId) ID

func (id ScalingPlanId) ID() string

ID returns the formatted Scaling Plan ID

func (ScalingPlanId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Scaling Plan ID

func (ScalingPlanId) String

func (id ScalingPlanId) String() string

String returns a human-readable description of this Scaling Plan ID

type ScalingPlanPersonalSchedule

type ScalingPlanPersonalSchedule struct {
	Id         *string                               `json:"id,omitempty"`
	Name       *string                               `json:"name,omitempty"`
	Properties ScalingPlanPersonalScheduleProperties `json:"properties"`
	SystemData *systemdata.SystemData                `json:"systemData,omitempty"`
	Type       *string                               `json:"type,omitempty"`
}

type ScalingPlanPersonalScheduleClient

type ScalingPlanPersonalScheduleClient struct {
	Client *resourcemanager.Client
}

func NewScalingPlanPersonalScheduleClientWithBaseURI

func NewScalingPlanPersonalScheduleClientWithBaseURI(sdkApi sdkEnv.Api) (*ScalingPlanPersonalScheduleClient, error)

func (ScalingPlanPersonalScheduleClient) Create

Create ...

func (ScalingPlanPersonalScheduleClient) Delete

Delete ...

func (ScalingPlanPersonalScheduleClient) Get

Get ...

func (ScalingPlanPersonalScheduleClient) List

List ...

func (ScalingPlanPersonalScheduleClient) ListComplete

ListComplete retrieves all the results into a single object

func (ScalingPlanPersonalScheduleClient) ListCompleteMatchingPredicate

ListCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ScalingPlanPersonalScheduleClient) Update

Update ...

type ScalingPlanPersonalScheduleOperationPredicate

type ScalingPlanPersonalScheduleOperationPredicate struct {
	Id   *string
	Name *string
	Type *string
}

func (ScalingPlanPersonalScheduleOperationPredicate) Matches

type ScalingPlanPersonalSchedulePatch

type ScalingPlanPersonalSchedulePatch struct {
	Properties *ScalingPlanPersonalScheduleProperties `json:"properties,omitempty"`
}

type ScalingPlanPersonalScheduleProperties

type ScalingPlanPersonalScheduleProperties struct {
	DaysOfWeek                        *[]DayOfWeek              `json:"daysOfWeek,omitempty"`
	OffPeakActionOnDisconnect         *SessionHandlingOperation `json:"offPeakActionOnDisconnect,omitempty"`
	OffPeakActionOnLogoff             *SessionHandlingOperation `json:"offPeakActionOnLogoff,omitempty"`
	OffPeakMinutesToWaitOnDisconnect  *int64                    `json:"offPeakMinutesToWaitOnDisconnect,omitempty"`
	OffPeakMinutesToWaitOnLogoff      *int64                    `json:"offPeakMinutesToWaitOnLogoff,omitempty"`
	OffPeakStartTime                  *Time                     `json:"offPeakStartTime,omitempty"`
	OffPeakStartVMOnConnect           *SetStartVMOnConnect      `json:"offPeakStartVMOnConnect,omitempty"`
	PeakActionOnDisconnect            *SessionHandlingOperation `json:"peakActionOnDisconnect,omitempty"`
	PeakActionOnLogoff                *SessionHandlingOperation `json:"peakActionOnLogoff,omitempty"`
	PeakMinutesToWaitOnDisconnect     *int64                    `json:"peakMinutesToWaitOnDisconnect,omitempty"`
	PeakMinutesToWaitOnLogoff         *int64                    `json:"peakMinutesToWaitOnLogoff,omitempty"`
	PeakStartTime                     *Time                     `json:"peakStartTime,omitempty"`
	PeakStartVMOnConnect              *SetStartVMOnConnect      `json:"peakStartVMOnConnect,omitempty"`
	RampDownActionOnDisconnect        *SessionHandlingOperation `json:"rampDownActionOnDisconnect,omitempty"`
	RampDownActionOnLogoff            *SessionHandlingOperation `json:"rampDownActionOnLogoff,omitempty"`
	RampDownMinutesToWaitOnDisconnect *int64                    `json:"rampDownMinutesToWaitOnDisconnect,omitempty"`
	RampDownMinutesToWaitOnLogoff     *int64                    `json:"rampDownMinutesToWaitOnLogoff,omitempty"`
	RampDownStartTime                 *Time                     `json:"rampDownStartTime,omitempty"`
	RampDownStartVMOnConnect          *SetStartVMOnConnect      `json:"rampDownStartVMOnConnect,omitempty"`
	RampUpActionOnDisconnect          *SessionHandlingOperation `json:"rampUpActionOnDisconnect,omitempty"`
	RampUpActionOnLogoff              *SessionHandlingOperation `json:"rampUpActionOnLogoff,omitempty"`
	RampUpAutoStartHosts              *StartupBehavior          `json:"rampUpAutoStartHosts,omitempty"`
	RampUpMinutesToWaitOnDisconnect   *int64                    `json:"rampUpMinutesToWaitOnDisconnect,omitempty"`
	RampUpMinutesToWaitOnLogoff       *int64                    `json:"rampUpMinutesToWaitOnLogoff,omitempty"`
	RampUpStartTime                   *Time                     `json:"rampUpStartTime,omitempty"`
	RampUpStartVMOnConnect            *SetStartVMOnConnect      `json:"rampUpStartVMOnConnect,omitempty"`
}

type SessionHandlingOperation

type SessionHandlingOperation string
const (
	SessionHandlingOperationDeallocate SessionHandlingOperation = "Deallocate"
	SessionHandlingOperationHibernate  SessionHandlingOperation = "Hibernate"
	SessionHandlingOperationNone       SessionHandlingOperation = "None"
)

func (*SessionHandlingOperation) UnmarshalJSON

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

type SetStartVMOnConnect

type SetStartVMOnConnect string
const (
	SetStartVMOnConnectDisable SetStartVMOnConnect = "Disable"
	SetStartVMOnConnectEnable  SetStartVMOnConnect = "Enable"
)

func (*SetStartVMOnConnect) UnmarshalJSON

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

type StartupBehavior

type StartupBehavior string
const (
	StartupBehaviorAll              StartupBehavior = "All"
	StartupBehaviorNone             StartupBehavior = "None"
	StartupBehaviorWithAssignedUser StartupBehavior = "WithAssignedUser"
)

func (*StartupBehavior) UnmarshalJSON

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

type Time

type Time struct {
	Hour   int64 `json:"hour"`
	Minute int64 `json:"minute"`
}

type UpdateOperationResponse

type UpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ScalingPlanPersonalSchedule
}

Jump to

Keyboard shortcuts

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