scalingplanpooledschedule

package
v0.20241023.1122425 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2024 License: MPL-2.0 Imports: 12 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/desktopvirtualization/2022-09-09/scalingplanpooledschedule Documentation

The scalingplanpooledschedule SDK allows for interaction with Azure Resource Manager desktopvirtualization (API Version 2022-09-09).

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/2022-09-09/scalingplanpooledschedule"

Client Initialization

client := scalingplanpooledschedule.NewScalingPlanPooledScheduleClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ScalingPlanPooledScheduleClient.Create

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

payload := scalingplanpooledschedule.ScalingPlanPooledSchedule{
	// ...
}


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: ScalingPlanPooledScheduleClient.Delete

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

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: ScalingPlanPooledScheduleClient.Get

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

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

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

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

Example Usage: ScalingPlanPooledScheduleClient.Update

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

payload := scalingplanpooledschedule.ScalingPlanPooledSchedulePatch{
	// ...
}


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 PossibleValuesForSessionHostLoadBalancingAlgorithm

func PossibleValuesForSessionHostLoadBalancingAlgorithm() []string

func PossibleValuesForStopHostsWhen

func PossibleValuesForStopHostsWhen() []string

func ValidatePooledScheduleID

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

ValidatePooledScheduleID checks that 'input' can be parsed as a Pooled 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        *ScalingPlanPooledSchedule
}

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        *ScalingPlanPooledSchedule
}

type ListCompleteResult

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

type ListCustomPager added in v0.20240628.1153531

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        *[]ScalingPlanPooledSchedule
}

type PooledScheduleId

type PooledScheduleId struct {
	SubscriptionId     string
	ResourceGroupName  string
	ScalingPlanName    string
	PooledScheduleName string
}

PooledScheduleId is a struct representing the Resource ID for a Pooled Schedule

func NewPooledScheduleID

func NewPooledScheduleID(subscriptionId string, resourceGroupName string, scalingPlanName string, pooledScheduleName string) PooledScheduleId

NewPooledScheduleID returns a new PooledScheduleId struct

func ParsePooledScheduleID

func ParsePooledScheduleID(input string) (*PooledScheduleId, error)

ParsePooledScheduleID parses 'input' into a PooledScheduleId

func ParsePooledScheduleIDInsensitively

func ParsePooledScheduleIDInsensitively(input string) (*PooledScheduleId, error)

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

func (*PooledScheduleId) FromParseResult

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

func (PooledScheduleId) ID

func (id PooledScheduleId) ID() string

ID returns the formatted Pooled Schedule ID

func (PooledScheduleId) Segments

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

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

func (PooledScheduleId) String

func (id PooledScheduleId) String() string

String returns a human-readable description of this Pooled 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 ScalingPlanPooledSchedule

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

type ScalingPlanPooledScheduleClient

type ScalingPlanPooledScheduleClient struct {
	Client *resourcemanager.Client
}

func NewScalingPlanPooledScheduleClientWithBaseURI

func NewScalingPlanPooledScheduleClientWithBaseURI(sdkApi sdkEnv.Api) (*ScalingPlanPooledScheduleClient, error)

func (ScalingPlanPooledScheduleClient) Create

Create ...

func (ScalingPlanPooledScheduleClient) Delete

Delete ...

func (ScalingPlanPooledScheduleClient) Get

Get ...

func (ScalingPlanPooledScheduleClient) List

List ...

func (ScalingPlanPooledScheduleClient) ListComplete

ListComplete retrieves all the results into a single object

func (ScalingPlanPooledScheduleClient) ListCompleteMatchingPredicate

ListCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ScalingPlanPooledScheduleClient) Update

Update ...

type ScalingPlanPooledScheduleOperationPredicate

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

func (ScalingPlanPooledScheduleOperationPredicate) Matches

type ScalingPlanPooledSchedulePatch

type ScalingPlanPooledSchedulePatch struct {
	Id         *string                              `json:"id,omitempty"`
	Name       *string                              `json:"name,omitempty"`
	Properties *ScalingPlanPooledScheduleProperties `json:"properties,omitempty"`
	Type       *string                              `json:"type,omitempty"`
}

type ScalingPlanPooledScheduleProperties

type ScalingPlanPooledScheduleProperties struct {
	DaysOfWeek                     *[]DayOfWeek                       `json:"daysOfWeek,omitempty"`
	OffPeakLoadBalancingAlgorithm  *SessionHostLoadBalancingAlgorithm `json:"offPeakLoadBalancingAlgorithm,omitempty"`
	OffPeakStartTime               *Time                              `json:"offPeakStartTime,omitempty"`
	PeakLoadBalancingAlgorithm     *SessionHostLoadBalancingAlgorithm `json:"peakLoadBalancingAlgorithm,omitempty"`
	PeakStartTime                  *Time                              `json:"peakStartTime,omitempty"`
	RampDownCapacityThresholdPct   *int64                             `json:"rampDownCapacityThresholdPct,omitempty"`
	RampDownForceLogoffUsers       *bool                              `json:"rampDownForceLogoffUsers,omitempty"`
	RampDownLoadBalancingAlgorithm *SessionHostLoadBalancingAlgorithm `json:"rampDownLoadBalancingAlgorithm,omitempty"`
	RampDownMinimumHostsPct        *int64                             `json:"rampDownMinimumHostsPct,omitempty"`
	RampDownNotificationMessage    *string                            `json:"rampDownNotificationMessage,omitempty"`
	RampDownStartTime              *Time                              `json:"rampDownStartTime,omitempty"`
	RampDownStopHostsWhen          *StopHostsWhen                     `json:"rampDownStopHostsWhen,omitempty"`
	RampDownWaitTimeMinutes        *int64                             `json:"rampDownWaitTimeMinutes,omitempty"`
	RampUpCapacityThresholdPct     *int64                             `json:"rampUpCapacityThresholdPct,omitempty"`
	RampUpLoadBalancingAlgorithm   *SessionHostLoadBalancingAlgorithm `json:"rampUpLoadBalancingAlgorithm,omitempty"`
	RampUpMinimumHostsPct          *int64                             `json:"rampUpMinimumHostsPct,omitempty"`
	RampUpStartTime                *Time                              `json:"rampUpStartTime,omitempty"`
}

type SessionHostLoadBalancingAlgorithm

type SessionHostLoadBalancingAlgorithm string
const (
	SessionHostLoadBalancingAlgorithmBreadthFirst SessionHostLoadBalancingAlgorithm = "BreadthFirst"
	SessionHostLoadBalancingAlgorithmDepthFirst   SessionHostLoadBalancingAlgorithm = "DepthFirst"
)

func (*SessionHostLoadBalancingAlgorithm) UnmarshalJSON

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

type StopHostsWhen

type StopHostsWhen string
const (
	StopHostsWhenZeroActiveSessions StopHostsWhen = "ZeroActiveSessions"
	StopHostsWhenZeroSessions       StopHostsWhen = "ZeroSessions"
)

func (*StopHostsWhen) UnmarshalJSON

func (s *StopHostsWhen) 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        *ScalingPlanPooledSchedule
}

Jump to

Keyboard shortcuts

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