elasticsans

package
v0.20230322.1105901 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2023 License: MPL-2.0 Imports: 12 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/elasticsan/2021-11-20-preview/elasticsans Documentation

The elasticsans SDK allows for interaction with the Azure Resource Manager Service elasticsan (API Version 2021-11-20-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/elasticsan/2021-11-20-preview/elasticsans"

Client Initialization

client := elasticsans.NewElasticSansClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ElasticSansClient.Create

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

payload := elasticsans.ElasticSan{
	// ...
}


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

Example Usage: ElasticSansClient.Delete

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

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

Example Usage: ElasticSansClient.Get

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

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: ElasticSansClient.ListBySubscription

ctx := context.TODO()
id := elasticsans.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: ElasticSansClient.Update

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

payload := elasticsans.ElasticSanUpdate{
	// ...
}


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 PossibleValuesForProvisioningStates

func PossibleValuesForProvisioningStates() []string

func PossibleValuesForSkuName

func PossibleValuesForSkuName() []string

func PossibleValuesForSkuTier

func PossibleValuesForSkuTier() []string

func ValidateElasticSanID

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

ValidateElasticSanID checks that 'input' can be parsed as a Elastic San ID

Types

type CreateOperationResponse

type CreateOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type DeleteOperationResponse

type DeleteOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type ElasticSan

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

type ElasticSanId

type ElasticSanId struct {
	SubscriptionId    string
	ResourceGroupName string
	ElasticSanName    string
}

ElasticSanId is a struct representing the Resource ID for a Elastic San

func NewElasticSanID

func NewElasticSanID(subscriptionId string, resourceGroupName string, elasticSanName string) ElasticSanId

NewElasticSanID returns a new ElasticSanId struct

func ParseElasticSanID

func ParseElasticSanID(input string) (*ElasticSanId, error)

ParseElasticSanID parses 'input' into a ElasticSanId

func ParseElasticSanIDInsensitively

func ParseElasticSanIDInsensitively(input string) (*ElasticSanId, error)

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

func (ElasticSanId) ID

func (id ElasticSanId) ID() string

ID returns the formatted Elastic San ID

func (ElasticSanId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Elastic San ID

func (ElasticSanId) String

func (id ElasticSanId) String() string

String returns a human-readable description of this Elastic San ID

type ElasticSanOperationPredicate

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

func (ElasticSanOperationPredicate) Matches

func (p ElasticSanOperationPredicate) Matches(input ElasticSan) bool

type ElasticSanProperties

type ElasticSanProperties struct {
	AvailabilityZones       *zones.Schema       `json:"availabilityZones,omitempty"`
	BaseSizeTiB             int64               `json:"baseSizeTiB"`
	ExtendedCapacitySizeTiB int64               `json:"extendedCapacitySizeTiB"`
	ProvisioningState       *ProvisioningStates `json:"provisioningState,omitempty"`
	Sku                     Sku                 `json:"sku"`
	TotalIops               *int64              `json:"totalIops,omitempty"`
	TotalMBps               *int64              `json:"totalMBps,omitempty"`
	TotalSizeTiB            *int64              `json:"totalSizeTiB,omitempty"`
	TotalVolumeSizeGiB      *int64              `json:"totalVolumeSizeGiB,omitempty"`
	VolumeGroupCount        *int64              `json:"volumeGroupCount,omitempty"`
}

type ElasticSanUpdate

type ElasticSanUpdate struct {
	Properties *ElasticSanUpdateProperties `json:"properties,omitempty"`
	Tags       *map[string]string          `json:"tags,omitempty"`
}

type ElasticSanUpdateProperties

type ElasticSanUpdateProperties struct {
	BaseSizeTiB             *int64 `json:"baseSizeTiB,omitempty"`
	ExtendedCapacitySizeTiB *int64 `json:"extendedCapacitySizeTiB,omitempty"`
}

type ElasticSansClient

type ElasticSansClient struct {
	Client autorest.Client
	// contains filtered or unexported fields
}

func NewElasticSansClientWithBaseURI

func NewElasticSansClientWithBaseURI(endpoint string) ElasticSansClient

func (ElasticSansClient) Create

func (c ElasticSansClient) Create(ctx context.Context, id ElasticSanId, input ElasticSan) (result CreateOperationResponse, err error)

Create ...

func (ElasticSansClient) CreateThenPoll

func (c ElasticSansClient) CreateThenPoll(ctx context.Context, id ElasticSanId, input ElasticSan) error

CreateThenPoll performs Create then polls until it's completed

func (ElasticSansClient) Delete

Delete ...

func (ElasticSansClient) DeleteThenPoll

func (c ElasticSansClient) DeleteThenPoll(ctx context.Context, id ElasticSanId) error

DeleteThenPoll performs Delete then polls until it's completed

func (ElasticSansClient) Get

Get ...

func (ElasticSansClient) ListBySubscription

ListBySubscription ...

func (ElasticSansClient) ListBySubscriptionComplete

ListBySubscriptionComplete retrieves all of the results into a single object

func (ElasticSansClient) ListBySubscriptionCompleteMatchingPredicate

func (c ElasticSansClient) ListBySubscriptionCompleteMatchingPredicate(ctx context.Context, id commonids.SubscriptionId, predicate ElasticSanOperationPredicate) (resp ListBySubscriptionCompleteResult, err error)

ListBySubscriptionCompleteMatchingPredicate retrieves all of the results and then applied the predicate

func (ElasticSansClient) Update

Update ...

func (ElasticSansClient) UpdateThenPoll

func (c ElasticSansClient) UpdateThenPoll(ctx context.Context, id ElasticSanId, input ElasticSanUpdate) error

UpdateThenPoll performs Update then polls until it's completed

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	Model        *ElasticSan
}

type ListBySubscriptionCompleteResult

type ListBySubscriptionCompleteResult struct {
	Items []ElasticSan
}

type ListBySubscriptionOperationResponse

type ListBySubscriptionOperationResponse struct {
	HttpResponse *http.Response
	Model        *[]ElasticSan
	// contains filtered or unexported fields
}

func (ListBySubscriptionOperationResponse) HasMore

func (ListBySubscriptionOperationResponse) LoadMore

type ProvisioningStates

type ProvisioningStates string
const (
	ProvisioningStatesCanceled  ProvisioningStates = "Canceled"
	ProvisioningStatesCreating  ProvisioningStates = "Creating"
	ProvisioningStatesDeleting  ProvisioningStates = "Deleting"
	ProvisioningStatesFailed    ProvisioningStates = "Failed"
	ProvisioningStatesInvalid   ProvisioningStates = "Invalid"
	ProvisioningStatesPending   ProvisioningStates = "Pending"
	ProvisioningStatesSucceeded ProvisioningStates = "Succeeded"
	ProvisioningStatesUpdating  ProvisioningStates = "Updating"
)

type Sku

type Sku struct {
	Name SkuName  `json:"name"`
	Tier *SkuTier `json:"tier,omitempty"`
}

type SkuName

type SkuName string
const (
	SkuNamePremiumLRS SkuName = "Premium_LRS"
	SkuNamePremiumZRS SkuName = "Premium_ZRS"
)

type SkuTier

type SkuTier string
const (
	SkuTierPremium SkuTier = "Premium"
)

type UpdateOperationResponse

type UpdateOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

Jump to

Keyboard shortcuts

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