storageaccountclient

package
v1.23.4 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2022 License: Apache-2.0 Imports: 15 Imported by: 2

Documentation

Overview

Package storageaccountclient implements the client for StorageAccounts.

Index

Constants

View Source
const (
	// APIVersion is the API version for network.
	APIVersion = "2021-02-01"
	// AzureStackCloudAPIVersion is the API version for Azure Stack
	AzureStackCloudAPIVersion = "2018-02-01"
	// AzureStackCloudName is the cloud name of Azure Stack
	AzureStackCloudName = "AZURESTACKCLOUD"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AccountListResultPage

type AccountListResultPage struct {
	// contains filtered or unexported fields
}

AccountListResultPage contains a page of Account values.

func (*AccountListResultPage) Next

func (page *AccountListResultPage) Next() error

Next advances to the next page of values. If there was an error making the request the page does not advance and the error is returned. Deprecated: Use NextWithContext() instead.

func (*AccountListResultPage) NextWithContext

func (page *AccountListResultPage) NextWithContext(ctx context.Context) (err error)

NextWithContext advances to the next page of values. If there was an error making the request the page does not advance and the error is returned.

func (AccountListResultPage) NotDone

func (page AccountListResultPage) NotDone() bool

NotDone returns true if the page enumeration should be started or is not yet complete.

func (AccountListResultPage) Response

Response returns the raw server response from the last page request.

func (AccountListResultPage) Values

func (page AccountListResultPage) Values() []storage.Account

Values returns the slice of values for the current page or nil if there are no values.

type Client

type Client struct {

	// ARM throttling configures.
	RetryAfterReader time.Time
	RetryAfterWriter time.Time
	// contains filtered or unexported fields
}

Client implements StorageAccount client Interface.

func New

func New(config *azclients.ClientConfig) *Client

New creates a new StorageAccount client with ratelimiting.

func (*Client) Create

func (c *Client) Create(ctx context.Context, resourceGroupName string, accountName string, parameters storage.AccountCreateParameters) *retry.Error

Create creates a StorageAccount.

func (*Client) Delete

func (c *Client) Delete(ctx context.Context, resourceGroupName string, accountName string) *retry.Error

Delete deletes a StorageAccount by name.

func (*Client) GetProperties

func (c *Client) GetProperties(ctx context.Context, resourceGroupName string, accountName string) (storage.Account, *retry.Error)

GetProperties gets properties of the StorageAccount.

func (*Client) ListByResourceGroup

func (c *Client) ListByResourceGroup(ctx context.Context, resourceGroupName string) ([]storage.Account, *retry.Error)

ListByResourceGroup get a list storage accounts by resourceGroup.

func (*Client) ListKeys

func (c *Client) ListKeys(ctx context.Context, resourceGroupName string, accountName string) (storage.AccountListKeysResult, *retry.Error)

ListKeys get a list of storage account keys.

func (*Client) ListStorageAccountByResourceGroup

func (c *Client) ListStorageAccountByResourceGroup(ctx context.Context, resourceGroupName string) ([]storage.Account, *retry.Error)

ListStorageAccountByResourceGroup get a list storage accounts by resourceGroup.

func (*Client) StorageAccountResultPreparer

func (c *Client) StorageAccountResultPreparer(ctx context.Context, lr storage.AccountListResult) (*http.Request, error)

StorageAccountResultPreparer prepares a request to retrieve the next set of results. It returns nil if no more results exist.

func (*Client) Update added in v0.7.1

func (c *Client) Update(ctx context.Context, resourceGroupName string, accountName string, parameters storage.AccountUpdateParameters) *retry.Error

Update updates a storage account.

type Interface

type Interface interface {
	// Create creates a StorageAccount.
	Create(ctx context.Context, resourceGroupName string, accountName string, parameters storage.AccountCreateParameters) *retry.Error

	// Update updates a StorageAccount.
	Update(ctx context.Context, resourceGroupName string, accountName string, parameters storage.AccountUpdateParameters) *retry.Error

	// Delete deletes a StorageAccount by name.
	Delete(ctx context.Context, resourceGroupName string, accountName string) *retry.Error

	// ListKeys get a list of storage account keys.
	ListKeys(ctx context.Context, resourceGroupName string, accountName string) (storage.AccountListKeysResult, *retry.Error)

	// ListByResourceGroup get a list storage accounts by resourceGroup.
	ListByResourceGroup(ctx context.Context, resourceGroupName string) ([]storage.Account, *retry.Error)

	// GetProperties gets properties of the StorageAccount.
	GetProperties(ctx context.Context, resourceGroupName string, accountName string) (result storage.Account, rerr *retry.Error)
}

Interface is the client interface for StorageAccounts. Don't forget to run "hack/update-mock-clients.sh" command to generate the mock client.

Directories

Path Synopsis
Package mockstorageaccountclient implements the mock client for StorageAccounts.
Package mockstorageaccountclient implements the mock client for StorageAccounts.

Jump to

Keyboard shortcuts

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