fabriccapacities

package
v0.20240920.1081703 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2024 License: MPL-2.0 Imports: 14 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/fabric/2023-11-01/fabriccapacities Documentation

The fabriccapacities SDK allows for interaction with the Azure Resource Manager Service fabric (API Version 2023-11-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-helpers/resourcemanager/commonids"
import "github.com/hashicorp/go-azure-sdk/resource-manager/fabric/2023-11-01/fabriccapacities"

Client Initialization

client := fabriccapacities.NewFabricCapacitiesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: FabricCapacitiesClient.CheckNameAvailability

ctx := context.TODO()
id := fabriccapacities.NewLocationID("12345678-1234-9876-4563-123456789012", "locationValue")

payload := fabriccapacities.CheckNameAvailabilityRequest{
	// ...
}


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

Example Usage: FabricCapacitiesClient.CreateOrUpdate

ctx := context.TODO()
id := fabriccapacities.NewCapacityID("12345678-1234-9876-4563-123456789012", "example-resource-group", "capacityValue")

payload := fabriccapacities.FabricCapacity{
	// ...
}


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

Example Usage: FabricCapacitiesClient.Delete

ctx := context.TODO()
id := fabriccapacities.NewCapacityID("12345678-1234-9876-4563-123456789012", "example-resource-group", "capacityValue")

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

Example Usage: FabricCapacitiesClient.Get

ctx := context.TODO()
id := fabriccapacities.NewCapacityID("12345678-1234-9876-4563-123456789012", "example-resource-group", "capacityValue")

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: FabricCapacitiesClient.ListByResourceGroup

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

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

Example Usage: FabricCapacitiesClient.ListBySubscription

ctx := context.TODO()
id := commonids.NewSubscriptionID("12345678-1234-9876-4563-123456789012")

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

Example Usage: FabricCapacitiesClient.ListSkus

ctx := context.TODO()
id := commonids.NewSubscriptionID("12345678-1234-9876-4563-123456789012")

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

Example Usage: FabricCapacitiesClient.ListSkusForCapacity

ctx := context.TODO()
id := fabriccapacities.NewCapacityID("12345678-1234-9876-4563-123456789012", "example-resource-group", "capacityValue")

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

Example Usage: FabricCapacitiesClient.Resume

ctx := context.TODO()
id := fabriccapacities.NewCapacityID("12345678-1234-9876-4563-123456789012", "example-resource-group", "capacityValue")

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

Example Usage: FabricCapacitiesClient.Suspend

ctx := context.TODO()
id := fabriccapacities.NewCapacityID("12345678-1234-9876-4563-123456789012", "example-resource-group", "capacityValue")

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

Example Usage: FabricCapacitiesClient.Update

ctx := context.TODO()
id := fabriccapacities.NewCapacityID("12345678-1234-9876-4563-123456789012", "example-resource-group", "capacityValue")

payload := fabriccapacities.FabricCapacityUpdate{
	// ...
}


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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForCheckNameAvailabilityReason

func PossibleValuesForCheckNameAvailabilityReason() []string

func PossibleValuesForProvisioningState

func PossibleValuesForProvisioningState() []string

func PossibleValuesForResourceState

func PossibleValuesForResourceState() []string

func PossibleValuesForRpSkuTier

func PossibleValuesForRpSkuTier() []string

func ValidateCapacityID

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

ValidateCapacityID checks that 'input' can be parsed as a Capacity ID

func ValidateLocationID

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

ValidateLocationID checks that 'input' can be parsed as a Location ID

Types

type CapacityAdministration

type CapacityAdministration struct {
	Members []string `json:"members"`
}

type CapacityId

type CapacityId struct {
	SubscriptionId    string
	ResourceGroupName string
	CapacityName      string
}

CapacityId is a struct representing the Resource ID for a Capacity

func NewCapacityID

func NewCapacityID(subscriptionId string, resourceGroupName string, capacityName string) CapacityId

NewCapacityID returns a new CapacityId struct

func ParseCapacityID

func ParseCapacityID(input string) (*CapacityId, error)

ParseCapacityID parses 'input' into a CapacityId

func ParseCapacityIDInsensitively

func ParseCapacityIDInsensitively(input string) (*CapacityId, error)

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

func (*CapacityId) FromParseResult

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

func (CapacityId) ID

func (id CapacityId) ID() string

ID returns the formatted Capacity ID

func (CapacityId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Capacity ID

func (CapacityId) String

func (id CapacityId) String() string

String returns a human-readable description of this Capacity ID

type CheckNameAvailabilityOperationResponse

type CheckNameAvailabilityOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *CheckNameAvailabilityResponse
}

type CheckNameAvailabilityReason

type CheckNameAvailabilityReason string
const (
	CheckNameAvailabilityReasonAlreadyExists CheckNameAvailabilityReason = "AlreadyExists"
	CheckNameAvailabilityReasonInvalid       CheckNameAvailabilityReason = "Invalid"
)

func (*CheckNameAvailabilityReason) UnmarshalJSON

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

type CheckNameAvailabilityRequest

type CheckNameAvailabilityRequest struct {
	Name *string `json:"name,omitempty"`
	Type *string `json:"type,omitempty"`
}

type CheckNameAvailabilityResponse

type CheckNameAvailabilityResponse struct {
	Message       *string                      `json:"message,omitempty"`
	NameAvailable *bool                        `json:"nameAvailable,omitempty"`
	Reason        *CheckNameAvailabilityReason `json:"reason,omitempty"`
}

type CreateOrUpdateOperationResponse

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

type DeleteOperationResponse

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

type FabricCapacitiesClient

type FabricCapacitiesClient struct {
	Client *resourcemanager.Client
}

func NewFabricCapacitiesClientWithBaseURI

func NewFabricCapacitiesClientWithBaseURI(sdkApi sdkEnv.Api) (*FabricCapacitiesClient, error)

func (FabricCapacitiesClient) CheckNameAvailability

CheckNameAvailability ...

func (FabricCapacitiesClient) CreateOrUpdate

CreateOrUpdate ...

func (FabricCapacitiesClient) CreateOrUpdateThenPoll

func (c FabricCapacitiesClient) CreateOrUpdateThenPoll(ctx context.Context, id CapacityId, input FabricCapacity) error

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (FabricCapacitiesClient) Delete

Delete ...

func (FabricCapacitiesClient) DeleteThenPoll

func (c FabricCapacitiesClient) DeleteThenPoll(ctx context.Context, id CapacityId) error

DeleteThenPoll performs Delete then polls until it's completed

func (FabricCapacitiesClient) Get

Get ...

func (FabricCapacitiesClient) ListByResourceGroup

ListByResourceGroup ...

func (FabricCapacitiesClient) ListByResourceGroupComplete

ListByResourceGroupComplete retrieves all the results into a single object

func (FabricCapacitiesClient) ListByResourceGroupCompleteMatchingPredicate

func (c FabricCapacitiesClient) ListByResourceGroupCompleteMatchingPredicate(ctx context.Context, id commonids.ResourceGroupId, predicate FabricCapacityOperationPredicate) (result ListByResourceGroupCompleteResult, err error)

ListByResourceGroupCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (FabricCapacitiesClient) ListBySubscription

ListBySubscription ...

func (FabricCapacitiesClient) ListBySubscriptionComplete

ListBySubscriptionComplete retrieves all the results into a single object

func (FabricCapacitiesClient) ListBySubscriptionCompleteMatchingPredicate

func (c FabricCapacitiesClient) ListBySubscriptionCompleteMatchingPredicate(ctx context.Context, id commonids.SubscriptionId, predicate FabricCapacityOperationPredicate) (result ListBySubscriptionCompleteResult, err error)

ListBySubscriptionCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (FabricCapacitiesClient) ListSkus

ListSkus ...

func (FabricCapacitiesClient) ListSkusComplete

ListSkusComplete retrieves all the results into a single object

func (FabricCapacitiesClient) ListSkusCompleteMatchingPredicate

ListSkusCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (FabricCapacitiesClient) ListSkusForCapacity

func (c FabricCapacitiesClient) ListSkusForCapacity(ctx context.Context, id CapacityId) (result ListSkusForCapacityOperationResponse, err error)

ListSkusForCapacity ...

func (FabricCapacitiesClient) ListSkusForCapacityComplete

func (c FabricCapacitiesClient) ListSkusForCapacityComplete(ctx context.Context, id CapacityId) (ListSkusForCapacityCompleteResult, error)

ListSkusForCapacityComplete retrieves all the results into a single object

func (FabricCapacitiesClient) ListSkusForCapacityCompleteMatchingPredicate

func (c FabricCapacitiesClient) ListSkusForCapacityCompleteMatchingPredicate(ctx context.Context, id CapacityId, predicate RpSkuDetailsForExistingResourceOperationPredicate) (result ListSkusForCapacityCompleteResult, err error)

ListSkusForCapacityCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (FabricCapacitiesClient) Resume

Resume ...

func (FabricCapacitiesClient) ResumeThenPoll

func (c FabricCapacitiesClient) ResumeThenPoll(ctx context.Context, id CapacityId) error

ResumeThenPoll performs Resume then polls until it's completed

func (FabricCapacitiesClient) Suspend

Suspend ...

func (FabricCapacitiesClient) SuspendThenPoll

func (c FabricCapacitiesClient) SuspendThenPoll(ctx context.Context, id CapacityId) error

SuspendThenPoll performs Suspend then polls until it's completed

func (FabricCapacitiesClient) Update

Update ...

func (FabricCapacitiesClient) UpdateThenPoll

UpdateThenPoll performs Update then polls until it's completed

type FabricCapacity

type FabricCapacity struct {
	Id         *string                  `json:"id,omitempty"`
	Location   string                   `json:"location"`
	Name       *string                  `json:"name,omitempty"`
	Properties FabricCapacityProperties `json:"properties"`
	Sku        RpSku                    `json:"sku"`
	SystemData *systemdata.SystemData   `json:"systemData,omitempty"`
	Tags       *map[string]string       `json:"tags,omitempty"`
	Type       *string                  `json:"type,omitempty"`
}

type FabricCapacityOperationPredicate

type FabricCapacityOperationPredicate struct {
	Id       *string
	Location *string
	Name     *string
	Type     *string
}

func (FabricCapacityOperationPredicate) Matches

type FabricCapacityProperties

type FabricCapacityProperties struct {
	Administration    CapacityAdministration `json:"administration"`
	ProvisioningState *ProvisioningState     `json:"provisioningState,omitempty"`
	State             *ResourceState         `json:"state,omitempty"`
}

type FabricCapacityUpdate

type FabricCapacityUpdate struct {
	Properties *FabricCapacityUpdateProperties `json:"properties,omitempty"`
	Sku        *RpSku                          `json:"sku,omitempty"`
	Tags       *map[string]string              `json:"tags,omitempty"`
}

type FabricCapacityUpdateProperties

type FabricCapacityUpdateProperties struct {
	Administration *CapacityAdministration `json:"administration,omitempty"`
}

type GetOperationResponse

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

type ListByResourceGroupCompleteResult

type ListByResourceGroupCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []FabricCapacity
}

type ListByResourceGroupCustomPager

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

type ListByResourceGroupOperationResponse

type ListByResourceGroupOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]FabricCapacity
}

type ListBySubscriptionCompleteResult

type ListBySubscriptionCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []FabricCapacity
}

type ListBySubscriptionCustomPager

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

type ListBySubscriptionOperationResponse

type ListBySubscriptionOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]FabricCapacity
}

type ListSkusCompleteResult

type ListSkusCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []RpSkuDetailsForNewResource
}

type ListSkusCustomPager

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

type ListSkusForCapacityCompleteResult

type ListSkusForCapacityCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []RpSkuDetailsForExistingResource
}

type ListSkusForCapacityCustomPager

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

type ListSkusForCapacityOperationResponse

type ListSkusForCapacityOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]RpSkuDetailsForExistingResource
}

type ListSkusOperationResponse

type ListSkusOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]RpSkuDetailsForNewResource
}

type LocationId

type LocationId struct {
	SubscriptionId string
	LocationName   string
}

LocationId is a struct representing the Resource ID for a Location

func NewLocationID

func NewLocationID(subscriptionId string, locationName string) LocationId

NewLocationID returns a new LocationId struct

func ParseLocationID

func ParseLocationID(input string) (*LocationId, error)

ParseLocationID parses 'input' into a LocationId

func ParseLocationIDInsensitively

func ParseLocationIDInsensitively(input string) (*LocationId, error)

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

func (*LocationId) FromParseResult

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

func (LocationId) ID

func (id LocationId) ID() string

ID returns the formatted Location ID

func (LocationId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Location ID

func (LocationId) String

func (id LocationId) String() string

String returns a human-readable description of this Location ID

type ProvisioningState

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

func (*ProvisioningState) UnmarshalJSON

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

type ResourceState

type ResourceState string
const (
	ResourceStateActive       ResourceState = "Active"
	ResourceStateDeleting     ResourceState = "Deleting"
	ResourceStateFailed       ResourceState = "Failed"
	ResourceStatePaused       ResourceState = "Paused"
	ResourceStatePausing      ResourceState = "Pausing"
	ResourceStatePreparing    ResourceState = "Preparing"
	ResourceStateProvisioning ResourceState = "Provisioning"
	ResourceStateResuming     ResourceState = "Resuming"
	ResourceStateScaling      ResourceState = "Scaling"
	ResourceStateSuspended    ResourceState = "Suspended"
	ResourceStateSuspending   ResourceState = "Suspending"
	ResourceStateUpdating     ResourceState = "Updating"
)

func (*ResourceState) UnmarshalJSON

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

type ResumeOperationResponse

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

type RpSku

type RpSku struct {
	Name string    `json:"name"`
	Tier RpSkuTier `json:"tier"`
}

type RpSkuDetailsForExistingResource

type RpSkuDetailsForExistingResource struct {
	ResourceType string `json:"resourceType"`
	Sku          RpSku  `json:"sku"`
}

type RpSkuDetailsForExistingResourceOperationPredicate

type RpSkuDetailsForExistingResourceOperationPredicate struct {
	ResourceType *string
}

func (RpSkuDetailsForExistingResourceOperationPredicate) Matches

type RpSkuDetailsForNewResource

type RpSkuDetailsForNewResource struct {
	Locations    []string `json:"locations"`
	Name         string   `json:"name"`
	ResourceType string   `json:"resourceType"`
}

type RpSkuDetailsForNewResourceOperationPredicate

type RpSkuDetailsForNewResourceOperationPredicate struct {
	Name         *string
	ResourceType *string
}

func (RpSkuDetailsForNewResourceOperationPredicate) Matches

type RpSkuTier

type RpSkuTier string
const (
	RpSkuTierFabric RpSkuTier = "Fabric"
)

func (*RpSkuTier) UnmarshalJSON

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

type SuspendOperationResponse

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

type UpdateOperationResponse

type UpdateOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *FabricCapacity
}

Jump to

Keyboard shortcuts

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