Documentation ¶
Index ¶
- type AccessPolicy
- type AccessTier
- type Account
- type AccountCheckNameAvailabilityParameters
- type AccountCreateParameters
- type AccountImmutabilityPolicyProperties
- type AccountImmutabilityPolicyState
- type AccountInternetEndpoints
- type AccountKey
- type AccountListKeysResult
- type AccountListResult
- type AccountMicrosoftEndpoints
- type AccountProperties
- type AccountPropertiesCreateParameters
- type AccountPropertiesUpdateParameters
- type AccountRegenerateKeyParameters
- type AccountSasParameters
- type AccountStatus
- type AccountUpdateParameters
- type AccountsClient
- func (client *AccountsClient) BeginAbortHierarchicalNamespaceMigration(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse, error)
- func (client *AccountsClient) BeginCreate(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientCreatePollerResponse, error)
- func (client *AccountsClient) BeginFailover(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientFailoverPollerResponse, error)
- func (client *AccountsClient) BeginHierarchicalNamespaceMigration(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientHierarchicalNamespaceMigrationPollerResponse, error)
- func (client *AccountsClient) BeginRestoreBlobRanges(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientRestoreBlobRangesPollerResponse, error)
- func (client *AccountsClient) CheckNameAvailability(ctx context.Context, accountName AccountCheckNameAvailabilityParameters, ...) (AccountsClientCheckNameAvailabilityResponse, error)
- func (client *AccountsClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientDeleteResponse, error)
- func (client *AccountsClient) GetProperties(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientGetPropertiesResponse, error)
- func (client *AccountsClient) List(options *AccountsClientListOptions) *AccountsClientListPager
- func (client *AccountsClient) ListAccountSAS(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientListAccountSASResponse, error)
- func (client *AccountsClient) ListByResourceGroup(resourceGroupName string, options *AccountsClientListByResourceGroupOptions) *AccountsClientListByResourceGroupPager
- func (client *AccountsClient) ListKeys(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientListKeysResponse, error)
- func (client *AccountsClient) ListServiceSAS(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientListServiceSASResponse, error)
- func (client *AccountsClient) RegenerateKey(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientRegenerateKeyResponse, error)
- func (client *AccountsClient) RevokeUserDelegationKeys(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientRevokeUserDelegationKeysResponse, error)
- func (client *AccountsClient) Update(ctx context.Context, resourceGroupName string, accountName string, ...) (AccountsClientUpdateResponse, error)
- type AccountsClientAbortHierarchicalNamespaceMigrationPoller
- func (p *AccountsClientAbortHierarchicalNamespaceMigrationPoller) Done() bool
- func (p *AccountsClientAbortHierarchicalNamespaceMigrationPoller) FinalResponse(ctx context.Context) (AccountsClientAbortHierarchicalNamespaceMigrationResponse, error)
- func (p *AccountsClientAbortHierarchicalNamespaceMigrationPoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *AccountsClientAbortHierarchicalNamespaceMigrationPoller) ResumeToken() (string, error)
- type AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse
- func (l AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (AccountsClientAbortHierarchicalNamespaceMigrationResponse, error)
- func (l *AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse) Resume(ctx context.Context, client *AccountsClient, token string) error
- type AccountsClientAbortHierarchicalNamespaceMigrationResponse
- type AccountsClientBeginAbortHierarchicalNamespaceMigrationOptions
- type AccountsClientBeginCreateOptions
- type AccountsClientBeginFailoverOptions
- type AccountsClientBeginHierarchicalNamespaceMigrationOptions
- type AccountsClientBeginRestoreBlobRangesOptions
- type AccountsClientCheckNameAvailabilityOptions
- type AccountsClientCheckNameAvailabilityResponse
- type AccountsClientCheckNameAvailabilityResult
- type AccountsClientCreatePoller
- func (p *AccountsClientCreatePoller) Done() bool
- func (p *AccountsClientCreatePoller) FinalResponse(ctx context.Context) (AccountsClientCreateResponse, error)
- func (p *AccountsClientCreatePoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *AccountsClientCreatePoller) ResumeToken() (string, error)
- type AccountsClientCreatePollerResponse
- type AccountsClientCreateResponse
- type AccountsClientCreateResult
- type AccountsClientDeleteOptions
- type AccountsClientDeleteResponse
- type AccountsClientFailoverPoller
- func (p *AccountsClientFailoverPoller) Done() bool
- func (p *AccountsClientFailoverPoller) FinalResponse(ctx context.Context) (AccountsClientFailoverResponse, error)
- func (p *AccountsClientFailoverPoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *AccountsClientFailoverPoller) ResumeToken() (string, error)
- type AccountsClientFailoverPollerResponse
- type AccountsClientFailoverResponse
- type AccountsClientGetPropertiesOptions
- type AccountsClientGetPropertiesResponse
- type AccountsClientGetPropertiesResult
- type AccountsClientHierarchicalNamespaceMigrationPoller
- func (p *AccountsClientHierarchicalNamespaceMigrationPoller) Done() bool
- func (p *AccountsClientHierarchicalNamespaceMigrationPoller) FinalResponse(ctx context.Context) (AccountsClientHierarchicalNamespaceMigrationResponse, error)
- func (p *AccountsClientHierarchicalNamespaceMigrationPoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *AccountsClientHierarchicalNamespaceMigrationPoller) ResumeToken() (string, error)
- type AccountsClientHierarchicalNamespaceMigrationPollerResponse
- func (l AccountsClientHierarchicalNamespaceMigrationPollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (AccountsClientHierarchicalNamespaceMigrationResponse, error)
- func (l *AccountsClientHierarchicalNamespaceMigrationPollerResponse) Resume(ctx context.Context, client *AccountsClient, token string) error
- type AccountsClientHierarchicalNamespaceMigrationResponse
- type AccountsClientListAccountSASOptions
- type AccountsClientListAccountSASResponse
- type AccountsClientListAccountSASResult
- type AccountsClientListByResourceGroupOptions
- type AccountsClientListByResourceGroupPager
- type AccountsClientListByResourceGroupResponse
- type AccountsClientListByResourceGroupResult
- type AccountsClientListKeysOptions
- type AccountsClientListKeysResponse
- type AccountsClientListKeysResult
- type AccountsClientListOptions
- type AccountsClientListPager
- type AccountsClientListResponse
- type AccountsClientListResult
- type AccountsClientListServiceSASOptions
- type AccountsClientListServiceSASResponse
- type AccountsClientListServiceSASResult
- type AccountsClientRegenerateKeyOptions
- type AccountsClientRegenerateKeyResponse
- type AccountsClientRegenerateKeyResult
- type AccountsClientRestoreBlobRangesPoller
- func (p *AccountsClientRestoreBlobRangesPoller) Done() bool
- func (p *AccountsClientRestoreBlobRangesPoller) FinalResponse(ctx context.Context) (AccountsClientRestoreBlobRangesResponse, error)
- func (p *AccountsClientRestoreBlobRangesPoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *AccountsClientRestoreBlobRangesPoller) ResumeToken() (string, error)
- type AccountsClientRestoreBlobRangesPollerResponse
- type AccountsClientRestoreBlobRangesResponse
- type AccountsClientRestoreBlobRangesResult
- type AccountsClientRevokeUserDelegationKeysOptions
- type AccountsClientRevokeUserDelegationKeysResponse
- type AccountsClientUpdateOptions
- type AccountsClientUpdateResponse
- type AccountsClientUpdateResult
- type ActiveDirectoryProperties
- type ActiveDirectoryPropertiesAccountType
- type AllowedCopyScope
- type AzureEntityResource
- type AzureFilesIdentityBasedAuthentication
- type BlobContainer
- type BlobContainersClient
- func (client *BlobContainersClient) BeginObjectLevelWorm(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientObjectLevelWormPollerResponse, error)
- func (client *BlobContainersClient) ClearLegalHold(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientClearLegalHoldResponse, error)
- func (client *BlobContainersClient) Create(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientCreateResponse, error)
- func (client *BlobContainersClient) CreateOrUpdateImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientCreateOrUpdateImmutabilityPolicyResponse, error)
- func (client *BlobContainersClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientDeleteResponse, error)
- func (client *BlobContainersClient) DeleteImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientDeleteImmutabilityPolicyResponse, error)
- func (client *BlobContainersClient) ExtendImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientExtendImmutabilityPolicyResponse, error)
- func (client *BlobContainersClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientGetResponse, error)
- func (client *BlobContainersClient) GetImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientGetImmutabilityPolicyResponse, error)
- func (client *BlobContainersClient) Lease(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientLeaseResponse, error)
- func (client *BlobContainersClient) List(resourceGroupName string, accountName string, ...) *BlobContainersClientListPager
- func (client *BlobContainersClient) LockImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientLockImmutabilityPolicyResponse, error)
- func (client *BlobContainersClient) SetLegalHold(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientSetLegalHoldResponse, error)
- func (client *BlobContainersClient) Update(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobContainersClientUpdateResponse, error)
- type BlobContainersClientBeginObjectLevelWormOptions
- type BlobContainersClientClearLegalHoldOptions
- type BlobContainersClientClearLegalHoldResponse
- type BlobContainersClientClearLegalHoldResult
- type BlobContainersClientCreateOptions
- type BlobContainersClientCreateOrUpdateImmutabilityPolicyOptions
- type BlobContainersClientCreateOrUpdateImmutabilityPolicyResponse
- type BlobContainersClientCreateOrUpdateImmutabilityPolicyResult
- type BlobContainersClientCreateResponse
- type BlobContainersClientCreateResult
- type BlobContainersClientDeleteImmutabilityPolicyOptions
- type BlobContainersClientDeleteImmutabilityPolicyResponse
- type BlobContainersClientDeleteImmutabilityPolicyResult
- type BlobContainersClientDeleteOptions
- type BlobContainersClientDeleteResponse
- type BlobContainersClientExtendImmutabilityPolicyOptions
- type BlobContainersClientExtendImmutabilityPolicyResponse
- type BlobContainersClientExtendImmutabilityPolicyResult
- type BlobContainersClientGetImmutabilityPolicyOptions
- type BlobContainersClientGetImmutabilityPolicyResponse
- type BlobContainersClientGetImmutabilityPolicyResult
- type BlobContainersClientGetOptions
- type BlobContainersClientGetResponse
- type BlobContainersClientGetResult
- type BlobContainersClientLeaseOptions
- type BlobContainersClientLeaseResponse
- type BlobContainersClientLeaseResult
- type BlobContainersClientListOptions
- type BlobContainersClientListPager
- type BlobContainersClientListResponse
- type BlobContainersClientListResult
- type BlobContainersClientLockImmutabilityPolicyOptions
- type BlobContainersClientLockImmutabilityPolicyResponse
- type BlobContainersClientLockImmutabilityPolicyResult
- type BlobContainersClientObjectLevelWormPoller
- func (p *BlobContainersClientObjectLevelWormPoller) Done() bool
- func (p *BlobContainersClientObjectLevelWormPoller) FinalResponse(ctx context.Context) (BlobContainersClientObjectLevelWormResponse, error)
- func (p *BlobContainersClientObjectLevelWormPoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *BlobContainersClientObjectLevelWormPoller) ResumeToken() (string, error)
- type BlobContainersClientObjectLevelWormPollerResponse
- func (l BlobContainersClientObjectLevelWormPollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (BlobContainersClientObjectLevelWormResponse, error)
- func (l *BlobContainersClientObjectLevelWormPollerResponse) Resume(ctx context.Context, client *BlobContainersClient, token string) error
- type BlobContainersClientObjectLevelWormResponse
- type BlobContainersClientSetLegalHoldOptions
- type BlobContainersClientSetLegalHoldResponse
- type BlobContainersClientSetLegalHoldResult
- type BlobContainersClientUpdateOptions
- type BlobContainersClientUpdateResponse
- type BlobContainersClientUpdateResult
- type BlobInventoryPoliciesClient
- func (client *BlobInventoryPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobInventoryPoliciesClientCreateOrUpdateResponse, error)
- func (client *BlobInventoryPoliciesClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobInventoryPoliciesClientDeleteResponse, error)
- func (client *BlobInventoryPoliciesClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobInventoryPoliciesClientGetResponse, error)
- func (client *BlobInventoryPoliciesClient) List(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobInventoryPoliciesClientListResponse, error)
- type BlobInventoryPoliciesClientCreateOrUpdateOptions
- type BlobInventoryPoliciesClientCreateOrUpdateResponse
- type BlobInventoryPoliciesClientCreateOrUpdateResult
- type BlobInventoryPoliciesClientDeleteOptions
- type BlobInventoryPoliciesClientDeleteResponse
- type BlobInventoryPoliciesClientGetOptions
- type BlobInventoryPoliciesClientGetResponse
- type BlobInventoryPoliciesClientGetResult
- type BlobInventoryPoliciesClientListOptions
- type BlobInventoryPoliciesClientListResponse
- type BlobInventoryPoliciesClientListResult
- type BlobInventoryPolicy
- type BlobInventoryPolicyDefinition
- type BlobInventoryPolicyFilter
- type BlobInventoryPolicyName
- type BlobInventoryPolicyProperties
- type BlobInventoryPolicyRule
- type BlobInventoryPolicySchema
- type BlobRestoreParameters
- type BlobRestoreProgressStatus
- type BlobRestoreRange
- type BlobRestoreStatus
- type BlobServiceItems
- type BlobServiceProperties
- type BlobServicePropertiesProperties
- type BlobServicesClient
- func (client *BlobServicesClient) GetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobServicesClientGetServicePropertiesResponse, error)
- func (client *BlobServicesClient) List(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobServicesClientListResponse, error)
- func (client *BlobServicesClient) SetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, ...) (BlobServicesClientSetServicePropertiesResponse, error)
- type BlobServicesClientGetServicePropertiesOptions
- type BlobServicesClientGetServicePropertiesResponse
- type BlobServicesClientGetServicePropertiesResult
- type BlobServicesClientListOptions
- type BlobServicesClientListResponse
- type BlobServicesClientListResult
- type BlobServicesClientSetServicePropertiesOptions
- type BlobServicesClientSetServicePropertiesResponse
- type BlobServicesClientSetServicePropertiesResult
- type Bypass
- type ChangeFeed
- type CheckNameAvailabilityResult
- type ContainerProperties
- type CorsRule
- type CorsRuleAllowedMethodsItem
- type CorsRules
- type CreatedByType
- type CustomDomain
- type DateAfterCreation
- type DateAfterModification
- type DefaultAction
- type DefaultSharePermission
- type DeleteRetentionPolicy
- type DeletedAccount
- type DeletedAccountListResult
- type DeletedAccountProperties
- type DeletedAccountsClient
- type DeletedAccountsClientGetOptions
- type DeletedAccountsClientGetResponse
- type DeletedAccountsClientGetResult
- type DeletedAccountsClientListOptions
- type DeletedAccountsClientListPager
- type DeletedAccountsClientListResponse
- type DeletedAccountsClientListResult
- type DeletedShare
- type Dimension
- type DirectoryServiceOptions
- type EnabledProtocols
- type Encryption
- type EncryptionIdentity
- type EncryptionScope
- type EncryptionScopeKeyVaultProperties
- type EncryptionScopeListResult
- type EncryptionScopeProperties
- type EncryptionScopeSource
- type EncryptionScopeState
- type EncryptionScopesClient
- func (client *EncryptionScopesClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (EncryptionScopesClientGetResponse, error)
- func (client *EncryptionScopesClient) List(resourceGroupName string, accountName string, ...) *EncryptionScopesClientListPager
- func (client *EncryptionScopesClient) Patch(ctx context.Context, resourceGroupName string, accountName string, ...) (EncryptionScopesClientPatchResponse, error)
- func (client *EncryptionScopesClient) Put(ctx context.Context, resourceGroupName string, accountName string, ...) (EncryptionScopesClientPutResponse, error)
- type EncryptionScopesClientGetOptions
- type EncryptionScopesClientGetResponse
- type EncryptionScopesClientGetResult
- type EncryptionScopesClientListOptions
- type EncryptionScopesClientListPager
- type EncryptionScopesClientListResponse
- type EncryptionScopesClientListResult
- type EncryptionScopesClientPatchOptions
- type EncryptionScopesClientPatchResponse
- type EncryptionScopesClientPatchResult
- type EncryptionScopesClientPutOptions
- type EncryptionScopesClientPutResponse
- type EncryptionScopesClientPutResult
- type EncryptionService
- type EncryptionServices
- type Endpoints
- type ExpirationAction
- type ExtendedLocation
- type ExtendedLocationTypes
- type FileServiceItems
- type FileServiceProperties
- type FileServicePropertiesProperties
- type FileServicesClient
- func (client *FileServicesClient) GetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, ...) (FileServicesClientGetServicePropertiesResponse, error)
- func (client *FileServicesClient) List(ctx context.Context, resourceGroupName string, accountName string, ...) (FileServicesClientListResponse, error)
- func (client *FileServicesClient) SetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, ...) (FileServicesClientSetServicePropertiesResponse, error)
- type FileServicesClientGetServicePropertiesOptions
- type FileServicesClientGetServicePropertiesResponse
- type FileServicesClientGetServicePropertiesResult
- type FileServicesClientListOptions
- type FileServicesClientListResponse
- type FileServicesClientListResult
- type FileServicesClientSetServicePropertiesOptions
- type FileServicesClientSetServicePropertiesResponse
- type FileServicesClientSetServicePropertiesResult
- type FileShare
- type FileShareItem
- type FileShareItems
- type FileShareProperties
- type FileSharesClient
- func (client *FileSharesClient) Create(ctx context.Context, resourceGroupName string, accountName string, ...) (FileSharesClientCreateResponse, error)
- func (client *FileSharesClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (FileSharesClientDeleteResponse, error)
- func (client *FileSharesClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (FileSharesClientGetResponse, error)
- func (client *FileSharesClient) Lease(ctx context.Context, resourceGroupName string, accountName string, ...) (FileSharesClientLeaseResponse, error)
- func (client *FileSharesClient) List(resourceGroupName string, accountName string, ...) *FileSharesClientListPager
- func (client *FileSharesClient) Restore(ctx context.Context, resourceGroupName string, accountName string, ...) (FileSharesClientRestoreResponse, error)
- func (client *FileSharesClient) Update(ctx context.Context, resourceGroupName string, accountName string, ...) (FileSharesClientUpdateResponse, error)
- type FileSharesClientCreateOptions
- type FileSharesClientCreateResponse
- type FileSharesClientCreateResult
- type FileSharesClientDeleteOptions
- type FileSharesClientDeleteResponse
- type FileSharesClientGetOptions
- type FileSharesClientGetResponse
- type FileSharesClientGetResult
- type FileSharesClientLeaseOptions
- type FileSharesClientLeaseResponse
- type FileSharesClientLeaseResult
- type FileSharesClientListOptions
- type FileSharesClientListPager
- type FileSharesClientListResponse
- type FileSharesClientListResult
- type FileSharesClientRestoreOptions
- type FileSharesClientRestoreResponse
- type FileSharesClientUpdateOptions
- type FileSharesClientUpdateResponse
- type FileSharesClientUpdateResult
- type Format
- type GeoReplicationStats
- type GeoReplicationStatus
- type HTTPProtocol
- type IPRule
- type Identity
- type IdentityType
- type ImmutabilityPolicy
- type ImmutabilityPolicyProperties
- type ImmutabilityPolicyProperty
- type ImmutabilityPolicyState
- type ImmutabilityPolicyUpdateType
- type ImmutableStorageAccount
- type ImmutableStorageWithVersioning
- type InventoryRuleType
- type KeyCreationTime
- type KeyPermission
- type KeyPolicy
- type KeySource
- type KeyType
- type KeyVaultProperties
- type Kind
- type LargeFileSharesState
- type LastAccessTimeTrackingPolicy
- type LeaseContainerRequest
- type LeaseContainerRequestAction
- type LeaseContainerResponse
- type LeaseDuration
- type LeaseShareAction
- type LeaseShareRequest
- type LeaseShareResponse
- type LeaseState
- type LeaseStatus
- type LegalHold
- type LegalHoldProperties
- type ListAccountSasResponse
- type ListBlobInventoryPolicy
- type ListContainerItem
- type ListContainerItems
- type ListContainersInclude
- type ListQueue
- type ListQueueProperties
- type ListQueueResource
- type ListQueueServices
- type ListServiceSasResponse
- type ListTableResource
- type ListTableServices
- type LocalUser
- type LocalUserKeys
- type LocalUserProperties
- type LocalUserRegeneratePasswordResult
- type LocalUsers
- type LocalUsersClient
- func (client *LocalUsersClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, accountName string, ...) (LocalUsersClientCreateOrUpdateResponse, error)
- func (client *LocalUsersClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (LocalUsersClientDeleteResponse, error)
- func (client *LocalUsersClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (LocalUsersClientGetResponse, error)
- func (client *LocalUsersClient) List(ctx context.Context, resourceGroupName string, accountName string, ...) (LocalUsersClientListResponse, error)
- func (client *LocalUsersClient) ListKeys(ctx context.Context, resourceGroupName string, accountName string, ...) (LocalUsersClientListKeysResponse, error)
- func (client *LocalUsersClient) RegeneratePassword(ctx context.Context, resourceGroupName string, accountName string, ...) (LocalUsersClientRegeneratePasswordResponse, error)
- type LocalUsersClientCreateOrUpdateOptions
- type LocalUsersClientCreateOrUpdateResponse
- type LocalUsersClientCreateOrUpdateResult
- type LocalUsersClientDeleteOptions
- type LocalUsersClientDeleteResponse
- type LocalUsersClientGetOptions
- type LocalUsersClientGetResponse
- type LocalUsersClientGetResult
- type LocalUsersClientListKeysOptions
- type LocalUsersClientListKeysResponse
- type LocalUsersClientListKeysResult
- type LocalUsersClientListOptions
- type LocalUsersClientListResponse
- type LocalUsersClientListResult
- type LocalUsersClientRegeneratePasswordOptions
- type LocalUsersClientRegeneratePasswordResponse
- type LocalUsersClientRegeneratePasswordResult
- type ManagementPoliciesClient
- func (client *ManagementPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, accountName string, ...) (ManagementPoliciesClientCreateOrUpdateResponse, error)
- func (client *ManagementPoliciesClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (ManagementPoliciesClientDeleteResponse, error)
- func (client *ManagementPoliciesClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (ManagementPoliciesClientGetResponse, error)
- type ManagementPoliciesClientCreateOrUpdateOptions
- type ManagementPoliciesClientCreateOrUpdateResponse
- type ManagementPoliciesClientCreateOrUpdateResult
- type ManagementPoliciesClientDeleteOptions
- type ManagementPoliciesClientDeleteResponse
- type ManagementPoliciesClientGetOptions
- type ManagementPoliciesClientGetResponse
- type ManagementPoliciesClientGetResult
- type ManagementPolicy
- type ManagementPolicyAction
- type ManagementPolicyBaseBlob
- type ManagementPolicyDefinition
- type ManagementPolicyFilter
- type ManagementPolicyName
- type ManagementPolicyProperties
- type ManagementPolicyRule
- type ManagementPolicySchema
- type ManagementPolicySnapShot
- type ManagementPolicyVersion
- type MetricSpecification
- type MigrationState
- type MinimumTLSVersion
- type Multichannel
- type Name
- type NetworkRuleSet
- type ObjectReplicationPolicies
- type ObjectReplicationPoliciesClient
- func (client *ObjectReplicationPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, accountName string, ...) (ObjectReplicationPoliciesClientCreateOrUpdateResponse, error)
- func (client *ObjectReplicationPoliciesClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (ObjectReplicationPoliciesClientDeleteResponse, error)
- func (client *ObjectReplicationPoliciesClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (ObjectReplicationPoliciesClientGetResponse, error)
- func (client *ObjectReplicationPoliciesClient) List(ctx context.Context, resourceGroupName string, accountName string, ...) (ObjectReplicationPoliciesClientListResponse, error)
- type ObjectReplicationPoliciesClientCreateOrUpdateOptions
- type ObjectReplicationPoliciesClientCreateOrUpdateResponse
- type ObjectReplicationPoliciesClientCreateOrUpdateResult
- type ObjectReplicationPoliciesClientDeleteOptions
- type ObjectReplicationPoliciesClientDeleteResponse
- type ObjectReplicationPoliciesClientGetOptions
- type ObjectReplicationPoliciesClientGetResponse
- type ObjectReplicationPoliciesClientGetResult
- type ObjectReplicationPoliciesClientListOptions
- type ObjectReplicationPoliciesClientListResponse
- type ObjectReplicationPoliciesClientListResult
- type ObjectReplicationPolicy
- type ObjectReplicationPolicyFilter
- type ObjectReplicationPolicyProperties
- type ObjectReplicationPolicyRule
- type ObjectType
- type Operation
- type OperationDisplay
- type OperationListResult
- type OperationProperties
- type OperationsClient
- type OperationsClientListOptions
- type OperationsClientListResponse
- type OperationsClientListResult
- type PermissionScope
- type Permissions
- type PrivateEndpoint
- type PrivateEndpointConnection
- type PrivateEndpointConnectionListResult
- type PrivateEndpointConnectionProperties
- type PrivateEndpointConnectionProvisioningState
- type PrivateEndpointConnectionsClient
- func (client *PrivateEndpointConnectionsClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (PrivateEndpointConnectionsClientDeleteResponse, error)
- func (client *PrivateEndpointConnectionsClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (PrivateEndpointConnectionsClientGetResponse, error)
- func (client *PrivateEndpointConnectionsClient) List(ctx context.Context, resourceGroupName string, accountName string, ...) (PrivateEndpointConnectionsClientListResponse, error)
- func (client *PrivateEndpointConnectionsClient) Put(ctx context.Context, resourceGroupName string, accountName string, ...) (PrivateEndpointConnectionsClientPutResponse, error)
- type PrivateEndpointConnectionsClientDeleteOptions
- type PrivateEndpointConnectionsClientDeleteResponse
- type PrivateEndpointConnectionsClientGetOptions
- type PrivateEndpointConnectionsClientGetResponse
- type PrivateEndpointConnectionsClientGetResult
- type PrivateEndpointConnectionsClientListOptions
- type PrivateEndpointConnectionsClientListResponse
- type PrivateEndpointConnectionsClientListResult
- type PrivateEndpointConnectionsClientPutOptions
- type PrivateEndpointConnectionsClientPutResponse
- type PrivateEndpointConnectionsClientPutResult
- type PrivateEndpointServiceConnectionStatus
- type PrivateLinkResource
- type PrivateLinkResourceListResult
- type PrivateLinkResourceProperties
- type PrivateLinkResourcesClient
- type PrivateLinkResourcesClientListByStorageAccountOptions
- type PrivateLinkResourcesClientListByStorageAccountResponse
- type PrivateLinkResourcesClientListByStorageAccountResult
- type PrivateLinkServiceConnectionState
- type ProtectedAppendWritesHistory
- type ProtocolSettings
- type ProvisioningState
- type ProxyResource
- type PublicAccess
- type PublicNetworkAccess
- type Queue
- type QueueClient
- func (client *QueueClient) Create(ctx context.Context, resourceGroupName string, accountName string, ...) (QueueClientCreateResponse, error)
- func (client *QueueClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (QueueClientDeleteResponse, error)
- func (client *QueueClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (QueueClientGetResponse, error)
- func (client *QueueClient) List(resourceGroupName string, accountName string, options *QueueClientListOptions) *QueueClientListPager
- func (client *QueueClient) Update(ctx context.Context, resourceGroupName string, accountName string, ...) (QueueClientUpdateResponse, error)
- type QueueClientCreateOptions
- type QueueClientCreateResponse
- type QueueClientCreateResult
- type QueueClientDeleteOptions
- type QueueClientDeleteResponse
- type QueueClientGetOptions
- type QueueClientGetResponse
- type QueueClientGetResult
- type QueueClientListOptions
- type QueueClientListPager
- type QueueClientListResponse
- type QueueClientListResult
- type QueueClientUpdateOptions
- type QueueClientUpdateResponse
- type QueueClientUpdateResult
- type QueueProperties
- type QueueServiceProperties
- type QueueServicePropertiesProperties
- type QueueServicesClient
- func (client *QueueServicesClient) GetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, ...) (QueueServicesClientGetServicePropertiesResponse, error)
- func (client *QueueServicesClient) List(ctx context.Context, resourceGroupName string, accountName string, ...) (QueueServicesClientListResponse, error)
- func (client *QueueServicesClient) SetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, ...) (QueueServicesClientSetServicePropertiesResponse, error)
- type QueueServicesClientGetServicePropertiesOptions
- type QueueServicesClientGetServicePropertiesResponse
- type QueueServicesClientGetServicePropertiesResult
- type QueueServicesClientListOptions
- type QueueServicesClientListResponse
- type QueueServicesClientListResult
- type QueueServicesClientSetServicePropertiesOptions
- type QueueServicesClientSetServicePropertiesResponse
- type QueueServicesClientSetServicePropertiesResult
- type Reason
- type ReasonCode
- type Resource
- type ResourceAccessRule
- type RestorePolicyProperties
- type Restriction
- type RootSquashType
- type RoutingChoice
- type RoutingPreference
- type RuleType
- type SKU
- type SKUCapability
- type SKUInformation
- type SKUListResult
- type SKUName
- type SKUTier
- type SKUsClient
- type SKUsClientListOptions
- type SKUsClientListResponse
- type SKUsClientListResult
- type SSHPublicKey
- type SasPolicy
- type Schedule
- type ServiceSasParameters
- type ServiceSpecification
- type Services
- type ShareAccessTier
- type SignedIdentifier
- type SignedResource
- type SignedResourceTypes
- type SmbSetting
- type State
- type StorageAccountExpand
- type SystemData
- type Table
- type TableClient
- func (client *TableClient) Create(ctx context.Context, resourceGroupName string, accountName string, ...) (TableClientCreateResponse, error)
- func (client *TableClient) Delete(ctx context.Context, resourceGroupName string, accountName string, ...) (TableClientDeleteResponse, error)
- func (client *TableClient) Get(ctx context.Context, resourceGroupName string, accountName string, ...) (TableClientGetResponse, error)
- func (client *TableClient) List(resourceGroupName string, accountName string, options *TableClientListOptions) *TableClientListPager
- func (client *TableClient) Update(ctx context.Context, resourceGroupName string, accountName string, ...) (TableClientUpdateResponse, error)
- type TableClientCreateOptions
- type TableClientCreateResponse
- type TableClientCreateResult
- type TableClientDeleteOptions
- type TableClientDeleteResponse
- type TableClientGetOptions
- type TableClientGetResponse
- type TableClientGetResult
- type TableClientListOptions
- type TableClientListPager
- type TableClientListResponse
- type TableClientListResult
- type TableClientUpdateOptions
- type TableClientUpdateResponse
- type TableClientUpdateResult
- type TableProperties
- type TableServiceProperties
- type TableServicePropertiesProperties
- type TableServicesClient
- func (client *TableServicesClient) GetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, ...) (TableServicesClientGetServicePropertiesResponse, error)
- func (client *TableServicesClient) List(ctx context.Context, resourceGroupName string, accountName string, ...) (TableServicesClientListResponse, error)
- func (client *TableServicesClient) SetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, ...) (TableServicesClientSetServicePropertiesResponse, error)
- type TableServicesClientGetServicePropertiesOptions
- type TableServicesClientGetServicePropertiesResponse
- type TableServicesClientGetServicePropertiesResult
- type TableServicesClientListOptions
- type TableServicesClientListResponse
- type TableServicesClientListResult
- type TableServicesClientSetServicePropertiesOptions
- type TableServicesClientSetServicePropertiesResponse
- type TableServicesClientSetServicePropertiesResult
- type TagFilter
- type TagProperty
- type TrackedResource
- type UpdateHistoryProperty
- type Usage
- type UsageListResult
- type UsageName
- type UsageUnit
- type UsagesClient
- type UsagesClientListByLocationOptions
- type UsagesClientListByLocationResponse
- type UsagesClientListByLocationResult
- type UserAssignedIdentity
- type VirtualNetworkRule
Examples ¶
- AccountsClient.BeginAbortHierarchicalNamespaceMigration
- AccountsClient.BeginCreate
- AccountsClient.BeginFailover
- AccountsClient.BeginHierarchicalNamespaceMigration
- AccountsClient.BeginRestoreBlobRanges
- AccountsClient.CheckNameAvailability
- AccountsClient.Delete
- AccountsClient.GetProperties
- AccountsClient.List
- AccountsClient.ListAccountSAS
- AccountsClient.ListByResourceGroup
- AccountsClient.ListKeys
- AccountsClient.ListServiceSAS
- AccountsClient.RegenerateKey
- AccountsClient.RevokeUserDelegationKeys
- AccountsClient.Update
- BlobContainersClient.BeginObjectLevelWorm
- BlobContainersClient.ClearLegalHold
- BlobContainersClient.Create
- BlobContainersClient.CreateOrUpdateImmutabilityPolicy
- BlobContainersClient.Delete
- BlobContainersClient.DeleteImmutabilityPolicy
- BlobContainersClient.ExtendImmutabilityPolicy
- BlobContainersClient.Get
- BlobContainersClient.GetImmutabilityPolicy
- BlobContainersClient.Lease
- BlobContainersClient.List
- BlobContainersClient.LockImmutabilityPolicy
- BlobContainersClient.SetLegalHold
- BlobContainersClient.Update
- BlobInventoryPoliciesClient.CreateOrUpdate
- BlobInventoryPoliciesClient.Delete
- BlobInventoryPoliciesClient.Get
- BlobInventoryPoliciesClient.List
- BlobServicesClient.GetServiceProperties
- BlobServicesClient.List
- BlobServicesClient.SetServiceProperties
- DeletedAccountsClient.Get
- DeletedAccountsClient.List
- EncryptionScopesClient.Get
- EncryptionScopesClient.List
- EncryptionScopesClient.Patch
- EncryptionScopesClient.Put
- FileServicesClient.GetServiceProperties
- FileServicesClient.List
- FileServicesClient.SetServiceProperties
- FileSharesClient.Create
- FileSharesClient.Delete
- FileSharesClient.Get
- FileSharesClient.Lease
- FileSharesClient.List
- FileSharesClient.Restore
- FileSharesClient.Update
- LocalUsersClient.CreateOrUpdate
- LocalUsersClient.Delete
- LocalUsersClient.Get
- LocalUsersClient.List
- LocalUsersClient.ListKeys
- LocalUsersClient.RegeneratePassword
- ManagementPoliciesClient.CreateOrUpdate
- ManagementPoliciesClient.Delete
- ManagementPoliciesClient.Get
- ObjectReplicationPoliciesClient.CreateOrUpdate
- ObjectReplicationPoliciesClient.Delete
- ObjectReplicationPoliciesClient.Get
- ObjectReplicationPoliciesClient.List
- OperationsClient.List
- PrivateEndpointConnectionsClient.Delete
- PrivateEndpointConnectionsClient.Get
- PrivateEndpointConnectionsClient.List
- PrivateEndpointConnectionsClient.Put
- PrivateLinkResourcesClient.ListByStorageAccount
- QueueClient.Create
- QueueClient.Delete
- QueueClient.Get
- QueueClient.List
- QueueClient.Update
- QueueServicesClient.GetServiceProperties
- QueueServicesClient.List
- QueueServicesClient.SetServiceProperties
- SKUsClient.List
- TableClient.Create
- TableClient.Delete
- TableClient.Get
- TableClient.List
- TableClient.Update
- TableServicesClient.GetServiceProperties
- TableServicesClient.List
- TableServicesClient.SetServiceProperties
- UsagesClient.ListByLocation
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccessPolicy ¶
type AccessPolicy struct { // Expiry time of the access policy ExpiryTime *time.Time `json:"expiryTime,omitempty"` // List of abbreviated permissions. Permission *string `json:"permission,omitempty"` // Start time of the access policy StartTime *time.Time `json:"startTime,omitempty"` }
func (AccessPolicy) MarshalJSON ¶
func (a AccessPolicy) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccessPolicy.
func (*AccessPolicy) UnmarshalJSON ¶
func (a *AccessPolicy) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AccessPolicy.
type AccessTier ¶
type AccessTier string
AccessTier - Required for storage accounts where kind = BlobStorage. The access tier used for billing.
const ( AccessTierHot AccessTier = "Hot" AccessTierCool AccessTier = "Cool" )
func PossibleAccessTierValues ¶
func PossibleAccessTierValues() []AccessTier
PossibleAccessTierValues returns the possible values for the AccessTier const type.
func (AccessTier) ToPtr ¶
func (c AccessTier) ToPtr() *AccessTier
ToPtr returns a *AccessTier pointing to the current value.
type Account ¶ added in v0.3.0
type Account struct { // REQUIRED; The geo-location where the resource lives Location *string `json:"location,omitempty"` // The extendedLocation of the resource. ExtendedLocation *ExtendedLocation `json:"extendedLocation,omitempty"` // The identity of the resource. Identity *Identity `json:"identity,omitempty"` // Properties of the storage account. Properties *AccountProperties `json:"properties,omitempty"` // Resource tags. Tags map[string]*string `json:"tags,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; Gets the Kind. Kind *Kind `json:"kind,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; Gets the SKU. SKU *SKU `json:"sku,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
Account - The storage account.
func (Account) MarshalJSON ¶ added in v0.3.0
MarshalJSON implements the json.Marshaller interface for type Account.
type AccountCheckNameAvailabilityParameters ¶ added in v0.3.0
type AccountCheckNameAvailabilityParameters struct { // REQUIRED; The storage account name. Name *string `json:"name,omitempty"` // REQUIRED; The type of resource, Microsoft.Storage/storageAccounts Type *string `json:"type,omitempty"` }
AccountCheckNameAvailabilityParameters - The parameters used to check the availability of the storage account name.
type AccountCreateParameters ¶ added in v0.3.0
type AccountCreateParameters struct { // REQUIRED; Required. Indicates the type of storage account. Kind *Kind `json:"kind,omitempty"` // REQUIRED; Required. Gets or sets the location of the resource. This will be one of the supported and registered Azure Geo // Regions (e.g. West US, East US, Southeast Asia, etc.). The geo region of a resource // cannot be changed once it is created, but if an identical geo region is specified on update, the request will succeed. Location *string `json:"location,omitempty"` // REQUIRED; Required. Gets or sets the SKU name. SKU *SKU `json:"sku,omitempty"` // Optional. Set the extended location of the resource. If not set, the storage account will be created in Azure main region. // Otherwise it will be created in the specified extended location ExtendedLocation *ExtendedLocation `json:"extendedLocation,omitempty"` // The identity of the resource. Identity *Identity `json:"identity,omitempty"` // The parameters used to create the storage account. Properties *AccountPropertiesCreateParameters `json:"properties,omitempty"` // Gets or sets a list of key value pairs that describe the resource. These tags can be used for viewing and grouping this // resource (across resource groups). A maximum of 15 tags can be provided for a // resource. Each tag must have a key with a length no greater than 128 characters and a value with a length no greater than // 256 characters. Tags map[string]*string `json:"tags,omitempty"` }
AccountCreateParameters - The parameters used when creating a storage account.
func (AccountCreateParameters) MarshalJSON ¶ added in v0.3.0
func (a AccountCreateParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccountCreateParameters.
type AccountImmutabilityPolicyProperties ¶
type AccountImmutabilityPolicyProperties struct { // This property can only be changed for disabled and unlocked time-based retention policies. When enabled, new blocks can // be written to an append blob while maintaining immutability protection and // compliance. Only new blocks can be added and any existing blocks cannot be modified or deleted. AllowProtectedAppendWrites *bool `json:"allowProtectedAppendWrites,omitempty"` // The immutability period for the blobs in the container since the policy creation, in days. ImmutabilityPeriodSinceCreationInDays *int32 `json:"immutabilityPeriodSinceCreationInDays,omitempty"` // The ImmutabilityPolicy state defines the mode of the policy. Disabled state disables the policy, Unlocked state allows // increase and decrease of immutability retention time and also allows toggling // allowProtectedAppendWrites property, Locked state only allows the increase of the immutability retention time. A policy // can only be created in a Disabled or Unlocked state and can be toggled between // the two states. Only a policy in an Unlocked state can transition to a Locked state which cannot be reverted. State *AccountImmutabilityPolicyState `json:"state,omitempty"` }
AccountImmutabilityPolicyProperties - This defines account-level immutability policy properties.
type AccountImmutabilityPolicyState ¶
type AccountImmutabilityPolicyState string
AccountImmutabilityPolicyState - The ImmutabilityPolicy state defines the mode of the policy. Disabled state disables the policy, Unlocked state allows increase and decrease of immutability retention time and also allows toggling allowProtectedAppendWrites property, Locked state only allows the increase of the immutability retention time. A policy can only be created in a Disabled or Unlocked state and can be toggled between the two states. Only a policy in an Unlocked state can transition to a Locked state which cannot be reverted.
const ( AccountImmutabilityPolicyStateDisabled AccountImmutabilityPolicyState = "Disabled" AccountImmutabilityPolicyStateLocked AccountImmutabilityPolicyState = "Locked" AccountImmutabilityPolicyStateUnlocked AccountImmutabilityPolicyState = "Unlocked" )
func PossibleAccountImmutabilityPolicyStateValues ¶
func PossibleAccountImmutabilityPolicyStateValues() []AccountImmutabilityPolicyState
PossibleAccountImmutabilityPolicyStateValues returns the possible values for the AccountImmutabilityPolicyState const type.
func (AccountImmutabilityPolicyState) ToPtr ¶
func (c AccountImmutabilityPolicyState) ToPtr() *AccountImmutabilityPolicyState
ToPtr returns a *AccountImmutabilityPolicyState pointing to the current value.
type AccountInternetEndpoints ¶ added in v0.3.0
type AccountInternetEndpoints struct { // READ-ONLY; Gets the blob endpoint. Blob *string `json:"blob,omitempty" azure:"ro"` // READ-ONLY; Gets the dfs endpoint. Dfs *string `json:"dfs,omitempty" azure:"ro"` // READ-ONLY; Gets the file endpoint. File *string `json:"file,omitempty" azure:"ro"` // READ-ONLY; Gets the web endpoint. Web *string `json:"web,omitempty" azure:"ro"` }
AccountInternetEndpoints - The URIs that are used to perform a retrieval of a public blob, file, web or dfs object via a internet routing endpoint.
type AccountKey ¶ added in v0.3.0
type AccountKey struct { // READ-ONLY; Creation time of the key, in round trip date format. CreationTime *time.Time `json:"creationTime,omitempty" azure:"ro"` // READ-ONLY; Name of the key. KeyName *string `json:"keyName,omitempty" azure:"ro"` // READ-ONLY; Permissions for the key -- read-only or full permissions. Permissions *KeyPermission `json:"permissions,omitempty" azure:"ro"` // READ-ONLY; Base 64-encoded value of the key. Value *string `json:"value,omitempty" azure:"ro"` }
AccountKey - An access key for the storage account.
func (AccountKey) MarshalJSON ¶ added in v0.3.0
func (a AccountKey) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccountKey.
func (*AccountKey) UnmarshalJSON ¶ added in v0.3.0
func (a *AccountKey) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AccountKey.
type AccountListKeysResult ¶ added in v0.3.0
type AccountListKeysResult struct { // READ-ONLY; Gets the list of storage account keys and their properties for the specified storage account. Keys []*AccountKey `json:"keys,omitempty" azure:"ro"` }
AccountListKeysResult - The response from the ListKeys operation.
func (AccountListKeysResult) MarshalJSON ¶ added in v0.3.0
func (a AccountListKeysResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccountListKeysResult.
type AccountListResult ¶ added in v0.3.0
type AccountListResult struct { // READ-ONLY; Request URL that can be used to query next page of storage accounts. Returned when total number of requested // storage accounts exceed maximum page size. NextLink *string `json:"nextLink,omitempty" azure:"ro"` // READ-ONLY; Gets the list of storage accounts and their properties. Value []*Account `json:"value,omitempty" azure:"ro"` }
AccountListResult - The response from the List Storage Accounts operation.
func (AccountListResult) MarshalJSON ¶ added in v0.3.0
func (a AccountListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccountListResult.
type AccountMicrosoftEndpoints ¶ added in v0.3.0
type AccountMicrosoftEndpoints struct { // READ-ONLY; Gets the blob endpoint. Blob *string `json:"blob,omitempty" azure:"ro"` // READ-ONLY; Gets the dfs endpoint. Dfs *string `json:"dfs,omitempty" azure:"ro"` // READ-ONLY; Gets the file endpoint. File *string `json:"file,omitempty" azure:"ro"` // READ-ONLY; Gets the queue endpoint. Queue *string `json:"queue,omitempty" azure:"ro"` // READ-ONLY; Gets the table endpoint. Table *string `json:"table,omitempty" azure:"ro"` // READ-ONLY; Gets the web endpoint. Web *string `json:"web,omitempty" azure:"ro"` }
AccountMicrosoftEndpoints - The URIs that are used to perform a retrieval of a public blob, queue, table, web or dfs object via a microsoft routing endpoint.
type AccountProperties ¶ added in v0.3.0
type AccountProperties struct { // Allow or disallow public access to all blobs or containers in the storage account. The default interpretation is true for // this property. AllowBlobPublicAccess *bool `json:"allowBlobPublicAccess,omitempty"` // Allow or disallow cross AAD tenant object replication. The default interpretation is true for this property. AllowCrossTenantReplication *bool `json:"allowCrossTenantReplication,omitempty"` // false, then all requests, including shared access signatures, must be authorized // with Azure Active Directory (Azure AD). The default value is null, which is equivalent to true. AllowSharedKeyAccess *bool `json:"allowSharedKeyAccess,omitempty"` // Restrict copy to and from Storage Accounts within an AAD tenant or with Private Links to the same VNet. AllowedCopyScope *AllowedCopyScope `json:"allowedCopyScope,omitempty"` // Provides the identity based authentication settings for Azure Files. AzureFilesIdentityBasedAuthentication *AzureFilesIdentityBasedAuthentication `json:"azureFilesIdentityBasedAuthentication,omitempty"` // A boolean flag which indicates whether the default authentication is OAuth or not. The default interpretation is false // for this property. DefaultToOAuthAuthentication *bool `json:"defaultToOAuthAuthentication,omitempty"` // Allows https traffic only to storage service if sets to true. EnableHTTPSTrafficOnly *bool `json:"supportsHttpsTrafficOnly,omitempty"` // NFS 3.0 protocol support enabled if set to true. EnableNfsV3 *bool `json:"isNfsV3Enabled,omitempty"` // The property is immutable and can only be set to true at the account creation time. When set to true, it enables object // level immutability for all the containers in the account by default. ImmutableStorageWithVersioning *ImmutableStorageAccount `json:"immutableStorageWithVersioning,omitempty"` // Account HierarchicalNamespace enabled if sets to true. IsHnsEnabled *bool `json:"isHnsEnabled,omitempty"` // Enables local users feature, if set to true IsLocalUserEnabled *bool `json:"isLocalUserEnabled,omitempty"` // Enables Secure File Transfer Protocol, if set to true IsSftpEnabled *bool `json:"isSftpEnabled,omitempty"` LargeFileSharesState *LargeFileSharesState `json:"largeFileSharesState,omitempty"` // Set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property. MinimumTLSVersion *MinimumTLSVersion `json:"minimumTlsVersion,omitempty"` // Allow or disallow public network access to Storage Account. Value is optional but if passed in, must be 'Enabled' or 'Disabled'. PublicNetworkAccess *PublicNetworkAccess `json:"publicNetworkAccess,omitempty"` // Maintains information about the network routing choice opted by the user for data transfer RoutingPreference *RoutingPreference `json:"routingPreference,omitempty"` // READ-ONLY; Required for storage accounts where kind = BlobStorage. The access tier used for billing. AccessTier *AccessTier `json:"accessTier,omitempty" azure:"ro"` // READ-ONLY; Blob restore status BlobRestoreStatus *BlobRestoreStatus `json:"blobRestoreStatus,omitempty" azure:"ro"` // READ-ONLY; Gets the creation date and time of the storage account in UTC. CreationTime *time.Time `json:"creationTime,omitempty" azure:"ro"` // READ-ONLY; Gets the custom domain the user assigned to this storage account. CustomDomain *CustomDomain `json:"customDomain,omitempty" azure:"ro"` // READ-ONLY; Encryption settings to be used for server-side encryption for the storage account. Encryption *Encryption `json:"encryption,omitempty" azure:"ro"` // READ-ONLY; If the failover is in progress, the value will be true, otherwise, it will be null. FailoverInProgress *bool `json:"failoverInProgress,omitempty" azure:"ro"` // READ-ONLY; Geo Replication Stats GeoReplicationStats *GeoReplicationStats `json:"geoReplicationStats,omitempty" azure:"ro"` // READ-ONLY; Storage account keys creation time. KeyCreationTime *KeyCreationTime `json:"keyCreationTime,omitempty" azure:"ro"` // READ-ONLY; KeyPolicy assigned to the storage account. KeyPolicy *KeyPolicy `json:"keyPolicy,omitempty" azure:"ro"` // READ-ONLY; Gets the timestamp of the most recent instance of a failover to the secondary location. Only the most recent // timestamp is retained. This element is not returned if there has never been a failover // instance. Only available if the accountType is StandardGRS or StandardRAGRS. LastGeoFailoverTime *time.Time `json:"lastGeoFailoverTime,omitempty" azure:"ro"` // READ-ONLY; Network rule set NetworkRuleSet *NetworkRuleSet `json:"networkAcls,omitempty" azure:"ro"` // READ-ONLY; Gets the URLs that are used to perform a retrieval of a public blob, queue, or table object. Note that StandardZRS // and PremiumLRS accounts only return the blob endpoint. PrimaryEndpoints *Endpoints `json:"primaryEndpoints,omitempty" azure:"ro"` // READ-ONLY; Gets the location of the primary data center for the storage account. PrimaryLocation *string `json:"primaryLocation,omitempty" azure:"ro"` // READ-ONLY; List of private endpoint connection associated with the specified storage account PrivateEndpointConnections []*PrivateEndpointConnection `json:"privateEndpointConnections,omitempty" azure:"ro"` // READ-ONLY; Gets the status of the storage account at the time the operation was called. ProvisioningState *ProvisioningState `json:"provisioningState,omitempty" azure:"ro"` // READ-ONLY; SasPolicy assigned to the storage account. SasPolicy *SasPolicy `json:"sasPolicy,omitempty" azure:"ro"` // READ-ONLY; Gets the URLs that are used to perform a retrieval of a public blob, queue, or table object from the secondary // location of the storage account. Only available if the SKU name is Standard_RAGRS. SecondaryEndpoints *Endpoints `json:"secondaryEndpoints,omitempty" azure:"ro"` // READ-ONLY; Gets the location of the geo-replicated secondary for the storage account. Only available if the accountType // is StandardGRS or StandardRAGRS. SecondaryLocation *string `json:"secondaryLocation,omitempty" azure:"ro"` // READ-ONLY; Gets the status indicating whether the primary location of the storage account is available or unavailable. StatusOfPrimary *AccountStatus `json:"statusOfPrimary,omitempty" azure:"ro"` // READ-ONLY; Gets the status indicating whether the secondary location of the storage account is available or unavailable. // Only available if the SKU name is StandardGRS or StandardRAGRS. StatusOfSecondary *AccountStatus `json:"statusOfSecondary,omitempty" azure:"ro"` }
AccountProperties - Properties of the storage account.
func (AccountProperties) MarshalJSON ¶ added in v0.3.0
func (a AccountProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccountProperties.
func (*AccountProperties) UnmarshalJSON ¶ added in v0.3.0
func (a *AccountProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AccountProperties.
type AccountPropertiesCreateParameters ¶ added in v0.3.0
type AccountPropertiesCreateParameters struct { // Required for storage accounts where kind = BlobStorage. The access tier used for billing. AccessTier *AccessTier `json:"accessTier,omitempty"` // Allow or disallow public access to all blobs or containers in the storage account. The default interpretation is true for // this property. AllowBlobPublicAccess *bool `json:"allowBlobPublicAccess,omitempty"` // Allow or disallow cross AAD tenant object replication. The default interpretation is true for this property. AllowCrossTenantReplication *bool `json:"allowCrossTenantReplication,omitempty"` // false, then all requests, including shared access signatures, must be authorized // with Azure Active Directory (Azure AD). The default value is null, which is equivalent to true. AllowSharedKeyAccess *bool `json:"allowSharedKeyAccess,omitempty"` // Restrict copy to and from Storage Accounts within an AAD tenant or with Private Links to the same VNet. AllowedCopyScope *AllowedCopyScope `json:"allowedCopyScope,omitempty"` // Provides the identity based authentication settings for Azure Files. AzureFilesIdentityBasedAuthentication *AzureFilesIdentityBasedAuthentication `json:"azureFilesIdentityBasedAuthentication,omitempty"` // User domain assigned to the storage account. Name is the CNAME source. Only one custom domain is supported per storage // account at this time. To clear the existing custom domain, use an empty string // for the custom domain name property. CustomDomain *CustomDomain `json:"customDomain,omitempty"` // A boolean flag which indicates whether the default authentication is OAuth or not. The default interpretation is false // for this property. DefaultToOAuthAuthentication *bool `json:"defaultToOAuthAuthentication,omitempty"` // Allows https traffic only to storage service if sets to true. The default value is true since API version 2019-04-01. EnableHTTPSTrafficOnly *bool `json:"supportsHttpsTrafficOnly,omitempty"` // NFS 3.0 protocol support enabled if set to true. EnableNfsV3 *bool `json:"isNfsV3Enabled,omitempty"` // Encryption settings to be used for server-side encryption for the storage account. Encryption *Encryption `json:"encryption,omitempty"` // The property is immutable and can only be set to true at the account creation time. When set to true, it enables object // level immutability for all the new containers in the account by default. ImmutableStorageWithVersioning *ImmutableStorageAccount `json:"immutableStorageWithVersioning,omitempty"` // Account HierarchicalNamespace enabled if sets to true. IsHnsEnabled *bool `json:"isHnsEnabled,omitempty"` // Enables local users feature, if set to true IsLocalUserEnabled *bool `json:"isLocalUserEnabled,omitempty"` // Enables Secure File Transfer Protocol, if set to true IsSftpEnabled *bool `json:"isSftpEnabled,omitempty"` // KeyPolicy assigned to the storage account. KeyPolicy *KeyPolicy `json:"keyPolicy,omitempty"` LargeFileSharesState *LargeFileSharesState `json:"largeFileSharesState,omitempty"` // Set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property. MinimumTLSVersion *MinimumTLSVersion `json:"minimumTlsVersion,omitempty"` // Network rule set NetworkRuleSet *NetworkRuleSet `json:"networkAcls,omitempty"` // Allow or disallow public network access to Storage Account. Value is optional but if passed in, must be 'Enabled' or 'Disabled'. PublicNetworkAccess *PublicNetworkAccess `json:"publicNetworkAccess,omitempty"` // Maintains information about the network routing choice opted by the user for data transfer RoutingPreference *RoutingPreference `json:"routingPreference,omitempty"` // SasPolicy assigned to the storage account. SasPolicy *SasPolicy `json:"sasPolicy,omitempty"` }
AccountPropertiesCreateParameters - The parameters used to create the storage account.
type AccountPropertiesUpdateParameters ¶ added in v0.3.0
type AccountPropertiesUpdateParameters struct { // Required for storage accounts where kind = BlobStorage. The access tier used for billing. AccessTier *AccessTier `json:"accessTier,omitempty"` // Allow or disallow public access to all blobs or containers in the storage account. The default interpretation is true for // this property. AllowBlobPublicAccess *bool `json:"allowBlobPublicAccess,omitempty"` // Allow or disallow cross AAD tenant object replication. The default interpretation is true for this property. AllowCrossTenantReplication *bool `json:"allowCrossTenantReplication,omitempty"` // false, then all requests, including shared access signatures, must be authorized // with Azure Active Directory (Azure AD). The default value is null, which is equivalent to true. AllowSharedKeyAccess *bool `json:"allowSharedKeyAccess,omitempty"` // Restrict copy to and from Storage Accounts within an AAD tenant or with Private Links to the same VNet. AllowedCopyScope *AllowedCopyScope `json:"allowedCopyScope,omitempty"` // Provides the identity based authentication settings for Azure Files. AzureFilesIdentityBasedAuthentication *AzureFilesIdentityBasedAuthentication `json:"azureFilesIdentityBasedAuthentication,omitempty"` // Custom domain assigned to the storage account by the user. Name is the CNAME source. Only one custom domain is supported // per storage account at this time. To clear the existing custom domain, use an // empty string for the custom domain name property. CustomDomain *CustomDomain `json:"customDomain,omitempty"` // A boolean flag which indicates whether the default authentication is OAuth or not. The default interpretation is false // for this property. DefaultToOAuthAuthentication *bool `json:"defaultToOAuthAuthentication,omitempty"` // Allows https traffic only to storage service if sets to true. EnableHTTPSTrafficOnly *bool `json:"supportsHttpsTrafficOnly,omitempty"` // Not applicable. Azure Storage encryption at rest is enabled by default for all storage accounts and cannot be disabled. Encryption *Encryption `json:"encryption,omitempty"` // The property is immutable and can only be set to true at the account creation time. When set to true, it enables object // level immutability for all the containers in the account by default. ImmutableStorageWithVersioning *ImmutableStorageAccount `json:"immutableStorageWithVersioning,omitempty"` // Enables local users feature, if set to true IsLocalUserEnabled *bool `json:"isLocalUserEnabled,omitempty"` // Enables Secure File Transfer Protocol, if set to true IsSftpEnabled *bool `json:"isSftpEnabled,omitempty"` // KeyPolicy assigned to the storage account. KeyPolicy *KeyPolicy `json:"keyPolicy,omitempty"` LargeFileSharesState *LargeFileSharesState `json:"largeFileSharesState,omitempty"` // Set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property. MinimumTLSVersion *MinimumTLSVersion `json:"minimumTlsVersion,omitempty"` // Network rule set NetworkRuleSet *NetworkRuleSet `json:"networkAcls,omitempty"` // Allow or disallow public network access to Storage Account. Value is optional but if passed in, must be 'Enabled' or 'Disabled'. PublicNetworkAccess *PublicNetworkAccess `json:"publicNetworkAccess,omitempty"` // Maintains information about the network routing choice opted by the user for data transfer RoutingPreference *RoutingPreference `json:"routingPreference,omitempty"` // SasPolicy assigned to the storage account. SasPolicy *SasPolicy `json:"sasPolicy,omitempty"` }
AccountPropertiesUpdateParameters - The parameters used when updating a storage account.
type AccountRegenerateKeyParameters ¶ added in v0.3.0
type AccountRegenerateKeyParameters struct { // REQUIRED; The name of storage keys that want to be regenerated, possible values are key1, key2, kerb1, kerb2. KeyName *string `json:"keyName,omitempty"` }
AccountRegenerateKeyParameters - The parameters used to regenerate the storage account key.
type AccountSasParameters ¶
type AccountSasParameters struct { // REQUIRED; The signed permissions for the account SAS. Possible values include: Read (r), Write (w), Delete (d), List (l), // Add (a), Create (c), Update (u) and Process (p). Permissions *Permissions `json:"signedPermission,omitempty"` // REQUIRED; The signed resource types that are accessible with the account SAS. Service (s): Access to service-level APIs; // Container (c): Access to container-level APIs; Object (o): Access to object-level APIs // for blobs, queue messages, table entities, and files. ResourceTypes *SignedResourceTypes `json:"signedResourceTypes,omitempty"` // REQUIRED; The signed services accessible with the account SAS. Possible values include: Blob (b), Queue (q), Table (t), // File (f). Services *Services `json:"signedServices,omitempty"` SharedAccessExpiryTime *time.Time `json:"signedExpiry,omitempty"` // An IP address or a range of IP addresses from which to accept requests. IPAddressOrRange *string `json:"signedIp,omitempty"` // The key to sign the account SAS token with. KeyToSign *string `json:"keyToSign,omitempty"` // The protocol permitted for a request made with the account SAS. Protocols *HTTPProtocol `json:"signedProtocol,omitempty"` SharedAccessStartTime *time.Time `json:"signedStart,omitempty"` }
AccountSasParameters - The parameters to list SAS credentials of a storage account.
func (AccountSasParameters) MarshalJSON ¶
func (a AccountSasParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccountSasParameters.
func (*AccountSasParameters) UnmarshalJSON ¶
func (a *AccountSasParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AccountSasParameters.
type AccountStatus ¶
type AccountStatus string
AccountStatus - Gets the status indicating whether the primary location of the storage account is available or unavailable.
const ( AccountStatusAvailable AccountStatus = "available" )
func PossibleAccountStatusValues ¶
func PossibleAccountStatusValues() []AccountStatus
PossibleAccountStatusValues returns the possible values for the AccountStatus const type.
func (AccountStatus) ToPtr ¶
func (c AccountStatus) ToPtr() *AccountStatus
ToPtr returns a *AccountStatus pointing to the current value.
type AccountUpdateParameters ¶ added in v0.3.0
type AccountUpdateParameters struct { // The identity of the resource. Identity *Identity `json:"identity,omitempty"` // Optional. Indicates the type of storage account. Currently only StorageV2 value supported by server. Kind *Kind `json:"kind,omitempty"` // The parameters used when updating a storage account. Properties *AccountPropertiesUpdateParameters `json:"properties,omitempty"` // Gets or sets the SKU name. Note that the SKU name cannot be updated to StandardZRS, PremiumLRS or Premium_ZRS, nor can // accounts of those SKU names be updated to any other value. SKU *SKU `json:"sku,omitempty"` // Gets or sets a list of key value pairs that describe the resource. These tags can be used in viewing and grouping this // resource (across resource groups). A maximum of 15 tags can be provided for a // resource. Each tag must have a key no greater in length than 128 characters and a value no greater in length than 256 characters. Tags map[string]*string `json:"tags,omitempty"` }
AccountUpdateParameters - The parameters that can be provided when updating the storage account properties.
func (AccountUpdateParameters) MarshalJSON ¶ added in v0.3.0
func (a AccountUpdateParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccountUpdateParameters.
type AccountsClient ¶ added in v0.3.0
type AccountsClient struct {
// contains filtered or unexported fields
}
AccountsClient contains the methods for the StorageAccounts group. Don't use this type directly, use NewAccountsClient() instead.
func NewAccountsClient ¶ added in v0.3.0
func NewAccountsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *AccountsClient
NewAccountsClient creates a new instance of AccountsClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*AccountsClient) BeginAbortHierarchicalNamespaceMigration ¶ added in v0.3.0
func (client *AccountsClient) BeginAbortHierarchicalNamespaceMigration(ctx context.Context, resourceGroupName string, accountName string, options *AccountsClientBeginAbortHierarchicalNamespaceMigrationOptions) (AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse, error)
BeginAbortHierarchicalNamespaceMigration - Abort live Migration of storage account to enable Hns If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - AccountsClientBeginAbortHierarchicalNamespaceMigrationOptions contains the optional parameters for the AccountsClient.BeginAbortHierarchicalNamespaceMigration method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountAbortHierarchicalNamespaceMigration.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) poller, err := client.BeginAbortHierarchicalNamespaceMigration(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } _, err = poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } }
Output:
func (*AccountsClient) BeginCreate ¶ added in v0.3.0
func (client *AccountsClient) BeginCreate(ctx context.Context, resourceGroupName string, accountName string, parameters AccountCreateParameters, options *AccountsClientBeginCreateOptions) (AccountsClientCreatePollerResponse, error)
BeginCreate - Asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. parameters - The parameters to provide for the created account. options - AccountsClientBeginCreateOptions contains the optional parameters for the AccountsClient.BeginCreate method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/NfsV3AccountCreate.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) poller, err := client.BeginCreate(ctx, "<resource-group-name>", "<account-name>", armstorage.AccountCreateParameters{ Kind: armstorage.Kind("BlockBlobStorage").ToPtr(), Location: to.StringPtr("<location>"), Properties: &armstorage.AccountPropertiesCreateParameters{ IsHnsEnabled: to.BoolPtr(true), EnableNfsV3: to.BoolPtr(true), NetworkRuleSet: &armstorage.NetworkRuleSet{ Bypass: armstorage.Bypass("AzureServices").ToPtr(), DefaultAction: armstorage.DefaultActionAllow.ToPtr(), IPRules: []*armstorage.IPRule{}, VirtualNetworkRules: []*armstorage.VirtualNetworkRule{ { VirtualNetworkResourceID: to.StringPtr("<virtual-network-resource-id>"), }}, }, EnableHTTPSTrafficOnly: to.BoolPtr(false), }, SKU: &armstorage.SKU{ Name: armstorage.SKUName("Premium_LRS").ToPtr(), }, }, nil) if err != nil { log.Fatal(err) } res, err := poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.AccountsClientCreateResult) }
Output:
func (*AccountsClient) BeginFailover ¶ added in v0.3.0
func (client *AccountsClient) BeginFailover(ctx context.Context, resourceGroupName string, accountName string, options *AccountsClientBeginFailoverOptions) (AccountsClientFailoverPollerResponse, error)
BeginFailover - Failover request can be triggered for a storage account in case of availability issues. The failover occurs from the storage account's primary cluster to secondary cluster for RA-GRS accounts. The secondary cluster will become primary after failover. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - AccountsClientBeginFailoverOptions contains the optional parameters for the AccountsClient.BeginFailover method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountFailover.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) poller, err := client.BeginFailover(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } _, err = poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } }
Output:
func (*AccountsClient) BeginHierarchicalNamespaceMigration ¶ added in v0.3.0
func (client *AccountsClient) BeginHierarchicalNamespaceMigration(ctx context.Context, resourceGroupName string, accountName string, requestType string, options *AccountsClientBeginHierarchicalNamespaceMigrationOptions) (AccountsClientHierarchicalNamespaceMigrationPollerResponse, error)
BeginHierarchicalNamespaceMigration - Live Migration of storage account to enable Hns If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. requestType - Required. Hierarchical namespace migration type can either be a hierarchical namespace validation request 'HnsOnValidationRequest' or a hydration request 'HnsOnHydrationRequest'. The validation request will validate the migration whereas the hydration request will migrate the account. options - AccountsClientBeginHierarchicalNamespaceMigrationOptions contains the optional parameters for the AccountsClient.BeginHierarchicalNamespaceMigration method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountHierarchicalNamespaceMigration.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) poller, err := client.BeginHierarchicalNamespaceMigration(ctx, "<resource-group-name>", "<account-name>", "<request-type>", nil) if err != nil { log.Fatal(err) } _, err = poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } }
Output:
func (*AccountsClient) BeginRestoreBlobRanges ¶ added in v0.3.0
func (client *AccountsClient) BeginRestoreBlobRanges(ctx context.Context, resourceGroupName string, accountName string, parameters BlobRestoreParameters, options *AccountsClientBeginRestoreBlobRangesOptions) (AccountsClientRestoreBlobRangesPollerResponse, error)
BeginRestoreBlobRanges - Restore blobs in the specified blob ranges If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. parameters - The parameters to provide for restore blob ranges. options - AccountsClientBeginRestoreBlobRangesOptions contains the optional parameters for the AccountsClient.BeginRestoreBlobRanges method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobRangesRestore.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) poller, err := client.BeginRestoreBlobRanges(ctx, "<resource-group-name>", "<account-name>", armstorage.BlobRestoreParameters{ BlobRanges: []*armstorage.BlobRestoreRange{ { EndRange: to.StringPtr("<end-range>"), StartRange: to.StringPtr("<start-range>"), }, { EndRange: to.StringPtr("<end-range>"), StartRange: to.StringPtr("<start-range>"), }}, TimeToRestore: to.TimePtr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2019-04-20T15:30:00.0000000Z"); return t }()), }, nil) if err != nil { log.Fatal(err) } res, err := poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.AccountsClientRestoreBlobRangesResult) }
Output:
func (*AccountsClient) CheckNameAvailability ¶ added in v0.3.0
func (client *AccountsClient) CheckNameAvailability(ctx context.Context, accountName AccountCheckNameAvailabilityParameters, options *AccountsClientCheckNameAvailabilityOptions) (AccountsClientCheckNameAvailabilityResponse, error)
CheckNameAvailability - Checks that the storage account name is valid and is not already in use. If the operation fails it returns an *azcore.ResponseError type. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - AccountsClientCheckNameAvailabilityOptions contains the optional parameters for the AccountsClient.CheckNameAvailability method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountCheckNameAvailability.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) res, err := client.CheckNameAvailability(ctx, armstorage.AccountCheckNameAvailabilityParameters{ Name: to.StringPtr("<name>"), Type: to.StringPtr("<type>"), }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.AccountsClientCheckNameAvailabilityResult) }
Output:
func (*AccountsClient) Delete ¶ added in v0.3.0
func (client *AccountsClient) Delete(ctx context.Context, resourceGroupName string, accountName string, options *AccountsClientDeleteOptions) (AccountsClientDeleteResponse, error)
Delete - Deletes a storage account in Microsoft Azure. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - AccountsClientDeleteOptions contains the optional parameters for the AccountsClient.Delete method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountDelete.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) _, err = client.Delete(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*AccountsClient) GetProperties ¶ added in v0.3.0
func (client *AccountsClient) GetProperties(ctx context.Context, resourceGroupName string, accountName string, options *AccountsClientGetPropertiesOptions) (AccountsClientGetPropertiesResponse, error)
GetProperties - Returns the properties for the specified storage account including but not limited to name, SKU name, location, and account status. The ListKeys operation should be used to retrieve storage keys. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - AccountsClientGetPropertiesOptions contains the optional parameters for the AccountsClient.GetProperties method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountGetProperties.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) res, err := client.GetProperties(ctx, "<resource-group-name>", "<account-name>", &armstorage.AccountsClientGetPropertiesOptions{Expand: nil}) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.AccountsClientGetPropertiesResult) }
Output:
func (*AccountsClient) List ¶ added in v0.3.0
func (client *AccountsClient) List(options *AccountsClientListOptions) *AccountsClientListPager
List - Lists all the storage accounts available under the subscription. Note that storage keys are not returned; use the ListKeys operation for this. If the operation fails it returns an *azcore.ResponseError type. options - AccountsClientListOptions contains the optional parameters for the AccountsClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) pager := client.List(nil) for { nextResult := pager.NextPage(ctx) if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } if !nextResult { break } for _, v := range pager.PageResponse().Value { log.Printf("Pager result: %#v\n", v) } } }
Output:
func (*AccountsClient) ListAccountSAS ¶ added in v0.3.0
func (client *AccountsClient) ListAccountSAS(ctx context.Context, resourceGroupName string, accountName string, parameters AccountSasParameters, options *AccountsClientListAccountSASOptions) (AccountsClientListAccountSASResponse, error)
ListAccountSAS - List SAS credentials of a storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. parameters - The parameters to provide to list SAS credentials for the storage account. options - AccountsClientListAccountSASOptions contains the optional parameters for the AccountsClient.ListAccountSAS method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountListAccountSAS.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) res, err := client.ListAccountSAS(ctx, "<resource-group-name>", "<account-name>", armstorage.AccountSasParameters{ KeyToSign: to.StringPtr("<key-to-sign>"), SharedAccessExpiryTime: to.TimePtr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-05-24T11:42:03.1567373Z"); return t }()), Permissions: armstorage.Permissions("r").ToPtr(), Protocols: armstorage.HTTPProtocolHTTPSHTTP.ToPtr(), ResourceTypes: armstorage.SignedResourceTypes("s").ToPtr(), Services: armstorage.Services("b").ToPtr(), SharedAccessStartTime: to.TimePtr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-05-24T10:42:03.1567373Z"); return t }()), }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.AccountsClientListAccountSASResult) }
Output:
func (*AccountsClient) ListByResourceGroup ¶ added in v0.3.0
func (client *AccountsClient) ListByResourceGroup(resourceGroupName string, options *AccountsClientListByResourceGroupOptions) *AccountsClientListByResourceGroupPager
ListByResourceGroup - Lists all the storage accounts available under the given resource group. Note that storage keys are not returned; use the ListKeys operation for this. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. options - AccountsClientListByResourceGroupOptions contains the optional parameters for the AccountsClient.ListByResourceGroup method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountListByResourceGroup.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) pager := client.ListByResourceGroup("<resource-group-name>", nil) for { nextResult := pager.NextPage(ctx) if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } if !nextResult { break } for _, v := range pager.PageResponse().Value { log.Printf("Pager result: %#v\n", v) } } }
Output:
func (*AccountsClient) ListKeys ¶ added in v0.3.0
func (client *AccountsClient) ListKeys(ctx context.Context, resourceGroupName string, accountName string, options *AccountsClientListKeysOptions) (AccountsClientListKeysResponse, error)
ListKeys - Lists the access keys or Kerberos keys (if active directory enabled) for the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - AccountsClientListKeysOptions contains the optional parameters for the AccountsClient.ListKeys method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountListKeys.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) res, err := client.ListKeys(ctx, "<resource-group-name>", "<account-name>", &armstorage.AccountsClientListKeysOptions{Expand: nil}) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.AccountsClientListKeysResult) }
Output:
func (*AccountsClient) ListServiceSAS ¶ added in v0.3.0
func (client *AccountsClient) ListServiceSAS(ctx context.Context, resourceGroupName string, accountName string, parameters ServiceSasParameters, options *AccountsClientListServiceSASOptions) (AccountsClientListServiceSASResponse, error)
ListServiceSAS - List service SAS credentials of a specific resource. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. parameters - The parameters to provide to list service SAS credentials. options - AccountsClientListServiceSASOptions contains the optional parameters for the AccountsClient.ListServiceSAS method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountListServiceSAS.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) res, err := client.ListServiceSAS(ctx, "<resource-group-name>", "<account-name>", armstorage.ServiceSasParameters{ CanonicalizedResource: to.StringPtr("<canonicalized-resource>"), SharedAccessExpiryTime: to.TimePtr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-05-24T11:32:48.8457197Z"); return t }()), Permissions: armstorage.Permissions("l").ToPtr(), Resource: armstorage.SignedResource("c").ToPtr(), }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.AccountsClientListServiceSASResult) }
Output:
func (*AccountsClient) RegenerateKey ¶ added in v0.3.0
func (client *AccountsClient) RegenerateKey(ctx context.Context, resourceGroupName string, accountName string, regenerateKey AccountRegenerateKeyParameters, options *AccountsClientRegenerateKeyOptions) (AccountsClientRegenerateKeyResponse, error)
RegenerateKey - Regenerates one of the access keys or Kerberos keys for the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. regenerateKey - Specifies name of the key which should be regenerated -- key1, key2, kerb1, kerb2. options - AccountsClientRegenerateKeyOptions contains the optional parameters for the AccountsClient.RegenerateKey method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountRegenerateKerbKey.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) res, err := client.RegenerateKey(ctx, "<resource-group-name>", "<account-name>", armstorage.AccountRegenerateKeyParameters{ KeyName: to.StringPtr("<key-name>"), }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.AccountsClientRegenerateKeyResult) }
Output:
func (*AccountsClient) RevokeUserDelegationKeys ¶ added in v0.3.0
func (client *AccountsClient) RevokeUserDelegationKeys(ctx context.Context, resourceGroupName string, accountName string, options *AccountsClientRevokeUserDelegationKeysOptions) (AccountsClientRevokeUserDelegationKeysResponse, error)
RevokeUserDelegationKeys - Revoke user delegation keys. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - AccountsClientRevokeUserDelegationKeysOptions contains the optional parameters for the AccountsClient.RevokeUserDelegationKeys method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountRevokeUserDelegationKeys.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) _, err = client.RevokeUserDelegationKeys(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*AccountsClient) Update ¶ added in v0.3.0
func (client *AccountsClient) Update(ctx context.Context, resourceGroupName string, accountName string, parameters AccountUpdateParameters, options *AccountsClientUpdateOptions) (AccountsClientUpdateResponse, error)
Update - The update operation can be used to update the SKU, encryption, access tier, or tags for a storage account. It can also be used to map the account to a custom domain. Only one custom domain is supported per storage account; the replacement/change of custom domain is not supported. In order to replace an old custom domain, the old value must be cleared/unregistered before a new value can be set. The update of multiple properties is supported. This call does not change the storage keys for the account. If you want to change the storage account keys, use the regenerate keys operation. The location and name of the storage account cannot be changed after creation. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. parameters - The parameters to provide for the updated account. options - AccountsClientUpdateOptions contains the optional parameters for the AccountsClient.Update method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountEnableAD.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewAccountsClient("<subscription-id>", cred, nil) res, err := client.Update(ctx, "<resource-group-name>", "<account-name>", armstorage.AccountUpdateParameters{ Properties: &armstorage.AccountPropertiesUpdateParameters{ AzureFilesIdentityBasedAuthentication: &armstorage.AzureFilesIdentityBasedAuthentication{ ActiveDirectoryProperties: &armstorage.ActiveDirectoryProperties{ AccountType: armstorage.ActiveDirectoryPropertiesAccountType("User").ToPtr(), AzureStorageSid: to.StringPtr("<azure-storage-sid>"), DomainGUID: to.StringPtr("<domain-guid>"), DomainName: to.StringPtr("<domain-name>"), DomainSid: to.StringPtr("<domain-sid>"), ForestName: to.StringPtr("<forest-name>"), NetBiosDomainName: to.StringPtr("<net-bios-domain-name>"), SamAccountName: to.StringPtr("<sam-account-name>"), }, DirectoryServiceOptions: armstorage.DirectoryServiceOptions("AD").ToPtr(), }, }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.AccountsClientUpdateResult) }
Output:
type AccountsClientAbortHierarchicalNamespaceMigrationPoller ¶ added in v0.3.0
type AccountsClientAbortHierarchicalNamespaceMigrationPoller struct {
// contains filtered or unexported fields
}
AccountsClientAbortHierarchicalNamespaceMigrationPoller provides polling facilities until the operation reaches a terminal state.
func (*AccountsClientAbortHierarchicalNamespaceMigrationPoller) Done ¶ added in v0.3.0
func (p *AccountsClientAbortHierarchicalNamespaceMigrationPoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*AccountsClientAbortHierarchicalNamespaceMigrationPoller) FinalResponse ¶ added in v0.3.0
func (p *AccountsClientAbortHierarchicalNamespaceMigrationPoller) FinalResponse(ctx context.Context) (AccountsClientAbortHierarchicalNamespaceMigrationResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final AccountsClientAbortHierarchicalNamespaceMigrationResponse will be returned.
func (*AccountsClientAbortHierarchicalNamespaceMigrationPoller) Poll ¶ added in v0.3.0
func (p *AccountsClientAbortHierarchicalNamespaceMigrationPoller) Poll(ctx context.Context) (*http.Response, error)
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*AccountsClientAbortHierarchicalNamespaceMigrationPoller) ResumeToken ¶ added in v0.3.0
func (p *AccountsClientAbortHierarchicalNamespaceMigrationPoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse ¶ added in v0.3.0
type AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse struct { // Poller contains an initialized poller. Poller *AccountsClientAbortHierarchicalNamespaceMigrationPoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse contains the response from method AccountsClient.AbortHierarchicalNamespaceMigration.
func (AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse) PollUntilDone ¶ added in v0.3.0
func (l AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (AccountsClientAbortHierarchicalNamespaceMigrationResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse) Resume ¶ added in v0.3.0
func (l *AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse) Resume(ctx context.Context, client *AccountsClient, token string) error
Resume rehydrates a AccountsClientAbortHierarchicalNamespaceMigrationPollerResponse from the provided client and resume token.
type AccountsClientAbortHierarchicalNamespaceMigrationResponse ¶ added in v0.3.0
type AccountsClientAbortHierarchicalNamespaceMigrationResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientAbortHierarchicalNamespaceMigrationResponse contains the response from method AccountsClient.AbortHierarchicalNamespaceMigration.
type AccountsClientBeginAbortHierarchicalNamespaceMigrationOptions ¶ added in v0.3.0
type AccountsClientBeginAbortHierarchicalNamespaceMigrationOptions struct { }
AccountsClientBeginAbortHierarchicalNamespaceMigrationOptions contains the optional parameters for the AccountsClient.BeginAbortHierarchicalNamespaceMigration method.
type AccountsClientBeginCreateOptions ¶ added in v0.3.0
type AccountsClientBeginCreateOptions struct { }
AccountsClientBeginCreateOptions contains the optional parameters for the AccountsClient.BeginCreate method.
type AccountsClientBeginFailoverOptions ¶ added in v0.3.0
type AccountsClientBeginFailoverOptions struct { }
AccountsClientBeginFailoverOptions contains the optional parameters for the AccountsClient.BeginFailover method.
type AccountsClientBeginHierarchicalNamespaceMigrationOptions ¶ added in v0.3.0
type AccountsClientBeginHierarchicalNamespaceMigrationOptions struct { }
AccountsClientBeginHierarchicalNamespaceMigrationOptions contains the optional parameters for the AccountsClient.BeginHierarchicalNamespaceMigration method.
type AccountsClientBeginRestoreBlobRangesOptions ¶ added in v0.3.0
type AccountsClientBeginRestoreBlobRangesOptions struct { }
AccountsClientBeginRestoreBlobRangesOptions contains the optional parameters for the AccountsClient.BeginRestoreBlobRanges method.
type AccountsClientCheckNameAvailabilityOptions ¶ added in v0.3.0
type AccountsClientCheckNameAvailabilityOptions struct { }
AccountsClientCheckNameAvailabilityOptions contains the optional parameters for the AccountsClient.CheckNameAvailability method.
type AccountsClientCheckNameAvailabilityResponse ¶ added in v0.3.0
type AccountsClientCheckNameAvailabilityResponse struct { AccountsClientCheckNameAvailabilityResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientCheckNameAvailabilityResponse contains the response from method AccountsClient.CheckNameAvailability.
type AccountsClientCheckNameAvailabilityResult ¶ added in v0.3.0
type AccountsClientCheckNameAvailabilityResult struct {
CheckNameAvailabilityResult
}
AccountsClientCheckNameAvailabilityResult contains the result from method AccountsClient.CheckNameAvailability.
type AccountsClientCreatePoller ¶ added in v0.3.0
type AccountsClientCreatePoller struct {
// contains filtered or unexported fields
}
AccountsClientCreatePoller provides polling facilities until the operation reaches a terminal state.
func (*AccountsClientCreatePoller) Done ¶ added in v0.3.0
func (p *AccountsClientCreatePoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*AccountsClientCreatePoller) FinalResponse ¶ added in v0.3.0
func (p *AccountsClientCreatePoller) FinalResponse(ctx context.Context) (AccountsClientCreateResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final AccountsClientCreateResponse will be returned.
func (*AccountsClientCreatePoller) Poll ¶ added in v0.3.0
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*AccountsClientCreatePoller) ResumeToken ¶ added in v0.3.0
func (p *AccountsClientCreatePoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type AccountsClientCreatePollerResponse ¶ added in v0.3.0
type AccountsClientCreatePollerResponse struct { // Poller contains an initialized poller. Poller *AccountsClientCreatePoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientCreatePollerResponse contains the response from method AccountsClient.Create.
func (AccountsClientCreatePollerResponse) PollUntilDone ¶ added in v0.3.0
func (l AccountsClientCreatePollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (AccountsClientCreateResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*AccountsClientCreatePollerResponse) Resume ¶ added in v0.3.0
func (l *AccountsClientCreatePollerResponse) Resume(ctx context.Context, client *AccountsClient, token string) error
Resume rehydrates a AccountsClientCreatePollerResponse from the provided client and resume token.
type AccountsClientCreateResponse ¶ added in v0.3.0
type AccountsClientCreateResponse struct { AccountsClientCreateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientCreateResponse contains the response from method AccountsClient.Create.
type AccountsClientCreateResult ¶ added in v0.3.0
type AccountsClientCreateResult struct {
Account
}
AccountsClientCreateResult contains the result from method AccountsClient.Create.
type AccountsClientDeleteOptions ¶ added in v0.3.0
type AccountsClientDeleteOptions struct { }
AccountsClientDeleteOptions contains the optional parameters for the AccountsClient.Delete method.
type AccountsClientDeleteResponse ¶ added in v0.3.0
type AccountsClientDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientDeleteResponse contains the response from method AccountsClient.Delete.
type AccountsClientFailoverPoller ¶ added in v0.3.0
type AccountsClientFailoverPoller struct {
// contains filtered or unexported fields
}
AccountsClientFailoverPoller provides polling facilities until the operation reaches a terminal state.
func (*AccountsClientFailoverPoller) Done ¶ added in v0.3.0
func (p *AccountsClientFailoverPoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*AccountsClientFailoverPoller) FinalResponse ¶ added in v0.3.0
func (p *AccountsClientFailoverPoller) FinalResponse(ctx context.Context) (AccountsClientFailoverResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final AccountsClientFailoverResponse will be returned.
func (*AccountsClientFailoverPoller) Poll ¶ added in v0.3.0
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*AccountsClientFailoverPoller) ResumeToken ¶ added in v0.3.0
func (p *AccountsClientFailoverPoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type AccountsClientFailoverPollerResponse ¶ added in v0.3.0
type AccountsClientFailoverPollerResponse struct { // Poller contains an initialized poller. Poller *AccountsClientFailoverPoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientFailoverPollerResponse contains the response from method AccountsClient.Failover.
func (AccountsClientFailoverPollerResponse) PollUntilDone ¶ added in v0.3.0
func (l AccountsClientFailoverPollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (AccountsClientFailoverResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*AccountsClientFailoverPollerResponse) Resume ¶ added in v0.3.0
func (l *AccountsClientFailoverPollerResponse) Resume(ctx context.Context, client *AccountsClient, token string) error
Resume rehydrates a AccountsClientFailoverPollerResponse from the provided client and resume token.
type AccountsClientFailoverResponse ¶ added in v0.3.0
type AccountsClientFailoverResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientFailoverResponse contains the response from method AccountsClient.Failover.
type AccountsClientGetPropertiesOptions ¶ added in v0.3.0
type AccountsClientGetPropertiesOptions struct { // May be used to expand the properties within account's properties. By default, data is not included when fetching properties. // Currently we only support geoReplicationStats and blobRestoreStatus. Expand *StorageAccountExpand }
AccountsClientGetPropertiesOptions contains the optional parameters for the AccountsClient.GetProperties method.
type AccountsClientGetPropertiesResponse ¶ added in v0.3.0
type AccountsClientGetPropertiesResponse struct { AccountsClientGetPropertiesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientGetPropertiesResponse contains the response from method AccountsClient.GetProperties.
type AccountsClientGetPropertiesResult ¶ added in v0.3.0
type AccountsClientGetPropertiesResult struct {
Account
}
AccountsClientGetPropertiesResult contains the result from method AccountsClient.GetProperties.
type AccountsClientHierarchicalNamespaceMigrationPoller ¶ added in v0.3.0
type AccountsClientHierarchicalNamespaceMigrationPoller struct {
// contains filtered or unexported fields
}
AccountsClientHierarchicalNamespaceMigrationPoller provides polling facilities until the operation reaches a terminal state.
func (*AccountsClientHierarchicalNamespaceMigrationPoller) Done ¶ added in v0.3.0
func (p *AccountsClientHierarchicalNamespaceMigrationPoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*AccountsClientHierarchicalNamespaceMigrationPoller) FinalResponse ¶ added in v0.3.0
func (p *AccountsClientHierarchicalNamespaceMigrationPoller) FinalResponse(ctx context.Context) (AccountsClientHierarchicalNamespaceMigrationResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final AccountsClientHierarchicalNamespaceMigrationResponse will be returned.
func (*AccountsClientHierarchicalNamespaceMigrationPoller) Poll ¶ added in v0.3.0
func (p *AccountsClientHierarchicalNamespaceMigrationPoller) Poll(ctx context.Context) (*http.Response, error)
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*AccountsClientHierarchicalNamespaceMigrationPoller) ResumeToken ¶ added in v0.3.0
func (p *AccountsClientHierarchicalNamespaceMigrationPoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type AccountsClientHierarchicalNamespaceMigrationPollerResponse ¶ added in v0.3.0
type AccountsClientHierarchicalNamespaceMigrationPollerResponse struct { // Poller contains an initialized poller. Poller *AccountsClientHierarchicalNamespaceMigrationPoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientHierarchicalNamespaceMigrationPollerResponse contains the response from method AccountsClient.HierarchicalNamespaceMigration.
func (AccountsClientHierarchicalNamespaceMigrationPollerResponse) PollUntilDone ¶ added in v0.3.0
func (l AccountsClientHierarchicalNamespaceMigrationPollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (AccountsClientHierarchicalNamespaceMigrationResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*AccountsClientHierarchicalNamespaceMigrationPollerResponse) Resume ¶ added in v0.3.0
func (l *AccountsClientHierarchicalNamespaceMigrationPollerResponse) Resume(ctx context.Context, client *AccountsClient, token string) error
Resume rehydrates a AccountsClientHierarchicalNamespaceMigrationPollerResponse from the provided client and resume token.
type AccountsClientHierarchicalNamespaceMigrationResponse ¶ added in v0.3.0
type AccountsClientHierarchicalNamespaceMigrationResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientHierarchicalNamespaceMigrationResponse contains the response from method AccountsClient.HierarchicalNamespaceMigration.
type AccountsClientListAccountSASOptions ¶ added in v0.3.0
type AccountsClientListAccountSASOptions struct { }
AccountsClientListAccountSASOptions contains the optional parameters for the AccountsClient.ListAccountSAS method.
type AccountsClientListAccountSASResponse ¶ added in v0.3.0
type AccountsClientListAccountSASResponse struct { AccountsClientListAccountSASResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientListAccountSASResponse contains the response from method AccountsClient.ListAccountSAS.
type AccountsClientListAccountSASResult ¶ added in v0.3.0
type AccountsClientListAccountSASResult struct {
ListAccountSasResponse
}
AccountsClientListAccountSASResult contains the result from method AccountsClient.ListAccountSAS.
type AccountsClientListByResourceGroupOptions ¶ added in v0.3.0
type AccountsClientListByResourceGroupOptions struct { }
AccountsClientListByResourceGroupOptions contains the optional parameters for the AccountsClient.ListByResourceGroup method.
type AccountsClientListByResourceGroupPager ¶ added in v0.3.0
type AccountsClientListByResourceGroupPager struct {
// contains filtered or unexported fields
}
AccountsClientListByResourceGroupPager provides operations for iterating over paged responses.
func (*AccountsClientListByResourceGroupPager) Err ¶ added in v0.3.0
func (p *AccountsClientListByResourceGroupPager) Err() error
Err returns the last error encountered while paging.
func (*AccountsClientListByResourceGroupPager) NextPage ¶ added in v0.3.0
func (p *AccountsClientListByResourceGroupPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*AccountsClientListByResourceGroupPager) PageResponse ¶ added in v0.3.0
func (p *AccountsClientListByResourceGroupPager) PageResponse() AccountsClientListByResourceGroupResponse
PageResponse returns the current AccountsClientListByResourceGroupResponse page.
type AccountsClientListByResourceGroupResponse ¶ added in v0.3.0
type AccountsClientListByResourceGroupResponse struct { AccountsClientListByResourceGroupResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientListByResourceGroupResponse contains the response from method AccountsClient.ListByResourceGroup.
type AccountsClientListByResourceGroupResult ¶ added in v0.3.0
type AccountsClientListByResourceGroupResult struct {
AccountListResult
}
AccountsClientListByResourceGroupResult contains the result from method AccountsClient.ListByResourceGroup.
type AccountsClientListKeysOptions ¶ added in v0.3.0
type AccountsClientListKeysOptions struct { // Specifies type of the key to be listed. Possible value is kerb.. Specifying any value will set the value to kerb. Expand *string }
AccountsClientListKeysOptions contains the optional parameters for the AccountsClient.ListKeys method.
type AccountsClientListKeysResponse ¶ added in v0.3.0
type AccountsClientListKeysResponse struct { AccountsClientListKeysResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientListKeysResponse contains the response from method AccountsClient.ListKeys.
type AccountsClientListKeysResult ¶ added in v0.3.0
type AccountsClientListKeysResult struct {
AccountListKeysResult
}
AccountsClientListKeysResult contains the result from method AccountsClient.ListKeys.
type AccountsClientListOptions ¶ added in v0.3.0
type AccountsClientListOptions struct { }
AccountsClientListOptions contains the optional parameters for the AccountsClient.List method.
type AccountsClientListPager ¶ added in v0.3.0
type AccountsClientListPager struct {
// contains filtered or unexported fields
}
AccountsClientListPager provides operations for iterating over paged responses.
func (*AccountsClientListPager) Err ¶ added in v0.3.0
func (p *AccountsClientListPager) Err() error
Err returns the last error encountered while paging.
func (*AccountsClientListPager) NextPage ¶ added in v0.3.0
func (p *AccountsClientListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*AccountsClientListPager) PageResponse ¶ added in v0.3.0
func (p *AccountsClientListPager) PageResponse() AccountsClientListResponse
PageResponse returns the current AccountsClientListResponse page.
type AccountsClientListResponse ¶ added in v0.3.0
type AccountsClientListResponse struct { AccountsClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientListResponse contains the response from method AccountsClient.List.
type AccountsClientListResult ¶ added in v0.3.0
type AccountsClientListResult struct {
AccountListResult
}
AccountsClientListResult contains the result from method AccountsClient.List.
type AccountsClientListServiceSASOptions ¶ added in v0.3.0
type AccountsClientListServiceSASOptions struct { }
AccountsClientListServiceSASOptions contains the optional parameters for the AccountsClient.ListServiceSAS method.
type AccountsClientListServiceSASResponse ¶ added in v0.3.0
type AccountsClientListServiceSASResponse struct { AccountsClientListServiceSASResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientListServiceSASResponse contains the response from method AccountsClient.ListServiceSAS.
type AccountsClientListServiceSASResult ¶ added in v0.3.0
type AccountsClientListServiceSASResult struct {
ListServiceSasResponse
}
AccountsClientListServiceSASResult contains the result from method AccountsClient.ListServiceSAS.
type AccountsClientRegenerateKeyOptions ¶ added in v0.3.0
type AccountsClientRegenerateKeyOptions struct { }
AccountsClientRegenerateKeyOptions contains the optional parameters for the AccountsClient.RegenerateKey method.
type AccountsClientRegenerateKeyResponse ¶ added in v0.3.0
type AccountsClientRegenerateKeyResponse struct { AccountsClientRegenerateKeyResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientRegenerateKeyResponse contains the response from method AccountsClient.RegenerateKey.
type AccountsClientRegenerateKeyResult ¶ added in v0.3.0
type AccountsClientRegenerateKeyResult struct {
AccountListKeysResult
}
AccountsClientRegenerateKeyResult contains the result from method AccountsClient.RegenerateKey.
type AccountsClientRestoreBlobRangesPoller ¶ added in v0.3.0
type AccountsClientRestoreBlobRangesPoller struct {
// contains filtered or unexported fields
}
AccountsClientRestoreBlobRangesPoller provides polling facilities until the operation reaches a terminal state.
func (*AccountsClientRestoreBlobRangesPoller) Done ¶ added in v0.3.0
func (p *AccountsClientRestoreBlobRangesPoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*AccountsClientRestoreBlobRangesPoller) FinalResponse ¶ added in v0.3.0
func (p *AccountsClientRestoreBlobRangesPoller) FinalResponse(ctx context.Context) (AccountsClientRestoreBlobRangesResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final AccountsClientRestoreBlobRangesResponse will be returned.
func (*AccountsClientRestoreBlobRangesPoller) Poll ¶ added in v0.3.0
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*AccountsClientRestoreBlobRangesPoller) ResumeToken ¶ added in v0.3.0
func (p *AccountsClientRestoreBlobRangesPoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type AccountsClientRestoreBlobRangesPollerResponse ¶ added in v0.3.0
type AccountsClientRestoreBlobRangesPollerResponse struct { // Poller contains an initialized poller. Poller *AccountsClientRestoreBlobRangesPoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientRestoreBlobRangesPollerResponse contains the response from method AccountsClient.RestoreBlobRanges.
func (AccountsClientRestoreBlobRangesPollerResponse) PollUntilDone ¶ added in v0.3.0
func (l AccountsClientRestoreBlobRangesPollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (AccountsClientRestoreBlobRangesResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*AccountsClientRestoreBlobRangesPollerResponse) Resume ¶ added in v0.3.0
func (l *AccountsClientRestoreBlobRangesPollerResponse) Resume(ctx context.Context, client *AccountsClient, token string) error
Resume rehydrates a AccountsClientRestoreBlobRangesPollerResponse from the provided client and resume token.
type AccountsClientRestoreBlobRangesResponse ¶ added in v0.3.0
type AccountsClientRestoreBlobRangesResponse struct { AccountsClientRestoreBlobRangesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientRestoreBlobRangesResponse contains the response from method AccountsClient.RestoreBlobRanges.
type AccountsClientRestoreBlobRangesResult ¶ added in v0.3.0
type AccountsClientRestoreBlobRangesResult struct {
BlobRestoreStatus
}
AccountsClientRestoreBlobRangesResult contains the result from method AccountsClient.RestoreBlobRanges.
type AccountsClientRevokeUserDelegationKeysOptions ¶ added in v0.3.0
type AccountsClientRevokeUserDelegationKeysOptions struct { }
AccountsClientRevokeUserDelegationKeysOptions contains the optional parameters for the AccountsClient.RevokeUserDelegationKeys method.
type AccountsClientRevokeUserDelegationKeysResponse ¶ added in v0.3.0
type AccountsClientRevokeUserDelegationKeysResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientRevokeUserDelegationKeysResponse contains the response from method AccountsClient.RevokeUserDelegationKeys.
type AccountsClientUpdateOptions ¶ added in v0.3.0
type AccountsClientUpdateOptions struct { }
AccountsClientUpdateOptions contains the optional parameters for the AccountsClient.Update method.
type AccountsClientUpdateResponse ¶ added in v0.3.0
type AccountsClientUpdateResponse struct { AccountsClientUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
AccountsClientUpdateResponse contains the response from method AccountsClient.Update.
type AccountsClientUpdateResult ¶ added in v0.3.0
type AccountsClientUpdateResult struct {
Account
}
AccountsClientUpdateResult contains the result from method AccountsClient.Update.
type ActiveDirectoryProperties ¶
type ActiveDirectoryProperties struct { // REQUIRED; Specifies the security identifier (SID) for Azure Storage. AzureStorageSid *string `json:"azureStorageSid,omitempty"` // REQUIRED; Specifies the domain GUID. DomainGUID *string `json:"domainGuid,omitempty"` // REQUIRED; Specifies the primary domain that the AD DNS server is authoritative for. DomainName *string `json:"domainName,omitempty"` // REQUIRED; Specifies the security identifier (SID). DomainSid *string `json:"domainSid,omitempty"` // REQUIRED; Specifies the Active Directory forest to get. ForestName *string `json:"forestName,omitempty"` // REQUIRED; Specifies the NetBIOS domain name. NetBiosDomainName *string `json:"netBiosDomainName,omitempty"` // Specifies the Active Directory account type for Azure Storage. AccountType *ActiveDirectoryPropertiesAccountType `json:"accountType,omitempty"` // Specifies the Active Directory SAMAccountName for Azure Storage. SamAccountName *string `json:"samAccountName,omitempty"` }
ActiveDirectoryProperties - Settings properties for Active Directory (AD).
type ActiveDirectoryPropertiesAccountType ¶ added in v0.3.0
type ActiveDirectoryPropertiesAccountType string
ActiveDirectoryPropertiesAccountType - Specifies the Active Directory account type for Azure Storage.
const ( ActiveDirectoryPropertiesAccountTypeComputer ActiveDirectoryPropertiesAccountType = "Computer" ActiveDirectoryPropertiesAccountTypeUser ActiveDirectoryPropertiesAccountType = "User" )
func PossibleActiveDirectoryPropertiesAccountTypeValues ¶ added in v0.3.0
func PossibleActiveDirectoryPropertiesAccountTypeValues() []ActiveDirectoryPropertiesAccountType
PossibleActiveDirectoryPropertiesAccountTypeValues returns the possible values for the ActiveDirectoryPropertiesAccountType const type.
func (ActiveDirectoryPropertiesAccountType) ToPtr ¶ added in v0.3.0
func (c ActiveDirectoryPropertiesAccountType) ToPtr() *ActiveDirectoryPropertiesAccountType
ToPtr returns a *ActiveDirectoryPropertiesAccountType pointing to the current value.
type AllowedCopyScope ¶ added in v0.3.0
type AllowedCopyScope string
AllowedCopyScope - Restrict copy to and from Storage Accounts within an AAD tenant or with Private Links to the same VNet.
const ( AllowedCopyScopeAAD AllowedCopyScope = "AAD" AllowedCopyScopePrivateLink AllowedCopyScope = "PrivateLink" )
func PossibleAllowedCopyScopeValues ¶ added in v0.3.0
func PossibleAllowedCopyScopeValues() []AllowedCopyScope
PossibleAllowedCopyScopeValues returns the possible values for the AllowedCopyScope const type.
func (AllowedCopyScope) ToPtr ¶ added in v0.3.0
func (c AllowedCopyScope) ToPtr() *AllowedCopyScope
ToPtr returns a *AllowedCopyScope pointing to the current value.
type AzureEntityResource ¶
type AzureEntityResource struct { // READ-ONLY; Resource Etag. Etag *string `json:"etag,omitempty" azure:"ro"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
AzureEntityResource - The resource model definition for an Azure Resource Manager resource with an etag.
type AzureFilesIdentityBasedAuthentication ¶
type AzureFilesIdentityBasedAuthentication struct { // REQUIRED; Indicates the directory service used. DirectoryServiceOptions *DirectoryServiceOptions `json:"directoryServiceOptions,omitempty"` // Required if choose AD. ActiveDirectoryProperties *ActiveDirectoryProperties `json:"activeDirectoryProperties,omitempty"` DefaultSharePermission *DefaultSharePermission `json:"defaultSharePermission,omitempty"` }
AzureFilesIdentityBasedAuthentication - Settings for Azure Files identity based authentication.
type BlobContainer ¶
type BlobContainer struct { // Properties of the blob container. ContainerProperties *ContainerProperties `json:"properties,omitempty"` // READ-ONLY; Resource Etag. Etag *string `json:"etag,omitempty" azure:"ro"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
BlobContainer - Properties of the blob container, including Id, resource name, resource type, Etag.
func (BlobContainer) MarshalJSON ¶
func (b BlobContainer) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlobContainer.
type BlobContainersClient ¶
type BlobContainersClient struct {
// contains filtered or unexported fields
}
BlobContainersClient contains the methods for the BlobContainers group. Don't use this type directly, use NewBlobContainersClient() instead.
func NewBlobContainersClient ¶
func NewBlobContainersClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *BlobContainersClient
NewBlobContainersClient creates a new instance of BlobContainersClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*BlobContainersClient) BeginObjectLevelWorm ¶
func (client *BlobContainersClient) BeginObjectLevelWorm(ctx context.Context, resourceGroupName string, accountName string, containerName string, options *BlobContainersClientBeginObjectLevelWormOptions) (BlobContainersClientObjectLevelWormPollerResponse, error)
BeginObjectLevelWorm - This operation migrates a blob container from container level WORM to object level immutability enabled container. Prerequisites require a container level immutability policy either in locked or unlocked state, Account level versioning must be enabled and there should be no Legal hold on the container. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - BlobContainersClientBeginObjectLevelWormOptions contains the optional parameters for the BlobContainersClient.BeginObjectLevelWorm method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/ObjectLevelWormContainerMigration.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) poller, err := client.BeginObjectLevelWorm(ctx, "<resource-group-name>", "<account-name>", "<container-name>", nil) if err != nil { log.Fatal(err) } _, err = poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } }
Output:
func (*BlobContainersClient) ClearLegalHold ¶
func (client *BlobContainersClient) ClearLegalHold(ctx context.Context, resourceGroupName string, accountName string, containerName string, legalHold LegalHold, options *BlobContainersClientClearLegalHoldOptions) (BlobContainersClientClearLegalHoldResponse, error)
ClearLegalHold - Clears legal hold tags. Clearing the same or non-existent tag results in an idempotent operation. ClearLegalHold clears out only the specified tags in the request. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. legalHold - The LegalHold property that will be clear from a blob container. options - BlobContainersClientClearLegalHoldOptions contains the optional parameters for the BlobContainersClient.ClearLegalHold method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersClearLegalHold.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.ClearLegalHold(ctx, "<resource-group-name>", "<account-name>", "<container-name>", armstorage.LegalHold{ Tags: []*string{ to.StringPtr("tag1"), to.StringPtr("tag2"), to.StringPtr("tag3")}, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientClearLegalHoldResult) }
Output:
func (*BlobContainersClient) Create ¶
func (client *BlobContainersClient) Create(ctx context.Context, resourceGroupName string, accountName string, containerName string, blobContainer BlobContainer, options *BlobContainersClientCreateOptions) (BlobContainersClientCreateResponse, error)
Create - Creates a new container under the specified account as described by request body. The container resource includes metadata and properties for that container. It does not include a list of the blobs contained by the container. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. blobContainer - Properties of the blob container to create. options - BlobContainersClientCreateOptions contains the optional parameters for the BlobContainersClient.Create method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersPutDefaultEncryptionScope.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.Create(ctx, "<resource-group-name>", "<account-name>", "<container-name>", armstorage.BlobContainer{ ContainerProperties: &armstorage.ContainerProperties{ DefaultEncryptionScope: to.StringPtr("<default-encryption-scope>"), DenyEncryptionScopeOverride: to.BoolPtr(true), }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientCreateResult) }
Output:
func (*BlobContainersClient) CreateOrUpdateImmutabilityPolicy ¶
func (client *BlobContainersClient) CreateOrUpdateImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, containerName string, options *BlobContainersClientCreateOrUpdateImmutabilityPolicyOptions) (BlobContainersClientCreateOrUpdateImmutabilityPolicyResponse, error)
CreateOrUpdateImmutabilityPolicy - Creates or updates an unlocked immutability policy. ETag in If-Match is honored if given but not required for this operation. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - BlobContainersClientCreateOrUpdateImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.CreateOrUpdateImmutabilityPolicy method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersPutImmutabilityPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.CreateOrUpdateImmutabilityPolicy(ctx, "<resource-group-name>", "<account-name>", "<container-name>", &armstorage.BlobContainersClientCreateOrUpdateImmutabilityPolicyOptions{IfMatch: nil, Parameters: &armstorage.ImmutabilityPolicy{ Properties: &armstorage.ImmutabilityPolicyProperty{ AllowProtectedAppendWrites: to.BoolPtr(true), ImmutabilityPeriodSinceCreationInDays: to.Int32Ptr(3), }, }, }) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientCreateOrUpdateImmutabilityPolicyResult) }
Output:
func (*BlobContainersClient) Delete ¶
func (client *BlobContainersClient) Delete(ctx context.Context, resourceGroupName string, accountName string, containerName string, options *BlobContainersClientDeleteOptions) (BlobContainersClientDeleteResponse, error)
Delete - Deletes specified container under its account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - BlobContainersClientDeleteOptions contains the optional parameters for the BlobContainersClient.Delete method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersDelete.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) _, err = client.Delete(ctx, "<resource-group-name>", "<account-name>", "<container-name>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*BlobContainersClient) DeleteImmutabilityPolicy ¶
func (client *BlobContainersClient) DeleteImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, containerName string, ifMatch string, options *BlobContainersClientDeleteImmutabilityPolicyOptions) (BlobContainersClientDeleteImmutabilityPolicyResponse, error)
DeleteImmutabilityPolicy - Aborts an unlocked immutability policy. The response of delete has immutabilityPeriodSinceCreationInDays set to 0. ETag in If-Match is required for this operation. Deleting a locked immutability policy is not allowed, the only way is to delete the container after deleting all expired blobs inside the policy locked container. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. ifMatch - The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. options - BlobContainersClientDeleteImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.DeleteImmutabilityPolicy method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersDeleteImmutabilityPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.DeleteImmutabilityPolicy(ctx, "<resource-group-name>", "<account-name>", "<container-name>", "<if-match>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientDeleteImmutabilityPolicyResult) }
Output:
func (*BlobContainersClient) ExtendImmutabilityPolicy ¶
func (client *BlobContainersClient) ExtendImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, containerName string, ifMatch string, options *BlobContainersClientExtendImmutabilityPolicyOptions) (BlobContainersClientExtendImmutabilityPolicyResponse, error)
ExtendImmutabilityPolicy - Extends the immutabilityPeriodSinceCreationInDays of a locked immutabilityPolicy. The only action allowed on a Locked policy will be this action. ETag in If-Match is required for this operation. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. ifMatch - The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. options - BlobContainersClientExtendImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.ExtendImmutabilityPolicy method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersExtendImmutabilityPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.ExtendImmutabilityPolicy(ctx, "<resource-group-name>", "<account-name>", "<container-name>", "<if-match>", &armstorage.BlobContainersClientExtendImmutabilityPolicyOptions{Parameters: &armstorage.ImmutabilityPolicy{ Properties: &armstorage.ImmutabilityPolicyProperty{ ImmutabilityPeriodSinceCreationInDays: to.Int32Ptr(100), }, }, }) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientExtendImmutabilityPolicyResult) }
Output:
func (*BlobContainersClient) Get ¶
func (client *BlobContainersClient) Get(ctx context.Context, resourceGroupName string, accountName string, containerName string, options *BlobContainersClientGetOptions) (BlobContainersClientGetResponse, error)
Get - Gets properties of a specified container. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - BlobContainersClientGetOptions contains the optional parameters for the BlobContainersClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersGetWithAllowProtectedAppendWritesAll.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<resource-group-name>", "<account-name>", "<container-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientGetResult) }
Output:
func (*BlobContainersClient) GetImmutabilityPolicy ¶
func (client *BlobContainersClient) GetImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, containerName string, options *BlobContainersClientGetImmutabilityPolicyOptions) (BlobContainersClientGetImmutabilityPolicyResponse, error)
GetImmutabilityPolicy - Gets the existing immutability policy along with the corresponding ETag in response headers and body. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - BlobContainersClientGetImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.GetImmutabilityPolicy method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersGetImmutabilityPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.GetImmutabilityPolicy(ctx, "<resource-group-name>", "<account-name>", "<container-name>", &armstorage.BlobContainersClientGetImmutabilityPolicyOptions{IfMatch: nil}) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientGetImmutabilityPolicyResult) }
Output:
func (*BlobContainersClient) Lease ¶
func (client *BlobContainersClient) Lease(ctx context.Context, resourceGroupName string, accountName string, containerName string, options *BlobContainersClientLeaseOptions) (BlobContainersClientLeaseResponse, error)
Lease - The Lease Container operation establishes and manages a lock on a container for delete operations. The lock duration can be 15 to 60 seconds, or can be infinite. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - BlobContainersClientLeaseOptions contains the optional parameters for the BlobContainersClient.Lease method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersLease_Acquire.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.Lease(ctx, "<resource-group-name>", "<account-name>", "<container-name>", &armstorage.BlobContainersClientLeaseOptions{Parameters: &armstorage.LeaseContainerRequest{ Action: armstorage.LeaseContainerRequestAction("Acquire").ToPtr(), LeaseDuration: to.Int32Ptr(-1), }, }) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientLeaseResult) }
Output:
func (*BlobContainersClient) List ¶
func (client *BlobContainersClient) List(resourceGroupName string, accountName string, options *BlobContainersClientListOptions) *BlobContainersClientListPager
List - Lists all containers and does not support a prefix like data plane. Also SRP today does not return continuation token. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - BlobContainersClientListOptions contains the optional parameters for the BlobContainersClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) pager := client.List("<resource-group-name>", "<account-name>", &armstorage.BlobContainersClientListOptions{Maxpagesize: nil, Filter: nil, Include: nil, }) for { nextResult := pager.NextPage(ctx) if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } if !nextResult { break } for _, v := range pager.PageResponse().Value { log.Printf("Pager result: %#v\n", v) } } }
Output:
func (*BlobContainersClient) LockImmutabilityPolicy ¶
func (client *BlobContainersClient) LockImmutabilityPolicy(ctx context.Context, resourceGroupName string, accountName string, containerName string, ifMatch string, options *BlobContainersClientLockImmutabilityPolicyOptions) (BlobContainersClientLockImmutabilityPolicyResponse, error)
LockImmutabilityPolicy - Sets the ImmutabilityPolicy to Locked state. The only action allowed on a Locked policy is ExtendImmutabilityPolicy action. ETag in If-Match is required for this operation. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. ifMatch - The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation only if the immutability policy already exists. If omitted, this operation will always be applied. options - BlobContainersClientLockImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.LockImmutabilityPolicy method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersLockImmutabilityPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.LockImmutabilityPolicy(ctx, "<resource-group-name>", "<account-name>", "<container-name>", "<if-match>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientLockImmutabilityPolicyResult) }
Output:
func (*BlobContainersClient) SetLegalHold ¶
func (client *BlobContainersClient) SetLegalHold(ctx context.Context, resourceGroupName string, accountName string, containerName string, legalHold LegalHold, options *BlobContainersClientSetLegalHoldOptions) (BlobContainersClientSetLegalHoldResponse, error)
SetLegalHold - Sets legal hold tags. Setting the same tag results in an idempotent operation. SetLegalHold follows an append pattern and does not clear out the existing tags that are not specified in the request. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. legalHold - The LegalHold property that will be set to a blob container. options - BlobContainersClientSetLegalHoldOptions contains the optional parameters for the BlobContainersClient.SetLegalHold method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersSetLegalHold.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.SetLegalHold(ctx, "<resource-group-name>", "<account-name>", "<container-name>", armstorage.LegalHold{ Tags: []*string{ to.StringPtr("tag1"), to.StringPtr("tag2"), to.StringPtr("tag3")}, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientSetLegalHoldResult) }
Output:
func (*BlobContainersClient) Update ¶
func (client *BlobContainersClient) Update(ctx context.Context, resourceGroupName string, accountName string, containerName string, blobContainer BlobContainer, options *BlobContainersClientUpdateOptions) (BlobContainersClientUpdateResponse, error)
Update - Updates container properties as specified in request body. Properties not mentioned in the request will be unchanged. Update fails if the specified container doesn't already exist. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. containerName - The name of the blob container within the specified storage account. Blob container names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. blobContainer - Properties to update for the blob container. options - BlobContainersClientUpdateOptions contains the optional parameters for the BlobContainersClient.Update method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobContainersPatch.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobContainersClient("<subscription-id>", cred, nil) res, err := client.Update(ctx, "<resource-group-name>", "<account-name>", "<container-name>", armstorage.BlobContainer{ ContainerProperties: &armstorage.ContainerProperties{ Metadata: map[string]*string{ "metadata": to.StringPtr("true"), }, PublicAccess: armstorage.PublicAccessContainer.ToPtr(), }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobContainersClientUpdateResult) }
Output:
type BlobContainersClientBeginObjectLevelWormOptions ¶ added in v0.3.0
type BlobContainersClientBeginObjectLevelWormOptions struct { }
BlobContainersClientBeginObjectLevelWormOptions contains the optional parameters for the BlobContainersClient.BeginObjectLevelWorm method.
type BlobContainersClientClearLegalHoldOptions ¶ added in v0.3.0
type BlobContainersClientClearLegalHoldOptions struct { }
BlobContainersClientClearLegalHoldOptions contains the optional parameters for the BlobContainersClient.ClearLegalHold method.
type BlobContainersClientClearLegalHoldResponse ¶ added in v0.3.0
type BlobContainersClientClearLegalHoldResponse struct { BlobContainersClientClearLegalHoldResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientClearLegalHoldResponse contains the response from method BlobContainersClient.ClearLegalHold.
type BlobContainersClientClearLegalHoldResult ¶ added in v0.3.0
type BlobContainersClientClearLegalHoldResult struct {
LegalHold
}
BlobContainersClientClearLegalHoldResult contains the result from method BlobContainersClient.ClearLegalHold.
type BlobContainersClientCreateOptions ¶ added in v0.3.0
type BlobContainersClientCreateOptions struct { }
BlobContainersClientCreateOptions contains the optional parameters for the BlobContainersClient.Create method.
type BlobContainersClientCreateOrUpdateImmutabilityPolicyOptions ¶ added in v0.3.0
type BlobContainersClientCreateOrUpdateImmutabilityPolicyOptions struct { // The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation // only if the immutability policy already exists. If omitted, this operation will // always be applied. IfMatch *string // The ImmutabilityPolicy Properties that will be created or updated to a blob container. Parameters *ImmutabilityPolicy }
BlobContainersClientCreateOrUpdateImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.CreateOrUpdateImmutabilityPolicy method.
type BlobContainersClientCreateOrUpdateImmutabilityPolicyResponse ¶ added in v0.3.0
type BlobContainersClientCreateOrUpdateImmutabilityPolicyResponse struct { BlobContainersClientCreateOrUpdateImmutabilityPolicyResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientCreateOrUpdateImmutabilityPolicyResponse contains the response from method BlobContainersClient.CreateOrUpdateImmutabilityPolicy.
type BlobContainersClientCreateOrUpdateImmutabilityPolicyResult ¶ added in v0.3.0
type BlobContainersClientCreateOrUpdateImmutabilityPolicyResult struct { ImmutabilityPolicy // ETag contains the information returned from the ETag header response. ETag *string }
BlobContainersClientCreateOrUpdateImmutabilityPolicyResult contains the result from method BlobContainersClient.CreateOrUpdateImmutabilityPolicy.
type BlobContainersClientCreateResponse ¶ added in v0.3.0
type BlobContainersClientCreateResponse struct { BlobContainersClientCreateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientCreateResponse contains the response from method BlobContainersClient.Create.
type BlobContainersClientCreateResult ¶ added in v0.3.0
type BlobContainersClientCreateResult struct {
BlobContainer
}
BlobContainersClientCreateResult contains the result from method BlobContainersClient.Create.
type BlobContainersClientDeleteImmutabilityPolicyOptions ¶ added in v0.3.0
type BlobContainersClientDeleteImmutabilityPolicyOptions struct { }
BlobContainersClientDeleteImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.DeleteImmutabilityPolicy method.
type BlobContainersClientDeleteImmutabilityPolicyResponse ¶ added in v0.3.0
type BlobContainersClientDeleteImmutabilityPolicyResponse struct { BlobContainersClientDeleteImmutabilityPolicyResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientDeleteImmutabilityPolicyResponse contains the response from method BlobContainersClient.DeleteImmutabilityPolicy.
type BlobContainersClientDeleteImmutabilityPolicyResult ¶ added in v0.3.0
type BlobContainersClientDeleteImmutabilityPolicyResult struct { ImmutabilityPolicy // ETag contains the information returned from the ETag header response. ETag *string }
BlobContainersClientDeleteImmutabilityPolicyResult contains the result from method BlobContainersClient.DeleteImmutabilityPolicy.
type BlobContainersClientDeleteOptions ¶ added in v0.3.0
type BlobContainersClientDeleteOptions struct { }
BlobContainersClientDeleteOptions contains the optional parameters for the BlobContainersClient.Delete method.
type BlobContainersClientDeleteResponse ¶ added in v0.3.0
type BlobContainersClientDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientDeleteResponse contains the response from method BlobContainersClient.Delete.
type BlobContainersClientExtendImmutabilityPolicyOptions ¶ added in v0.3.0
type BlobContainersClientExtendImmutabilityPolicyOptions struct { // The ImmutabilityPolicy Properties that will be extended for a blob container. Parameters *ImmutabilityPolicy }
BlobContainersClientExtendImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.ExtendImmutabilityPolicy method.
type BlobContainersClientExtendImmutabilityPolicyResponse ¶ added in v0.3.0
type BlobContainersClientExtendImmutabilityPolicyResponse struct { BlobContainersClientExtendImmutabilityPolicyResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientExtendImmutabilityPolicyResponse contains the response from method BlobContainersClient.ExtendImmutabilityPolicy.
type BlobContainersClientExtendImmutabilityPolicyResult ¶ added in v0.3.0
type BlobContainersClientExtendImmutabilityPolicyResult struct { ImmutabilityPolicy // ETag contains the information returned from the ETag header response. ETag *string }
BlobContainersClientExtendImmutabilityPolicyResult contains the result from method BlobContainersClient.ExtendImmutabilityPolicy.
type BlobContainersClientGetImmutabilityPolicyOptions ¶ added in v0.3.0
type BlobContainersClientGetImmutabilityPolicyOptions struct { // The entity state (ETag) version of the immutability policy to update. A value of "*" can be used to apply the operation // only if the immutability policy already exists. If omitted, this operation will // always be applied. IfMatch *string }
BlobContainersClientGetImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.GetImmutabilityPolicy method.
type BlobContainersClientGetImmutabilityPolicyResponse ¶ added in v0.3.0
type BlobContainersClientGetImmutabilityPolicyResponse struct { BlobContainersClientGetImmutabilityPolicyResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientGetImmutabilityPolicyResponse contains the response from method BlobContainersClient.GetImmutabilityPolicy.
type BlobContainersClientGetImmutabilityPolicyResult ¶ added in v0.3.0
type BlobContainersClientGetImmutabilityPolicyResult struct { ImmutabilityPolicy // ETag contains the information returned from the ETag header response. ETag *string }
BlobContainersClientGetImmutabilityPolicyResult contains the result from method BlobContainersClient.GetImmutabilityPolicy.
type BlobContainersClientGetOptions ¶ added in v0.3.0
type BlobContainersClientGetOptions struct { }
BlobContainersClientGetOptions contains the optional parameters for the BlobContainersClient.Get method.
type BlobContainersClientGetResponse ¶ added in v0.3.0
type BlobContainersClientGetResponse struct { BlobContainersClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientGetResponse contains the response from method BlobContainersClient.Get.
type BlobContainersClientGetResult ¶ added in v0.3.0
type BlobContainersClientGetResult struct {
BlobContainer
}
BlobContainersClientGetResult contains the result from method BlobContainersClient.Get.
type BlobContainersClientLeaseOptions ¶ added in v0.3.0
type BlobContainersClientLeaseOptions struct { // Lease Container request body. Parameters *LeaseContainerRequest }
BlobContainersClientLeaseOptions contains the optional parameters for the BlobContainersClient.Lease method.
type BlobContainersClientLeaseResponse ¶ added in v0.3.0
type BlobContainersClientLeaseResponse struct { BlobContainersClientLeaseResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientLeaseResponse contains the response from method BlobContainersClient.Lease.
type BlobContainersClientLeaseResult ¶ added in v0.3.0
type BlobContainersClientLeaseResult struct {
LeaseContainerResponse
}
BlobContainersClientLeaseResult contains the result from method BlobContainersClient.Lease.
type BlobContainersClientListOptions ¶ added in v0.3.0
type BlobContainersClientListOptions struct { // Optional. When specified, only container names starting with the filter will be listed. Filter *string // Optional, used to include the properties for soft deleted blob containers. Include *ListContainersInclude // Optional. Specified maximum number of containers that can be included in the list. Maxpagesize *string }
BlobContainersClientListOptions contains the optional parameters for the BlobContainersClient.List method.
type BlobContainersClientListPager ¶ added in v0.3.0
type BlobContainersClientListPager struct {
// contains filtered or unexported fields
}
BlobContainersClientListPager provides operations for iterating over paged responses.
func (*BlobContainersClientListPager) Err ¶ added in v0.3.0
func (p *BlobContainersClientListPager) Err() error
Err returns the last error encountered while paging.
func (*BlobContainersClientListPager) NextPage ¶ added in v0.3.0
func (p *BlobContainersClientListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*BlobContainersClientListPager) PageResponse ¶ added in v0.3.0
func (p *BlobContainersClientListPager) PageResponse() BlobContainersClientListResponse
PageResponse returns the current BlobContainersClientListResponse page.
type BlobContainersClientListResponse ¶ added in v0.3.0
type BlobContainersClientListResponse struct { BlobContainersClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientListResponse contains the response from method BlobContainersClient.List.
type BlobContainersClientListResult ¶ added in v0.3.0
type BlobContainersClientListResult struct {
ListContainerItems
}
BlobContainersClientListResult contains the result from method BlobContainersClient.List.
type BlobContainersClientLockImmutabilityPolicyOptions ¶ added in v0.3.0
type BlobContainersClientLockImmutabilityPolicyOptions struct { }
BlobContainersClientLockImmutabilityPolicyOptions contains the optional parameters for the BlobContainersClient.LockImmutabilityPolicy method.
type BlobContainersClientLockImmutabilityPolicyResponse ¶ added in v0.3.0
type BlobContainersClientLockImmutabilityPolicyResponse struct { BlobContainersClientLockImmutabilityPolicyResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientLockImmutabilityPolicyResponse contains the response from method BlobContainersClient.LockImmutabilityPolicy.
type BlobContainersClientLockImmutabilityPolicyResult ¶ added in v0.3.0
type BlobContainersClientLockImmutabilityPolicyResult struct { ImmutabilityPolicy // ETag contains the information returned from the ETag header response. ETag *string }
BlobContainersClientLockImmutabilityPolicyResult contains the result from method BlobContainersClient.LockImmutabilityPolicy.
type BlobContainersClientObjectLevelWormPoller ¶ added in v0.3.0
type BlobContainersClientObjectLevelWormPoller struct {
// contains filtered or unexported fields
}
BlobContainersClientObjectLevelWormPoller provides polling facilities until the operation reaches a terminal state.
func (*BlobContainersClientObjectLevelWormPoller) Done ¶ added in v0.3.0
func (p *BlobContainersClientObjectLevelWormPoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*BlobContainersClientObjectLevelWormPoller) FinalResponse ¶ added in v0.3.0
func (p *BlobContainersClientObjectLevelWormPoller) FinalResponse(ctx context.Context) (BlobContainersClientObjectLevelWormResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final BlobContainersClientObjectLevelWormResponse will be returned.
func (*BlobContainersClientObjectLevelWormPoller) Poll ¶ added in v0.3.0
func (p *BlobContainersClientObjectLevelWormPoller) Poll(ctx context.Context) (*http.Response, error)
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*BlobContainersClientObjectLevelWormPoller) ResumeToken ¶ added in v0.3.0
func (p *BlobContainersClientObjectLevelWormPoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type BlobContainersClientObjectLevelWormPollerResponse ¶ added in v0.3.0
type BlobContainersClientObjectLevelWormPollerResponse struct { // Poller contains an initialized poller. Poller *BlobContainersClientObjectLevelWormPoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientObjectLevelWormPollerResponse contains the response from method BlobContainersClient.ObjectLevelWorm.
func (BlobContainersClientObjectLevelWormPollerResponse) PollUntilDone ¶ added in v0.3.0
func (l BlobContainersClientObjectLevelWormPollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (BlobContainersClientObjectLevelWormResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*BlobContainersClientObjectLevelWormPollerResponse) Resume ¶ added in v0.3.0
func (l *BlobContainersClientObjectLevelWormPollerResponse) Resume(ctx context.Context, client *BlobContainersClient, token string) error
Resume rehydrates a BlobContainersClientObjectLevelWormPollerResponse from the provided client and resume token.
type BlobContainersClientObjectLevelWormResponse ¶ added in v0.3.0
type BlobContainersClientObjectLevelWormResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientObjectLevelWormResponse contains the response from method BlobContainersClient.ObjectLevelWorm.
type BlobContainersClientSetLegalHoldOptions ¶ added in v0.3.0
type BlobContainersClientSetLegalHoldOptions struct { }
BlobContainersClientSetLegalHoldOptions contains the optional parameters for the BlobContainersClient.SetLegalHold method.
type BlobContainersClientSetLegalHoldResponse ¶ added in v0.3.0
type BlobContainersClientSetLegalHoldResponse struct { BlobContainersClientSetLegalHoldResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientSetLegalHoldResponse contains the response from method BlobContainersClient.SetLegalHold.
type BlobContainersClientSetLegalHoldResult ¶ added in v0.3.0
type BlobContainersClientSetLegalHoldResult struct {
LegalHold
}
BlobContainersClientSetLegalHoldResult contains the result from method BlobContainersClient.SetLegalHold.
type BlobContainersClientUpdateOptions ¶ added in v0.3.0
type BlobContainersClientUpdateOptions struct { }
BlobContainersClientUpdateOptions contains the optional parameters for the BlobContainersClient.Update method.
type BlobContainersClientUpdateResponse ¶ added in v0.3.0
type BlobContainersClientUpdateResponse struct { BlobContainersClientUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobContainersClientUpdateResponse contains the response from method BlobContainersClient.Update.
type BlobContainersClientUpdateResult ¶ added in v0.3.0
type BlobContainersClientUpdateResult struct {
BlobContainer
}
BlobContainersClientUpdateResult contains the result from method BlobContainersClient.Update.
type BlobInventoryPoliciesClient ¶
type BlobInventoryPoliciesClient struct {
// contains filtered or unexported fields
}
BlobInventoryPoliciesClient contains the methods for the BlobInventoryPolicies group. Don't use this type directly, use NewBlobInventoryPoliciesClient() instead.
func NewBlobInventoryPoliciesClient ¶
func NewBlobInventoryPoliciesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *BlobInventoryPoliciesClient
NewBlobInventoryPoliciesClient creates a new instance of BlobInventoryPoliciesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*BlobInventoryPoliciesClient) CreateOrUpdate ¶
func (client *BlobInventoryPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, accountName string, blobInventoryPolicyName BlobInventoryPolicyName, properties BlobInventoryPolicy, options *BlobInventoryPoliciesClientCreateOrUpdateOptions) (BlobInventoryPoliciesClientCreateOrUpdateResponse, error)
CreateOrUpdate - Sets the blob inventory policy to the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. blobInventoryPolicyName - The name of the storage account blob inventory policy. It should always be 'default' properties - The blob inventory policy set to a storage account. options - BlobInventoryPoliciesClientCreateOrUpdateOptions contains the optional parameters for the BlobInventoryPoliciesClient.CreateOrUpdate method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountSetBlobInventoryPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobInventoryPoliciesClient("<subscription-id>", cred, nil) res, err := client.CreateOrUpdate(ctx, "<resource-group-name>", "<account-name>", armstorage.BlobInventoryPolicyName("default"), armstorage.BlobInventoryPolicy{ Properties: &armstorage.BlobInventoryPolicyProperties{ Policy: &armstorage.BlobInventoryPolicySchema{ Type: armstorage.InventoryRuleType("Inventory").ToPtr(), Enabled: to.BoolPtr(true), Rules: []*armstorage.BlobInventoryPolicyRule{ { Name: to.StringPtr("<name>"), Definition: &armstorage.BlobInventoryPolicyDefinition{ Format: armstorage.Format("Csv").ToPtr(), Filters: &armstorage.BlobInventoryPolicyFilter{ BlobTypes: []*string{ to.StringPtr("blockBlob"), to.StringPtr("appendBlob"), to.StringPtr("pageBlob")}, IncludeBlobVersions: to.BoolPtr(true), IncludeSnapshots: to.BoolPtr(true), PrefixMatch: []*string{ to.StringPtr("inventoryprefix1"), to.StringPtr("inventoryprefix2")}, }, ObjectType: armstorage.ObjectType("Blob").ToPtr(), Schedule: armstorage.Schedule("Daily").ToPtr(), SchemaFields: []*string{ to.StringPtr("Name"), to.StringPtr("Creation-Time"), to.StringPtr("Last-Modified"), to.StringPtr("Content-Length"), to.StringPtr("Content-MD5"), to.StringPtr("BlobType"), to.StringPtr("AccessTier"), to.StringPtr("AccessTierChangeTime"), to.StringPtr("Snapshot"), to.StringPtr("VersionId"), to.StringPtr("IsCurrentVersion"), to.StringPtr("Metadata")}, }, Destination: to.StringPtr("<destination>"), Enabled: to.BoolPtr(true), }, { Name: to.StringPtr("<name>"), Definition: &armstorage.BlobInventoryPolicyDefinition{ Format: armstorage.Format("Parquet").ToPtr(), ObjectType: armstorage.ObjectType("Container").ToPtr(), Schedule: armstorage.Schedule("Weekly").ToPtr(), SchemaFields: []*string{ to.StringPtr("Name"), to.StringPtr("Last-Modified"), to.StringPtr("Metadata"), to.StringPtr("LeaseStatus"), to.StringPtr("LeaseState"), to.StringPtr("LeaseDuration"), to.StringPtr("PublicAccess"), to.StringPtr("HasImmutabilityPolicy"), to.StringPtr("HasLegalHold")}, }, Destination: to.StringPtr("<destination>"), Enabled: to.BoolPtr(true), }}, }, }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobInventoryPoliciesClientCreateOrUpdateResult) }
Output:
func (*BlobInventoryPoliciesClient) Delete ¶
func (client *BlobInventoryPoliciesClient) Delete(ctx context.Context, resourceGroupName string, accountName string, blobInventoryPolicyName BlobInventoryPolicyName, options *BlobInventoryPoliciesClientDeleteOptions) (BlobInventoryPoliciesClientDeleteResponse, error)
Delete - Deletes the blob inventory policy associated with the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. blobInventoryPolicyName - The name of the storage account blob inventory policy. It should always be 'default' options - BlobInventoryPoliciesClientDeleteOptions contains the optional parameters for the BlobInventoryPoliciesClient.Delete method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountDeleteBlobInventoryPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobInventoryPoliciesClient("<subscription-id>", cred, nil) _, err = client.Delete(ctx, "<resource-group-name>", "<account-name>", armstorage.BlobInventoryPolicyName("default"), nil) if err != nil { log.Fatal(err) } }
Output:
func (*BlobInventoryPoliciesClient) Get ¶
func (client *BlobInventoryPoliciesClient) Get(ctx context.Context, resourceGroupName string, accountName string, blobInventoryPolicyName BlobInventoryPolicyName, options *BlobInventoryPoliciesClientGetOptions) (BlobInventoryPoliciesClientGetResponse, error)
Get - Gets the blob inventory policy associated with the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. blobInventoryPolicyName - The name of the storage account blob inventory policy. It should always be 'default' options - BlobInventoryPoliciesClientGetOptions contains the optional parameters for the BlobInventoryPoliciesClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountGetBlobInventoryPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobInventoryPoliciesClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<resource-group-name>", "<account-name>", armstorage.BlobInventoryPolicyName("default"), nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobInventoryPoliciesClientGetResult) }
Output:
func (*BlobInventoryPoliciesClient) List ¶
func (client *BlobInventoryPoliciesClient) List(ctx context.Context, resourceGroupName string, accountName string, options *BlobInventoryPoliciesClientListOptions) (BlobInventoryPoliciesClientListResponse, error)
List - Gets the blob inventory policy associated with the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - BlobInventoryPoliciesClientListOptions contains the optional parameters for the BlobInventoryPoliciesClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountListBlobInventoryPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobInventoryPoliciesClient("<subscription-id>", cred, nil) res, err := client.List(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobInventoryPoliciesClientListResult) }
Output:
type BlobInventoryPoliciesClientCreateOrUpdateOptions ¶ added in v0.3.0
type BlobInventoryPoliciesClientCreateOrUpdateOptions struct { }
BlobInventoryPoliciesClientCreateOrUpdateOptions contains the optional parameters for the BlobInventoryPoliciesClient.CreateOrUpdate method.
type BlobInventoryPoliciesClientCreateOrUpdateResponse ¶ added in v0.3.0
type BlobInventoryPoliciesClientCreateOrUpdateResponse struct { BlobInventoryPoliciesClientCreateOrUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobInventoryPoliciesClientCreateOrUpdateResponse contains the response from method BlobInventoryPoliciesClient.CreateOrUpdate.
type BlobInventoryPoliciesClientCreateOrUpdateResult ¶ added in v0.3.0
type BlobInventoryPoliciesClientCreateOrUpdateResult struct {
BlobInventoryPolicy
}
BlobInventoryPoliciesClientCreateOrUpdateResult contains the result from method BlobInventoryPoliciesClient.CreateOrUpdate.
type BlobInventoryPoliciesClientDeleteOptions ¶ added in v0.3.0
type BlobInventoryPoliciesClientDeleteOptions struct { }
BlobInventoryPoliciesClientDeleteOptions contains the optional parameters for the BlobInventoryPoliciesClient.Delete method.
type BlobInventoryPoliciesClientDeleteResponse ¶ added in v0.3.0
type BlobInventoryPoliciesClientDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobInventoryPoliciesClientDeleteResponse contains the response from method BlobInventoryPoliciesClient.Delete.
type BlobInventoryPoliciesClientGetOptions ¶ added in v0.3.0
type BlobInventoryPoliciesClientGetOptions struct { }
BlobInventoryPoliciesClientGetOptions contains the optional parameters for the BlobInventoryPoliciesClient.Get method.
type BlobInventoryPoliciesClientGetResponse ¶ added in v0.3.0
type BlobInventoryPoliciesClientGetResponse struct { BlobInventoryPoliciesClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobInventoryPoliciesClientGetResponse contains the response from method BlobInventoryPoliciesClient.Get.
type BlobInventoryPoliciesClientGetResult ¶ added in v0.3.0
type BlobInventoryPoliciesClientGetResult struct {
BlobInventoryPolicy
}
BlobInventoryPoliciesClientGetResult contains the result from method BlobInventoryPoliciesClient.Get.
type BlobInventoryPoliciesClientListOptions ¶ added in v0.3.0
type BlobInventoryPoliciesClientListOptions struct { }
BlobInventoryPoliciesClientListOptions contains the optional parameters for the BlobInventoryPoliciesClient.List method.
type BlobInventoryPoliciesClientListResponse ¶ added in v0.3.0
type BlobInventoryPoliciesClientListResponse struct { BlobInventoryPoliciesClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobInventoryPoliciesClientListResponse contains the response from method BlobInventoryPoliciesClient.List.
type BlobInventoryPoliciesClientListResult ¶ added in v0.3.0
type BlobInventoryPoliciesClientListResult struct {
ListBlobInventoryPolicy
}
BlobInventoryPoliciesClientListResult contains the result from method BlobInventoryPoliciesClient.List.
type BlobInventoryPolicy ¶
type BlobInventoryPolicy struct { // Returns the storage account blob inventory policy rules. Properties *BlobInventoryPolicyProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; Metadata pertaining to creation and last modification of the resource. SystemData *SystemData `json:"systemData,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
BlobInventoryPolicy - The storage account blob inventory policy.
type BlobInventoryPolicyDefinition ¶
type BlobInventoryPolicyDefinition struct { // REQUIRED; This is a required field, it specifies the format for the inventory files. Format *Format `json:"format,omitempty"` // REQUIRED; This is a required field. This field specifies the scope of the inventory created either at the blob or container // level. ObjectType *ObjectType `json:"objectType,omitempty"` // REQUIRED; This is a required field. This field is used to schedule an inventory formation. Schedule *Schedule `json:"schedule,omitempty"` // REQUIRED; This is a required field. This field specifies the fields and properties of the object to be included in the // inventory. The Schema field value 'Name' is always required. The valid values for this // field for the 'Blob' definition.objectType include 'Name, Creation-Time, Last-Modified, Content-Length, Content-MD5, BlobType, // AccessTier, AccessTierChangeTime, AccessTierInferred, Tags, Expiry-Time, // hdiisfolder, Owner, Group, Permissions, Acl, Snapshot, VersionId, IsCurrentVersion, Metadata, LastAccessTime'. The valid // values for 'Container' definition.objectType include 'Name, Last-Modified, // Metadata, LeaseStatus, LeaseState, LeaseDuration, PublicAccess, HasImmutabilityPolicy, HasLegalHold'. Schema field values // 'Expiry-Time, hdiisfolder, Owner, Group, Permissions, Acl' are valid only for // Hns enabled accounts.'Tags' field is only valid for non Hns accounts SchemaFields []*string `json:"schemaFields,omitempty"` // An object that defines the filter set. Filters *BlobInventoryPolicyFilter `json:"filters,omitempty"` }
BlobInventoryPolicyDefinition - An object that defines the blob inventory rule.
func (BlobInventoryPolicyDefinition) MarshalJSON ¶
func (b BlobInventoryPolicyDefinition) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlobInventoryPolicyDefinition.
type BlobInventoryPolicyFilter ¶
type BlobInventoryPolicyFilter struct { // An array of predefined enum values. Valid values include blockBlob, appendBlob, pageBlob. Hns accounts does not support // pageBlobs. This field is required when definition.objectType property is set to // 'Blob'. BlobTypes []*string `json:"blobTypes,omitempty"` // Includes blob versions in blob inventory when value is set to true. The definition.schemaFields values 'VersionId and IsCurrentVersion' // are required if this property is set to true, else they must be // excluded. IncludeBlobVersions *bool `json:"includeBlobVersions,omitempty"` // Includes blob snapshots in blob inventory when value is set to true. The definition.schemaFields value 'Snapshot' is required // if this property is set to true, else it must be excluded. IncludeSnapshots *bool `json:"includeSnapshots,omitempty"` // An array of strings for blob prefixes to be matched. PrefixMatch []*string `json:"prefixMatch,omitempty"` }
BlobInventoryPolicyFilter - An object that defines the blob inventory rule filter conditions. For 'Blob' definition.objectType all filter properties are applicable, 'blobTypes' is required and others are optional. For 'Container' definition.objectType only prefixMatch is applicable and is optional.
func (BlobInventoryPolicyFilter) MarshalJSON ¶
func (b BlobInventoryPolicyFilter) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlobInventoryPolicyFilter.
type BlobInventoryPolicyName ¶
type BlobInventoryPolicyName string
const (
BlobInventoryPolicyNameDefault BlobInventoryPolicyName = "default"
)
func PossibleBlobInventoryPolicyNameValues ¶
func PossibleBlobInventoryPolicyNameValues() []BlobInventoryPolicyName
PossibleBlobInventoryPolicyNameValues returns the possible values for the BlobInventoryPolicyName const type.
func (BlobInventoryPolicyName) ToPtr ¶
func (c BlobInventoryPolicyName) ToPtr() *BlobInventoryPolicyName
ToPtr returns a *BlobInventoryPolicyName pointing to the current value.
type BlobInventoryPolicyProperties ¶
type BlobInventoryPolicyProperties struct { // REQUIRED; The storage account blob inventory policy object. It is composed of policy rules. Policy *BlobInventoryPolicySchema `json:"policy,omitempty"` // READ-ONLY; Returns the last modified date and time of the blob inventory policy. LastModifiedTime *time.Time `json:"lastModifiedTime,omitempty" azure:"ro"` }
BlobInventoryPolicyProperties - The storage account blob inventory policy properties.
func (BlobInventoryPolicyProperties) MarshalJSON ¶
func (b BlobInventoryPolicyProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlobInventoryPolicyProperties.
func (*BlobInventoryPolicyProperties) UnmarshalJSON ¶
func (b *BlobInventoryPolicyProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type BlobInventoryPolicyProperties.
type BlobInventoryPolicyRule ¶
type BlobInventoryPolicyRule struct { // REQUIRED; An object that defines the blob inventory policy rule. Definition *BlobInventoryPolicyDefinition `json:"definition,omitempty"` // REQUIRED; Container name where blob inventory files are stored. Must be pre-created. Destination *string `json:"destination,omitempty"` // REQUIRED; Rule is enabled when set to true. Enabled *bool `json:"enabled,omitempty"` // REQUIRED; A rule name can contain any combination of alpha numeric characters. Rule name is case-sensitive. It must be // unique within a policy. Name *string `json:"name,omitempty"` }
BlobInventoryPolicyRule - An object that wraps the blob inventory rule. Each rule is uniquely defined by name.
type BlobInventoryPolicySchema ¶
type BlobInventoryPolicySchema struct { // REQUIRED; Policy is enabled if set to true. Enabled *bool `json:"enabled,omitempty"` // REQUIRED; The storage account blob inventory policy rules. The rule is applied when it is enabled. Rules []*BlobInventoryPolicyRule `json:"rules,omitempty"` // REQUIRED; The valid value is Inventory Type *InventoryRuleType `json:"type,omitempty"` }
BlobInventoryPolicySchema - The storage account blob inventory policy rules.
func (BlobInventoryPolicySchema) MarshalJSON ¶
func (b BlobInventoryPolicySchema) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlobInventoryPolicySchema.
type BlobRestoreParameters ¶
type BlobRestoreParameters struct { // REQUIRED; Blob ranges to restore. BlobRanges []*BlobRestoreRange `json:"blobRanges,omitempty"` // REQUIRED; Restore blob to the specified time. TimeToRestore *time.Time `json:"timeToRestore,omitempty"` }
BlobRestoreParameters - Blob restore parameters
func (BlobRestoreParameters) MarshalJSON ¶
func (b BlobRestoreParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlobRestoreParameters.
func (*BlobRestoreParameters) UnmarshalJSON ¶
func (b *BlobRestoreParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type BlobRestoreParameters.
type BlobRestoreProgressStatus ¶
type BlobRestoreProgressStatus string
BlobRestoreProgressStatus - The status of blob restore progress. Possible values are: - InProgress: Indicates that blob restore is ongoing. - Complete: Indicates that blob restore has been completed successfully. - Failed: Indicates that blob restore is failed.
const ( BlobRestoreProgressStatusComplete BlobRestoreProgressStatus = "Complete" BlobRestoreProgressStatusFailed BlobRestoreProgressStatus = "Failed" BlobRestoreProgressStatusInProgress BlobRestoreProgressStatus = "InProgress" )
func PossibleBlobRestoreProgressStatusValues ¶
func PossibleBlobRestoreProgressStatusValues() []BlobRestoreProgressStatus
PossibleBlobRestoreProgressStatusValues returns the possible values for the BlobRestoreProgressStatus const type.
func (BlobRestoreProgressStatus) ToPtr ¶
func (c BlobRestoreProgressStatus) ToPtr() *BlobRestoreProgressStatus
ToPtr returns a *BlobRestoreProgressStatus pointing to the current value.
type BlobRestoreRange ¶
type BlobRestoreRange struct { // REQUIRED; Blob end range. This is exclusive. Empty means account end. EndRange *string `json:"endRange,omitempty"` // REQUIRED; Blob start range. This is inclusive. Empty means account start. StartRange *string `json:"startRange,omitempty"` }
BlobRestoreRange - Blob range
type BlobRestoreStatus ¶
type BlobRestoreStatus struct { // READ-ONLY; Failure reason when blob restore is failed. FailureReason *string `json:"failureReason,omitempty" azure:"ro"` // READ-ONLY; Blob restore request parameters. Parameters *BlobRestoreParameters `json:"parameters,omitempty" azure:"ro"` // READ-ONLY; Id for tracking blob restore request. RestoreID *string `json:"restoreId,omitempty" azure:"ro"` // READ-ONLY; The status of blob restore progress. Possible values are: - InProgress: Indicates that blob restore is ongoing. // - Complete: Indicates that blob restore has been completed successfully. - Failed: // Indicates that blob restore is failed. Status *BlobRestoreProgressStatus `json:"status,omitempty" azure:"ro"` }
BlobRestoreStatus - Blob restore status.
type BlobServiceItems ¶
type BlobServiceItems struct { // READ-ONLY; List of blob services returned. Value []*BlobServiceProperties `json:"value,omitempty" azure:"ro"` }
func (BlobServiceItems) MarshalJSON ¶
func (b BlobServiceItems) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlobServiceItems.
type BlobServiceProperties ¶
type BlobServiceProperties struct { // The properties of a storage account’s Blob service. BlobServiceProperties *BlobServicePropertiesProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; Sku name and tier. SKU *SKU `json:"sku,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
BlobServiceProperties - The properties of a storage account’s Blob service.
type BlobServicePropertiesProperties ¶
type BlobServicePropertiesProperties struct { // Deprecated in favor of isVersioningEnabled property. AutomaticSnapshotPolicyEnabled *bool `json:"automaticSnapshotPolicyEnabled,omitempty"` // The blob service properties for change feed events. ChangeFeed *ChangeFeed `json:"changeFeed,omitempty"` // The blob service properties for container soft delete. ContainerDeleteRetentionPolicy *DeleteRetentionPolicy `json:"containerDeleteRetentionPolicy,omitempty"` // Specifies CORS rules for the Blob service. You can include up to five CorsRule elements in the request. If no CorsRule // elements are included in the request body, all CORS rules will be deleted, and // CORS will be disabled for the Blob service. Cors *CorsRules `json:"cors,omitempty"` // DefaultServiceVersion indicates the default version to use for requests to the Blob service if an incoming request’s version // is not specified. Possible values include version 2008-10-27 and all more // recent versions. DefaultServiceVersion *string `json:"defaultServiceVersion,omitempty"` // The blob service properties for blob soft delete. DeleteRetentionPolicy *DeleteRetentionPolicy `json:"deleteRetentionPolicy,omitempty"` // Versioning is enabled if set to true. IsVersioningEnabled *bool `json:"isVersioningEnabled,omitempty"` // The blob service property to configure last access time based tracking policy. LastAccessTimeTrackingPolicy *LastAccessTimeTrackingPolicy `json:"lastAccessTimeTrackingPolicy,omitempty"` // The blob service properties for blob restore policy. RestorePolicy *RestorePolicyProperties `json:"restorePolicy,omitempty"` }
BlobServicePropertiesProperties - The properties of a storage account’s Blob service.
type BlobServicesClient ¶
type BlobServicesClient struct {
// contains filtered or unexported fields
}
BlobServicesClient contains the methods for the BlobServices group. Don't use this type directly, use NewBlobServicesClient() instead.
func NewBlobServicesClient ¶
func NewBlobServicesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *BlobServicesClient
NewBlobServicesClient creates a new instance of BlobServicesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*BlobServicesClient) GetServiceProperties ¶
func (client *BlobServicesClient) GetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, options *BlobServicesClientGetServicePropertiesOptions) (BlobServicesClientGetServicePropertiesResponse, error)
GetServiceProperties - Gets the properties of a storage account’s Blob service, including properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - BlobServicesClientGetServicePropertiesOptions contains the optional parameters for the BlobServicesClient.GetServiceProperties method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobServicesGet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobServicesClient("<subscription-id>", cred, nil) res, err := client.GetServiceProperties(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobServicesClientGetServicePropertiesResult) }
Output:
func (*BlobServicesClient) List ¶
func (client *BlobServicesClient) List(ctx context.Context, resourceGroupName string, accountName string, options *BlobServicesClientListOptions) (BlobServicesClientListResponse, error)
List - List blob services of storage account. It returns a collection of one object named default. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - BlobServicesClientListOptions contains the optional parameters for the BlobServicesClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobServicesList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobServicesClient("<subscription-id>", cred, nil) res, err := client.List(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobServicesClientListResult) }
Output:
func (*BlobServicesClient) SetServiceProperties ¶
func (client *BlobServicesClient) SetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, parameters BlobServiceProperties, options *BlobServicesClientSetServicePropertiesOptions) (BlobServicesClientSetServicePropertiesResponse, error)
SetServiceProperties - Sets the properties of a storage account’s Blob service, including properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. parameters - The properties of a storage account’s Blob service, including properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules. options - BlobServicesClientSetServicePropertiesOptions contains the optional parameters for the BlobServicesClient.SetServiceProperties method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/BlobServicesPutLastAccessTimeBasedTracking.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewBlobServicesClient("<subscription-id>", cred, nil) res, err := client.SetServiceProperties(ctx, "<resource-group-name>", "<account-name>", armstorage.BlobServiceProperties{ BlobServiceProperties: &armstorage.BlobServicePropertiesProperties{ LastAccessTimeTrackingPolicy: &armstorage.LastAccessTimeTrackingPolicy{ Name: armstorage.Name("AccessTimeTracking").ToPtr(), BlobType: []*string{ to.StringPtr("blockBlob")}, Enable: to.BoolPtr(true), TrackingGranularityInDays: to.Int32Ptr(1), }, }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.BlobServicesClientSetServicePropertiesResult) }
Output:
type BlobServicesClientGetServicePropertiesOptions ¶ added in v0.3.0
type BlobServicesClientGetServicePropertiesOptions struct { }
BlobServicesClientGetServicePropertiesOptions contains the optional parameters for the BlobServicesClient.GetServiceProperties method.
type BlobServicesClientGetServicePropertiesResponse ¶ added in v0.3.0
type BlobServicesClientGetServicePropertiesResponse struct { BlobServicesClientGetServicePropertiesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobServicesClientGetServicePropertiesResponse contains the response from method BlobServicesClient.GetServiceProperties.
type BlobServicesClientGetServicePropertiesResult ¶ added in v0.3.0
type BlobServicesClientGetServicePropertiesResult struct {
BlobServiceProperties
}
BlobServicesClientGetServicePropertiesResult contains the result from method BlobServicesClient.GetServiceProperties.
type BlobServicesClientListOptions ¶ added in v0.3.0
type BlobServicesClientListOptions struct { }
BlobServicesClientListOptions contains the optional parameters for the BlobServicesClient.List method.
type BlobServicesClientListResponse ¶ added in v0.3.0
type BlobServicesClientListResponse struct { BlobServicesClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobServicesClientListResponse contains the response from method BlobServicesClient.List.
type BlobServicesClientListResult ¶ added in v0.3.0
type BlobServicesClientListResult struct {
BlobServiceItems
}
BlobServicesClientListResult contains the result from method BlobServicesClient.List.
type BlobServicesClientSetServicePropertiesOptions ¶ added in v0.3.0
type BlobServicesClientSetServicePropertiesOptions struct { }
BlobServicesClientSetServicePropertiesOptions contains the optional parameters for the BlobServicesClient.SetServiceProperties method.
type BlobServicesClientSetServicePropertiesResponse ¶ added in v0.3.0
type BlobServicesClientSetServicePropertiesResponse struct { BlobServicesClientSetServicePropertiesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlobServicesClientSetServicePropertiesResponse contains the response from method BlobServicesClient.SetServiceProperties.
type BlobServicesClientSetServicePropertiesResult ¶ added in v0.3.0
type BlobServicesClientSetServicePropertiesResult struct {
BlobServiceProperties
}
BlobServicesClientSetServicePropertiesResult contains the result from method BlobServicesClient.SetServiceProperties.
type Bypass ¶
type Bypass string
Bypass - Specifies whether traffic is bypassed for Logging/Metrics/AzureServices. Possible values are any combination of Logging|Metrics|AzureServices (For example, "Logging, Metrics"), or None to bypass none of those traffics.
func PossibleBypassValues ¶
func PossibleBypassValues() []Bypass
PossibleBypassValues returns the possible values for the Bypass const type.
type ChangeFeed ¶
type ChangeFeed struct { // Indicates whether change feed event logging is enabled for the Blob service. Enabled *bool `json:"enabled,omitempty"` // Indicates the duration of changeFeed retention in days. Minimum value is 1 day and maximum value is 146000 days (400 years). // A null value indicates an infinite retention of the change feed. RetentionInDays *int32 `json:"retentionInDays,omitempty"` }
ChangeFeed - The blob service properties for change feed events.
type CheckNameAvailabilityResult ¶
type CheckNameAvailabilityResult struct { // READ-ONLY; Gets an error message explaining the Reason value in more detail. Message *string `json:"message,omitempty" azure:"ro"` // READ-ONLY; Gets a boolean value that indicates whether the name is available for you to use. If true, the name is available. // If false, the name has already been taken or is invalid and cannot be used. NameAvailable *bool `json:"nameAvailable,omitempty" azure:"ro"` // READ-ONLY; Gets the reason that a storage account name could not be used. The Reason element is only returned if NameAvailable // is false. Reason *Reason `json:"reason,omitempty" azure:"ro"` }
CheckNameAvailabilityResult - The CheckNameAvailability operation response.
type ContainerProperties ¶
type ContainerProperties struct { // Default the container to use specified encryption scope for all writes. DefaultEncryptionScope *string `json:"defaultEncryptionScope,omitempty"` // Block override of encryption scope from the container default. DenyEncryptionScopeOverride *bool `json:"denyEncryptionScopeOverride,omitempty"` // Enable NFSv3 all squash on blob container. EnableNfsV3AllSquash *bool `json:"enableNfsV3AllSquash,omitempty"` // Enable NFSv3 root squash on blob container. EnableNfsV3RootSquash *bool `json:"enableNfsV3RootSquash,omitempty"` // The object level immutability property of the container. The property is immutable and can only be set to true at the container // creation time. Existing containers must undergo a migration process. ImmutableStorageWithVersioning *ImmutableStorageWithVersioning `json:"immutableStorageWithVersioning,omitempty"` // A name-value pair to associate with the container as metadata. Metadata map[string]*string `json:"metadata,omitempty"` // Specifies whether data in the container may be accessed publicly and the level of access. PublicAccess *PublicAccess `json:"publicAccess,omitempty"` // READ-ONLY; Indicates whether the blob container was deleted. Deleted *bool `json:"deleted,omitempty" azure:"ro"` // READ-ONLY; Blob container deletion time. DeletedTime *time.Time `json:"deletedTime,omitempty" azure:"ro"` // READ-ONLY; The hasImmutabilityPolicy public property is set to true by SRP if ImmutabilityPolicy has been created for this // container. The hasImmutabilityPolicy public property is set to false by SRP if // ImmutabilityPolicy has not been created for this container. HasImmutabilityPolicy *bool `json:"hasImmutabilityPolicy,omitempty" azure:"ro"` // READ-ONLY; The hasLegalHold public property is set to true by SRP if there are at least one existing tag. The hasLegalHold // public property is set to false by SRP if all existing legal hold tags are cleared out. // There can be a maximum of 1000 blob containers with hasLegalHold=true for a given account. HasLegalHold *bool `json:"hasLegalHold,omitempty" azure:"ro"` // READ-ONLY; The ImmutabilityPolicy property of the container. ImmutabilityPolicy *ImmutabilityPolicyProperties `json:"immutabilityPolicy,omitempty" azure:"ro"` // READ-ONLY; Returns the date and time the container was last modified. LastModifiedTime *time.Time `json:"lastModifiedTime,omitempty" azure:"ro"` // READ-ONLY; Specifies whether the lease on a container is of infinite or fixed duration, only when the container is leased. LeaseDuration *LeaseDuration `json:"leaseDuration,omitempty" azure:"ro"` // READ-ONLY; Lease state of the container. LeaseState *LeaseState `json:"leaseState,omitempty" azure:"ro"` // READ-ONLY; The lease status of the container. LeaseStatus *LeaseStatus `json:"leaseStatus,omitempty" azure:"ro"` // READ-ONLY; The LegalHold property of the container. LegalHold *LegalHoldProperties `json:"legalHold,omitempty" azure:"ro"` // READ-ONLY; Remaining retention days for soft deleted blob container. RemainingRetentionDays *int32 `json:"remainingRetentionDays,omitempty" azure:"ro"` // READ-ONLY; The version of the deleted blob container. Version *string `json:"version,omitempty" azure:"ro"` }
ContainerProperties - The properties of a container.
func (ContainerProperties) MarshalJSON ¶
func (c ContainerProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ContainerProperties.
func (*ContainerProperties) UnmarshalJSON ¶
func (c *ContainerProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ContainerProperties.
type CorsRule ¶
type CorsRule struct { // REQUIRED; Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request. AllowedHeaders []*string `json:"allowedHeaders,omitempty"` // REQUIRED; Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin. AllowedMethods []*CorsRuleAllowedMethodsItem `json:"allowedMethods,omitempty"` // REQUIRED; Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or "*" to allow // all domains AllowedOrigins []*string `json:"allowedOrigins,omitempty"` // REQUIRED; Required if CorsRule element is present. A list of response headers to expose to CORS clients. ExposedHeaders []*string `json:"exposedHeaders,omitempty"` // REQUIRED; Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight // response. MaxAgeInSeconds *int32 `json:"maxAgeInSeconds,omitempty"` }
CorsRule - Specifies a CORS rule for the Blob service.
func (CorsRule) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type CorsRule.
type CorsRuleAllowedMethodsItem ¶
type CorsRuleAllowedMethodsItem string
const ( CorsRuleAllowedMethodsItemDELETE CorsRuleAllowedMethodsItem = "DELETE" CorsRuleAllowedMethodsItemGET CorsRuleAllowedMethodsItem = "GET" CorsRuleAllowedMethodsItemHEAD CorsRuleAllowedMethodsItem = "HEAD" CorsRuleAllowedMethodsItemMERGE CorsRuleAllowedMethodsItem = "MERGE" CorsRuleAllowedMethodsItemOPTIONS CorsRuleAllowedMethodsItem = "OPTIONS" CorsRuleAllowedMethodsItemPOST CorsRuleAllowedMethodsItem = "POST" CorsRuleAllowedMethodsItemPUT CorsRuleAllowedMethodsItem = "PUT" )
func PossibleCorsRuleAllowedMethodsItemValues ¶
func PossibleCorsRuleAllowedMethodsItemValues() []CorsRuleAllowedMethodsItem
PossibleCorsRuleAllowedMethodsItemValues returns the possible values for the CorsRuleAllowedMethodsItem const type.
func (CorsRuleAllowedMethodsItem) ToPtr ¶
func (c CorsRuleAllowedMethodsItem) ToPtr() *CorsRuleAllowedMethodsItem
ToPtr returns a *CorsRuleAllowedMethodsItem pointing to the current value.
type CorsRules ¶
type CorsRules struct { // The List of CORS rules. You can include up to five CorsRule elements in the request. CorsRules []*CorsRule `json:"corsRules,omitempty"` }
CorsRules - Sets the CORS rules. You can include up to five CorsRule elements in the request.
func (CorsRules) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type CorsRules.
type CreatedByType ¶
type CreatedByType string
CreatedByType - The type of identity that created the resource.
const ( CreatedByTypeApplication CreatedByType = "Application" CreatedByTypeKey CreatedByType = "Key" CreatedByTypeManagedIdentity CreatedByType = "ManagedIdentity" CreatedByTypeUser CreatedByType = "User" )
func PossibleCreatedByTypeValues ¶
func PossibleCreatedByTypeValues() []CreatedByType
PossibleCreatedByTypeValues returns the possible values for the CreatedByType const type.
func (CreatedByType) ToPtr ¶
func (c CreatedByType) ToPtr() *CreatedByType
ToPtr returns a *CreatedByType pointing to the current value.
type CustomDomain ¶
type CustomDomain struct { // REQUIRED; Gets or sets the custom domain name assigned to the storage account. Name is the CNAME source. Name *string `json:"name,omitempty"` // Indicates whether indirect CName validation is enabled. Default value is false. This should only be set on updates. UseSubDomainName *bool `json:"useSubDomainName,omitempty"` }
CustomDomain - The custom domain assigned to this storage account. This can be set via Update.
type DateAfterCreation ¶
type DateAfterCreation struct { // REQUIRED; Value indicating the age in days after creation DaysAfterCreationGreaterThan *float32 `json:"daysAfterCreationGreaterThan,omitempty"` }
DateAfterCreation - Object to define the number of days after creation.
type DateAfterModification ¶
type DateAfterModification struct { // Value indicating the age in days after last blob access. This property can only be used in conjunction with last access // time tracking policy DaysAfterLastAccessTimeGreaterThan *float32 `json:"daysAfterLastAccessTimeGreaterThan,omitempty"` // Value indicating the age in days after last modification DaysAfterModificationGreaterThan *float32 `json:"daysAfterModificationGreaterThan,omitempty"` }
DateAfterModification - Object to define the number of days after object last modification Or last access. Properties daysAfterModificationGreaterThan and daysAfterLastAccessTimeGreaterThan are mutually exclusive.
type DefaultAction ¶
type DefaultAction string
DefaultAction - Specifies the default action of allow or deny when no other rules match.
const ( DefaultActionAllow DefaultAction = "Allow" DefaultActionDeny DefaultAction = "Deny" )
func PossibleDefaultActionValues ¶
func PossibleDefaultActionValues() []DefaultAction
PossibleDefaultActionValues returns the possible values for the DefaultAction const type.
func (DefaultAction) ToPtr ¶
func (c DefaultAction) ToPtr() *DefaultAction
ToPtr returns a *DefaultAction pointing to the current value.
type DefaultSharePermission ¶
type DefaultSharePermission string
DefaultSharePermission - Default share permission for users using Kerberos authentication if RBAC role is not assigned.
const ()
func PossibleDefaultSharePermissionValues ¶
func PossibleDefaultSharePermissionValues() []DefaultSharePermission
PossibleDefaultSharePermissionValues returns the possible values for the DefaultSharePermission const type.
func (DefaultSharePermission) ToPtr ¶
func (c DefaultSharePermission) ToPtr() *DefaultSharePermission
ToPtr returns a *DefaultSharePermission pointing to the current value.
type DeleteRetentionPolicy ¶
type DeleteRetentionPolicy struct { // Indicates the number of days that the deleted item should be retained. The minimum specified value can be 1 and the maximum // value can be 365. Days *int32 `json:"days,omitempty"` // Indicates whether DeleteRetentionPolicy is enabled. Enabled *bool `json:"enabled,omitempty"` }
DeleteRetentionPolicy - The service properties for soft delete.
type DeletedAccount ¶
type DeletedAccount struct { // Properties of the deleted account. Properties *DeletedAccountProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
DeletedAccount - Deleted storage account
type DeletedAccountListResult ¶
type DeletedAccountListResult struct { // READ-ONLY; Request URL that can be used to query next page of deleted accounts. Returned when total number of requested // deleted accounts exceed maximum page size. NextLink *string `json:"nextLink,omitempty" azure:"ro"` // READ-ONLY; Gets the list of deleted accounts and their properties. Value []*DeletedAccount `json:"value,omitempty" azure:"ro"` }
DeletedAccountListResult - The response from the List Deleted Accounts operation.
func (DeletedAccountListResult) MarshalJSON ¶
func (d DeletedAccountListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type DeletedAccountListResult.
type DeletedAccountProperties ¶
type DeletedAccountProperties struct { // READ-ONLY; Creation time of the deleted account. CreationTime *string `json:"creationTime,omitempty" azure:"ro"` // READ-ONLY; Deletion time of the deleted account. DeletionTime *string `json:"deletionTime,omitempty" azure:"ro"` // READ-ONLY; Location of the deleted account. Location *string `json:"location,omitempty" azure:"ro"` // READ-ONLY; Can be used to attempt recovering this deleted account via PutStorageAccount API. RestoreReference *string `json:"restoreReference,omitempty" azure:"ro"` // READ-ONLY; Full resource id of the original storage account. StorageAccountResourceID *string `json:"storageAccountResourceId,omitempty" azure:"ro"` }
DeletedAccountProperties - Attributes of a deleted storage account.
type DeletedAccountsClient ¶
type DeletedAccountsClient struct {
// contains filtered or unexported fields
}
DeletedAccountsClient contains the methods for the DeletedAccounts group. Don't use this type directly, use NewDeletedAccountsClient() instead.
func NewDeletedAccountsClient ¶
func NewDeletedAccountsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *DeletedAccountsClient
NewDeletedAccountsClient creates a new instance of DeletedAccountsClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*DeletedAccountsClient) Get ¶
func (client *DeletedAccountsClient) Get(ctx context.Context, deletedAccountName string, location string, options *DeletedAccountsClientGetOptions) (DeletedAccountsClientGetResponse, error)
Get - Get properties of specified deleted account resource. If the operation fails it returns an *azcore.ResponseError type. deletedAccountName - Name of the deleted storage account. location - The location of the deleted storage account. options - DeletedAccountsClientGetOptions contains the optional parameters for the DeletedAccountsClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/DeletedAccountGet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewDeletedAccountsClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<deleted-account-name>", "<location>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.DeletedAccountsClientGetResult) }
Output:
func (*DeletedAccountsClient) List ¶
func (client *DeletedAccountsClient) List(options *DeletedAccountsClientListOptions) *DeletedAccountsClientListPager
List - Lists deleted accounts under the subscription. If the operation fails it returns an *azcore.ResponseError type. options - DeletedAccountsClientListOptions contains the optional parameters for the DeletedAccountsClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/DeletedAccountList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewDeletedAccountsClient("<subscription-id>", cred, nil) pager := client.List(nil) for { nextResult := pager.NextPage(ctx) if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } if !nextResult { break } for _, v := range pager.PageResponse().Value { log.Printf("Pager result: %#v\n", v) } } }
Output:
type DeletedAccountsClientGetOptions ¶ added in v0.3.0
type DeletedAccountsClientGetOptions struct { }
DeletedAccountsClientGetOptions contains the optional parameters for the DeletedAccountsClient.Get method.
type DeletedAccountsClientGetResponse ¶ added in v0.3.0
type DeletedAccountsClientGetResponse struct { DeletedAccountsClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
DeletedAccountsClientGetResponse contains the response from method DeletedAccountsClient.Get.
type DeletedAccountsClientGetResult ¶ added in v0.3.0
type DeletedAccountsClientGetResult struct {
DeletedAccount
}
DeletedAccountsClientGetResult contains the result from method DeletedAccountsClient.Get.
type DeletedAccountsClientListOptions ¶ added in v0.3.0
type DeletedAccountsClientListOptions struct { }
DeletedAccountsClientListOptions contains the optional parameters for the DeletedAccountsClient.List method.
type DeletedAccountsClientListPager ¶ added in v0.3.0
type DeletedAccountsClientListPager struct {
// contains filtered or unexported fields
}
DeletedAccountsClientListPager provides operations for iterating over paged responses.
func (*DeletedAccountsClientListPager) Err ¶ added in v0.3.0
func (p *DeletedAccountsClientListPager) Err() error
Err returns the last error encountered while paging.
func (*DeletedAccountsClientListPager) NextPage ¶ added in v0.3.0
func (p *DeletedAccountsClientListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*DeletedAccountsClientListPager) PageResponse ¶ added in v0.3.0
func (p *DeletedAccountsClientListPager) PageResponse() DeletedAccountsClientListResponse
PageResponse returns the current DeletedAccountsClientListResponse page.
type DeletedAccountsClientListResponse ¶ added in v0.3.0
type DeletedAccountsClientListResponse struct { DeletedAccountsClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
DeletedAccountsClientListResponse contains the response from method DeletedAccountsClient.List.
type DeletedAccountsClientListResult ¶ added in v0.3.0
type DeletedAccountsClientListResult struct {
DeletedAccountListResult
}
DeletedAccountsClientListResult contains the result from method DeletedAccountsClient.List.
type DeletedShare ¶
type DeletedShare struct { string `json:"deletedShareName,omitempty"` DeletedShareVersion *string `json:"deletedShareVersion,omitempty"` }DeletedShareName *
DeletedShare - The deleted share to be restored.
type Dimension ¶
type Dimension struct { // Display name of dimension. DisplayName *string `json:"displayName,omitempty"` // Display name of dimension. Name *string `json:"name,omitempty"` }
Dimension of blobs, possibly be blob type or access tier.
type DirectoryServiceOptions ¶
type DirectoryServiceOptions string
DirectoryServiceOptions - Indicates the directory service used.
const ( DirectoryServiceOptionsAADDS DirectoryServiceOptions = "AADDS" DirectoryServiceOptionsAD DirectoryServiceOptions = "AD" DirectoryServiceOptionsNone DirectoryServiceOptions = "None" )
func PossibleDirectoryServiceOptionsValues ¶
func PossibleDirectoryServiceOptionsValues() []DirectoryServiceOptions
PossibleDirectoryServiceOptionsValues returns the possible values for the DirectoryServiceOptions const type.
func (DirectoryServiceOptions) ToPtr ¶
func (c DirectoryServiceOptions) ToPtr() *DirectoryServiceOptions
ToPtr returns a *DirectoryServiceOptions pointing to the current value.
type EnabledProtocols ¶
type EnabledProtocols string
EnabledProtocols - The authentication protocol that is used for the file share. Can only be specified when creating a share.
const ( EnabledProtocolsNFS EnabledProtocols = "NFS" EnabledProtocolsSMB EnabledProtocols = "SMB" )
func PossibleEnabledProtocolsValues ¶
func PossibleEnabledProtocolsValues() []EnabledProtocols
PossibleEnabledProtocolsValues returns the possible values for the EnabledProtocols const type.
func (EnabledProtocols) ToPtr ¶
func (c EnabledProtocols) ToPtr() *EnabledProtocols
ToPtr returns a *EnabledProtocols pointing to the current value.
type Encryption ¶
type Encryption struct { // REQUIRED; The encryption keySource (provider). Possible values (case-insensitive): Microsoft.Storage, Microsoft.Keyvault KeySource *KeySource `json:"keySource,omitempty"` // The identity to be used with service-side encryption at rest. EncryptionIdentity *EncryptionIdentity `json:"identity,omitempty"` // Properties provided by key vault. KeyVaultProperties *KeyVaultProperties `json:"keyvaultproperties,omitempty"` // A boolean indicating whether or not the service applies a secondary layer of encryption with platform managed keys for // data at rest. RequireInfrastructureEncryption *bool `json:"requireInfrastructureEncryption,omitempty"` // List of services which support encryption. Services *EncryptionServices `json:"services,omitempty"` }
Encryption - The encryption settings on the storage account.
type EncryptionIdentity ¶
type EncryptionIdentity struct { // ClientId of the multi-tenant application to be used in conjunction with the user-assigned identity for cross-tenant customer-managed-keys // server-side encryption on the storage account. EncryptionFederatedIdentityClientID *string `json:"federatedIdentityClientId,omitempty"` // Resource identifier of the UserAssigned identity to be associated with server-side encryption on the storage account. EncryptionUserAssignedIdentity *string `json:"userAssignedIdentity,omitempty"` }
EncryptionIdentity - Encryption identity for the storage account.
type EncryptionScope ¶
type EncryptionScope struct { // Properties of the encryption scope. EncryptionScopeProperties *EncryptionScopeProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
EncryptionScope - The Encryption Scope resource.
func (EncryptionScope) MarshalJSON ¶
func (e EncryptionScope) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type EncryptionScope.
type EncryptionScopeKeyVaultProperties ¶
type EncryptionScopeKeyVaultProperties struct { // The object identifier for a key vault key object. When applied, the encryption scope will use the key referenced by the // identifier to enable customer-managed key support on this encryption scope. KeyURI *string `json:"keyUri,omitempty"` // READ-ONLY; The object identifier of the current versioned Key Vault Key in use. CurrentVersionedKeyIdentifier *string `json:"currentVersionedKeyIdentifier,omitempty" azure:"ro"` // READ-ONLY; Timestamp of last rotation of the Key Vault Key. LastKeyRotationTimestamp *time.Time `json:"lastKeyRotationTimestamp,omitempty" azure:"ro"` }
EncryptionScopeKeyVaultProperties - The key vault properties for the encryption scope. This is a required field if encryption scope 'source' attribute is set to 'Microsoft.KeyVault'.
func (EncryptionScopeKeyVaultProperties) MarshalJSON ¶
func (e EncryptionScopeKeyVaultProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type EncryptionScopeKeyVaultProperties.
func (*EncryptionScopeKeyVaultProperties) UnmarshalJSON ¶
func (e *EncryptionScopeKeyVaultProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type EncryptionScopeKeyVaultProperties.
type EncryptionScopeListResult ¶
type EncryptionScopeListResult struct { // READ-ONLY; Request URL that can be used to query next page of encryption scopes. Returned when total number of requested // encryption scopes exceeds the maximum page size. NextLink *string `json:"nextLink,omitempty" azure:"ro"` // READ-ONLY; List of encryption scopes requested. Value []*EncryptionScope `json:"value,omitempty" azure:"ro"` }
EncryptionScopeListResult - List of encryption scopes requested, and if paging is required, a URL to the next page of encryption scopes.
func (EncryptionScopeListResult) MarshalJSON ¶
func (e EncryptionScopeListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type EncryptionScopeListResult.
type EncryptionScopeProperties ¶
type EncryptionScopeProperties struct { // The key vault properties for the encryption scope. This is a required field if encryption scope 'source' attribute is set // to 'Microsoft.KeyVault'. KeyVaultProperties *EncryptionScopeKeyVaultProperties `json:"keyVaultProperties,omitempty"` // A boolean indicating whether or not the service applies a secondary layer of encryption with platform managed keys for // data at rest. RequireInfrastructureEncryption *bool `json:"requireInfrastructureEncryption,omitempty"` // The provider for the encryption scope. Possible values (case-insensitive): Microsoft.Storage, Microsoft.KeyVault. Source *EncryptionScopeSource `json:"source,omitempty"` // The state of the encryption scope. Possible values (case-insensitive): Enabled, Disabled. State *EncryptionScopeState `json:"state,omitempty"` // READ-ONLY; Gets the creation date and time of the encryption scope in UTC. CreationTime *time.Time `json:"creationTime,omitempty" azure:"ro"` // READ-ONLY; Gets the last modification date and time of the encryption scope in UTC. LastModifiedTime *time.Time `json:"lastModifiedTime,omitempty" azure:"ro"` }
EncryptionScopeProperties - Properties of the encryption scope.
func (EncryptionScopeProperties) MarshalJSON ¶
func (e EncryptionScopeProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type EncryptionScopeProperties.
func (*EncryptionScopeProperties) UnmarshalJSON ¶
func (e *EncryptionScopeProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type EncryptionScopeProperties.
type EncryptionScopeSource ¶
type EncryptionScopeSource string
EncryptionScopeSource - The provider for the encryption scope. Possible values (case-insensitive): Microsoft.Storage, Microsoft.KeyVault.
const ( EncryptionScopeSourceMicrosoftKeyVault EncryptionScopeSource = "Microsoft.KeyVault" EncryptionScopeSourceMicrosoftStorage EncryptionScopeSource = "Microsoft.Storage" )
func PossibleEncryptionScopeSourceValues ¶
func PossibleEncryptionScopeSourceValues() []EncryptionScopeSource
PossibleEncryptionScopeSourceValues returns the possible values for the EncryptionScopeSource const type.
func (EncryptionScopeSource) ToPtr ¶
func (c EncryptionScopeSource) ToPtr() *EncryptionScopeSource
ToPtr returns a *EncryptionScopeSource pointing to the current value.
type EncryptionScopeState ¶
type EncryptionScopeState string
EncryptionScopeState - The state of the encryption scope. Possible values (case-insensitive): Enabled, Disabled.
const ( EncryptionScopeStateDisabled EncryptionScopeState = "Disabled" EncryptionScopeStateEnabled EncryptionScopeState = "Enabled" )
func PossibleEncryptionScopeStateValues ¶
func PossibleEncryptionScopeStateValues() []EncryptionScopeState
PossibleEncryptionScopeStateValues returns the possible values for the EncryptionScopeState const type.
func (EncryptionScopeState) ToPtr ¶
func (c EncryptionScopeState) ToPtr() *EncryptionScopeState
ToPtr returns a *EncryptionScopeState pointing to the current value.
type EncryptionScopesClient ¶
type EncryptionScopesClient struct {
// contains filtered or unexported fields
}
EncryptionScopesClient contains the methods for the EncryptionScopes group. Don't use this type directly, use NewEncryptionScopesClient() instead.
func NewEncryptionScopesClient ¶
func NewEncryptionScopesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *EncryptionScopesClient
NewEncryptionScopesClient creates a new instance of EncryptionScopesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*EncryptionScopesClient) Get ¶
func (client *EncryptionScopesClient) Get(ctx context.Context, resourceGroupName string, accountName string, encryptionScopeName string, options *EncryptionScopesClientGetOptions) (EncryptionScopesClientGetResponse, error)
Get - Returns the properties for the specified encryption scope. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. encryptionScopeName - The name of the encryption scope within the specified storage account. Encryption scope names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - EncryptionScopesClientGetOptions contains the optional parameters for the EncryptionScopesClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountGetEncryptionScope.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewEncryptionScopesClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<resource-group-name>", "<account-name>", "<encryption-scope-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.EncryptionScopesClientGetResult) }
Output:
func (*EncryptionScopesClient) List ¶
func (client *EncryptionScopesClient) List(resourceGroupName string, accountName string, options *EncryptionScopesClientListOptions) *EncryptionScopesClientListPager
List - Lists all the encryption scopes available under the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - EncryptionScopesClientListOptions contains the optional parameters for the EncryptionScopesClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountEncryptionScopeList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewEncryptionScopesClient("<subscription-id>", cred, nil) pager := client.List("<resource-group-name>", "<account-name>", nil) for { nextResult := pager.NextPage(ctx) if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } if !nextResult { break } for _, v := range pager.PageResponse().Value { log.Printf("Pager result: %#v\n", v) } } }
Output:
func (*EncryptionScopesClient) Patch ¶
func (client *EncryptionScopesClient) Patch(ctx context.Context, resourceGroupName string, accountName string, encryptionScopeName string, encryptionScope EncryptionScope, options *EncryptionScopesClientPatchOptions) (EncryptionScopesClientPatchResponse, error)
Patch - Update encryption scope properties as specified in the request body. Update fails if the specified encryption scope does not already exist. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. encryptionScopeName - The name of the encryption scope within the specified storage account. Encryption scope names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. encryptionScope - Encryption scope properties to be used for the update. options - EncryptionScopesClientPatchOptions contains the optional parameters for the EncryptionScopesClient.Patch method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountPatchEncryptionScope.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewEncryptionScopesClient("<subscription-id>", cred, nil) res, err := client.Patch(ctx, "<resource-group-name>", "<account-name>", "<encryption-scope-name>", armstorage.EncryptionScope{ EncryptionScopeProperties: &armstorage.EncryptionScopeProperties{ KeyVaultProperties: &armstorage.EncryptionScopeKeyVaultProperties{ KeyURI: to.StringPtr("<key-uri>"), }, Source: armstorage.EncryptionScopeSource("Microsoft.KeyVault").ToPtr(), }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.EncryptionScopesClientPatchResult) }
Output:
func (*EncryptionScopesClient) Put ¶
func (client *EncryptionScopesClient) Put(ctx context.Context, resourceGroupName string, accountName string, encryptionScopeName string, encryptionScope EncryptionScope, options *EncryptionScopesClientPutOptions) (EncryptionScopesClientPutResponse, error)
Put - Synchronously creates or updates an encryption scope under the specified storage account. If an encryption scope is already created and a subsequent request is issued with different properties, the encryption scope properties will be updated per the specified request. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. encryptionScopeName - The name of the encryption scope within the specified storage account. Encryption scope names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. encryptionScope - Encryption scope properties to be used for the create or update. options - EncryptionScopesClientPutOptions contains the optional parameters for the EncryptionScopesClient.Put method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountPutEncryptionScope.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewEncryptionScopesClient("<subscription-id>", cred, nil) res, err := client.Put(ctx, "<resource-group-name>", "<account-name>", "<encryption-scope-name>", armstorage.EncryptionScope{}, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.EncryptionScopesClientPutResult) }
Output:
type EncryptionScopesClientGetOptions ¶ added in v0.3.0
type EncryptionScopesClientGetOptions struct { }
EncryptionScopesClientGetOptions contains the optional parameters for the EncryptionScopesClient.Get method.
type EncryptionScopesClientGetResponse ¶ added in v0.3.0
type EncryptionScopesClientGetResponse struct { EncryptionScopesClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
EncryptionScopesClientGetResponse contains the response from method EncryptionScopesClient.Get.
type EncryptionScopesClientGetResult ¶ added in v0.3.0
type EncryptionScopesClientGetResult struct {
EncryptionScope
}
EncryptionScopesClientGetResult contains the result from method EncryptionScopesClient.Get.
type EncryptionScopesClientListOptions ¶ added in v0.3.0
type EncryptionScopesClientListOptions struct { }
EncryptionScopesClientListOptions contains the optional parameters for the EncryptionScopesClient.List method.
type EncryptionScopesClientListPager ¶ added in v0.3.0
type EncryptionScopesClientListPager struct {
// contains filtered or unexported fields
}
EncryptionScopesClientListPager provides operations for iterating over paged responses.
func (*EncryptionScopesClientListPager) Err ¶ added in v0.3.0
func (p *EncryptionScopesClientListPager) Err() error
Err returns the last error encountered while paging.
func (*EncryptionScopesClientListPager) NextPage ¶ added in v0.3.0
func (p *EncryptionScopesClientListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*EncryptionScopesClientListPager) PageResponse ¶ added in v0.3.0
func (p *EncryptionScopesClientListPager) PageResponse() EncryptionScopesClientListResponse
PageResponse returns the current EncryptionScopesClientListResponse page.
type EncryptionScopesClientListResponse ¶ added in v0.3.0
type EncryptionScopesClientListResponse struct { EncryptionScopesClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
EncryptionScopesClientListResponse contains the response from method EncryptionScopesClient.List.
type EncryptionScopesClientListResult ¶ added in v0.3.0
type EncryptionScopesClientListResult struct {
EncryptionScopeListResult
}
EncryptionScopesClientListResult contains the result from method EncryptionScopesClient.List.
type EncryptionScopesClientPatchOptions ¶ added in v0.3.0
type EncryptionScopesClientPatchOptions struct { }
EncryptionScopesClientPatchOptions contains the optional parameters for the EncryptionScopesClient.Patch method.
type EncryptionScopesClientPatchResponse ¶ added in v0.3.0
type EncryptionScopesClientPatchResponse struct { EncryptionScopesClientPatchResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
EncryptionScopesClientPatchResponse contains the response from method EncryptionScopesClient.Patch.
type EncryptionScopesClientPatchResult ¶ added in v0.3.0
type EncryptionScopesClientPatchResult struct {
EncryptionScope
}
EncryptionScopesClientPatchResult contains the result from method EncryptionScopesClient.Patch.
type EncryptionScopesClientPutOptions ¶ added in v0.3.0
type EncryptionScopesClientPutOptions struct { }
EncryptionScopesClientPutOptions contains the optional parameters for the EncryptionScopesClient.Put method.
type EncryptionScopesClientPutResponse ¶ added in v0.3.0
type EncryptionScopesClientPutResponse struct { EncryptionScopesClientPutResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
EncryptionScopesClientPutResponse contains the response from method EncryptionScopesClient.Put.
type EncryptionScopesClientPutResult ¶ added in v0.3.0
type EncryptionScopesClientPutResult struct {
EncryptionScope
}
EncryptionScopesClientPutResult contains the result from method EncryptionScopesClient.Put.
type EncryptionService ¶
type EncryptionService struct { // A boolean indicating whether or not the service encrypts the data as it is stored. Encryption at rest is enabled by default // today and cannot be disabled. Enabled *bool `json:"enabled,omitempty"` // Encryption key type to be used for the encryption service. 'Account' key type implies that an account-scoped encryption // key will be used. 'Service' key type implies that a default service key is used. KeyType *KeyType `json:"keyType,omitempty"` // READ-ONLY; Gets a rough estimate of the date/time when the encryption was last enabled by the user. Data is encrypted at // rest by default today and cannot be disabled. LastEnabledTime *time.Time `json:"lastEnabledTime,omitempty" azure:"ro"` }
EncryptionService - A service that allows server-side encryption to be used.
func (EncryptionService) MarshalJSON ¶
func (e EncryptionService) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type EncryptionService.
func (*EncryptionService) UnmarshalJSON ¶
func (e *EncryptionService) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type EncryptionService.
type EncryptionServices ¶
type EncryptionServices struct { // The encryption function of the blob storage service. Blob *EncryptionService `json:"blob,omitempty"` // The encryption function of the file storage service. File *EncryptionService `json:"file,omitempty"` // The encryption function of the queue storage service. Queue *EncryptionService `json:"queue,omitempty"` // The encryption function of the table storage service. Table *EncryptionService `json:"table,omitempty"` }
EncryptionServices - A list of services that support encryption.
type Endpoints ¶
type Endpoints struct { // Gets the internet routing storage endpoints InternetEndpoints *AccountInternetEndpoints `json:"internetEndpoints,omitempty"` // Gets the microsoft routing storage endpoints. MicrosoftEndpoints *AccountMicrosoftEndpoints `json:"microsoftEndpoints,omitempty"` // READ-ONLY; Gets the blob endpoint. Blob *string `json:"blob,omitempty" azure:"ro"` // READ-ONLY; Gets the dfs endpoint. Dfs *string `json:"dfs,omitempty" azure:"ro"` // READ-ONLY; Gets the file endpoint. File *string `json:"file,omitempty" azure:"ro"` // READ-ONLY; Gets the queue endpoint. Queue *string `json:"queue,omitempty" azure:"ro"` // READ-ONLY; Gets the table endpoint. Table *string `json:"table,omitempty" azure:"ro"` // READ-ONLY; Gets the web endpoint. Web *string `json:"web,omitempty" azure:"ro"` }
Endpoints - The URIs that are used to perform a retrieval of a public blob, queue, table, web or dfs object.
type ExpirationAction ¶
type ExpirationAction string
ExpirationAction - The SAS expiration action. Can only be Log.
const (
ExpirationActionLog ExpirationAction = "Log"
)
func PossibleExpirationActionValues ¶
func PossibleExpirationActionValues() []ExpirationAction
PossibleExpirationActionValues returns the possible values for the ExpirationAction const type.
func (ExpirationAction) ToPtr ¶
func (c ExpirationAction) ToPtr() *ExpirationAction
ToPtr returns a *ExpirationAction pointing to the current value.
type ExtendedLocation ¶
type ExtendedLocation struct { // The name of the extended location. Name *string `json:"name,omitempty"` // The type of the extended location. Type *ExtendedLocationTypes `json:"type,omitempty"` }
ExtendedLocation - The complex type of the extended location.
type ExtendedLocationTypes ¶
type ExtendedLocationTypes string
ExtendedLocationTypes - The type of extendedLocation.
const (
ExtendedLocationTypesEdgeZone ExtendedLocationTypes = "EdgeZone"
)
func PossibleExtendedLocationTypesValues ¶
func PossibleExtendedLocationTypesValues() []ExtendedLocationTypes
PossibleExtendedLocationTypesValues returns the possible values for the ExtendedLocationTypes const type.
func (ExtendedLocationTypes) ToPtr ¶
func (c ExtendedLocationTypes) ToPtr() *ExtendedLocationTypes
ToPtr returns a *ExtendedLocationTypes pointing to the current value.
type FileServiceItems ¶
type FileServiceItems struct { // READ-ONLY; List of file services returned. Value []*FileServiceProperties `json:"value,omitempty" azure:"ro"` }
func (FileServiceItems) MarshalJSON ¶
func (f FileServiceItems) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FileServiceItems.
type FileServiceProperties ¶
type FileServiceProperties struct { // The properties of File services in storage account. FileServiceProperties *FileServicePropertiesProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; Sku name and tier. SKU *SKU `json:"sku,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
FileServiceProperties - The properties of File services in storage account.
type FileServicePropertiesProperties ¶
type FileServicePropertiesProperties struct { // Specifies CORS rules for the File service. You can include up to five CorsRule elements in the request. If no CorsRule // elements are included in the request body, all CORS rules will be deleted, and // CORS will be disabled for the File service. Cors *CorsRules `json:"cors,omitempty"` // Protocol settings for file service ProtocolSettings *ProtocolSettings `json:"protocolSettings,omitempty"` ShareDeleteRetentionPolicy *DeleteRetentionPolicy `json:"shareDeleteRetentionPolicy,omitempty"` }
FileServicePropertiesProperties - The properties of File services in storage account.
type FileServicesClient ¶
type FileServicesClient struct {
// contains filtered or unexported fields
}
FileServicesClient contains the methods for the FileServices group. Don't use this type directly, use NewFileServicesClient() instead.
func NewFileServicesClient ¶
func NewFileServicesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *FileServicesClient
NewFileServicesClient creates a new instance of FileServicesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*FileServicesClient) GetServiceProperties ¶
func (client *FileServicesClient) GetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, options *FileServicesClientGetServicePropertiesOptions) (FileServicesClientGetServicePropertiesResponse, error)
GetServiceProperties - Gets the properties of file services in storage accounts, including CORS (Cross-Origin Resource Sharing) rules. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - FileServicesClientGetServicePropertiesOptions contains the optional parameters for the FileServicesClient.GetServiceProperties method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/FileServicesGet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewFileServicesClient("<subscription-id>", cred, nil) res, err := client.GetServiceProperties(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.FileServicesClientGetServicePropertiesResult) }
Output:
func (*FileServicesClient) List ¶
func (client *FileServicesClient) List(ctx context.Context, resourceGroupName string, accountName string, options *FileServicesClientListOptions) (FileServicesClientListResponse, error)
List - List all file services in storage accounts If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - FileServicesClientListOptions contains the optional parameters for the FileServicesClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/FileServicesList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewFileServicesClient("<subscription-id>", cred, nil) res, err := client.List(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.FileServicesClientListResult) }
Output:
func (*FileServicesClient) SetServiceProperties ¶
func (client *FileServicesClient) SetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, parameters FileServiceProperties, options *FileServicesClientSetServicePropertiesOptions) (FileServicesClientSetServicePropertiesResponse, error)
SetServiceProperties - Sets the properties of file services in storage accounts, including CORS (Cross-Origin Resource Sharing) rules. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. parameters - The properties of file services in storage accounts, including CORS (Cross-Origin Resource Sharing) rules. options - FileServicesClientSetServicePropertiesOptions contains the optional parameters for the FileServicesClient.SetServiceProperties method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/FileServicesPut.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewFileServicesClient("<subscription-id>", cred, nil) res, err := client.SetServiceProperties(ctx, "<resource-group-name>", "<account-name>", armstorage.FileServiceProperties{ FileServiceProperties: &armstorage.FileServicePropertiesProperties{ Cors: &armstorage.CorsRules{ CorsRules: []*armstorage.CorsRule{ { AllowedHeaders: []*string{ to.StringPtr("x-ms-meta-abc"), to.StringPtr("x-ms-meta-data*"), to.StringPtr("x-ms-meta-target*")}, AllowedMethods: []*armstorage.CorsRuleAllowedMethodsItem{ armstorage.CorsRuleAllowedMethodsItem("GET").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("HEAD").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("POST").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("OPTIONS").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("MERGE").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("PUT").ToPtr()}, AllowedOrigins: []*string{ to.StringPtr("http://www.contoso.com"), to.StringPtr("http://www.fabrikam.com")}, ExposedHeaders: []*string{ to.StringPtr("x-ms-meta-*")}, MaxAgeInSeconds: to.Int32Ptr(100), }, { AllowedHeaders: []*string{ to.StringPtr("*")}, AllowedMethods: []*armstorage.CorsRuleAllowedMethodsItem{ armstorage.CorsRuleAllowedMethodsItem("GET").ToPtr()}, AllowedOrigins: []*string{ to.StringPtr("*")}, ExposedHeaders: []*string{ to.StringPtr("*")}, MaxAgeInSeconds: to.Int32Ptr(2), }, { AllowedHeaders: []*string{ to.StringPtr("x-ms-meta-12345675754564*")}, AllowedMethods: []*armstorage.CorsRuleAllowedMethodsItem{ armstorage.CorsRuleAllowedMethodsItem("GET").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("PUT").ToPtr()}, AllowedOrigins: []*string{ to.StringPtr("http://www.abc23.com"), to.StringPtr("https://www.fabrikam.com/*")}, ExposedHeaders: []*string{ to.StringPtr("x-ms-meta-abc"), to.StringPtr("x-ms-meta-data*"), to.StringPtr("x-ms-meta-target*")}, MaxAgeInSeconds: to.Int32Ptr(2000), }}, }, }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.FileServicesClientSetServicePropertiesResult) }
Output:
type FileServicesClientGetServicePropertiesOptions ¶ added in v0.3.0
type FileServicesClientGetServicePropertiesOptions struct { }
FileServicesClientGetServicePropertiesOptions contains the optional parameters for the FileServicesClient.GetServiceProperties method.
type FileServicesClientGetServicePropertiesResponse ¶ added in v0.3.0
type FileServicesClientGetServicePropertiesResponse struct { FileServicesClientGetServicePropertiesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
FileServicesClientGetServicePropertiesResponse contains the response from method FileServicesClient.GetServiceProperties.
type FileServicesClientGetServicePropertiesResult ¶ added in v0.3.0
type FileServicesClientGetServicePropertiesResult struct {
FileServiceProperties
}
FileServicesClientGetServicePropertiesResult contains the result from method FileServicesClient.GetServiceProperties.
type FileServicesClientListOptions ¶ added in v0.3.0
type FileServicesClientListOptions struct { }
FileServicesClientListOptions contains the optional parameters for the FileServicesClient.List method.
type FileServicesClientListResponse ¶ added in v0.3.0
type FileServicesClientListResponse struct { FileServicesClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
FileServicesClientListResponse contains the response from method FileServicesClient.List.
type FileServicesClientListResult ¶ added in v0.3.0
type FileServicesClientListResult struct {
FileServiceItems
}
FileServicesClientListResult contains the result from method FileServicesClient.List.
type FileServicesClientSetServicePropertiesOptions ¶ added in v0.3.0
type FileServicesClientSetServicePropertiesOptions struct { }
FileServicesClientSetServicePropertiesOptions contains the optional parameters for the FileServicesClient.SetServiceProperties method.
type FileServicesClientSetServicePropertiesResponse ¶ added in v0.3.0
type FileServicesClientSetServicePropertiesResponse struct { FileServicesClientSetServicePropertiesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
FileServicesClientSetServicePropertiesResponse contains the response from method FileServicesClient.SetServiceProperties.
type FileServicesClientSetServicePropertiesResult ¶ added in v0.3.0
type FileServicesClientSetServicePropertiesResult struct {
FileServiceProperties
}
FileServicesClientSetServicePropertiesResult contains the result from method FileServicesClient.SetServiceProperties.
type FileShare ¶
type FileShare struct { FileShareProperties `json:"properties,omitempty"` Etag *string `json:"etag,omitempty" azure:"ro"` ID *string `json:"id,omitempty" azure:"ro"` Name *string `json:"name,omitempty" azure:"ro"` Type *string `json:"type,omitempty" azure:"ro"` }FileShareProperties *
FileShare - Properties of the file share, including Id, resource name, resource type, Etag.
func (FileShare) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type FileShare.
type FileShareItem ¶
type FileShareItem struct { FileShareProperties `json:"properties,omitempty"` Etag *string `json:"etag,omitempty" azure:"ro"` ID *string `json:"id,omitempty" azure:"ro"` Name *string `json:"name,omitempty" azure:"ro"` Type *string `json:"type,omitempty" azure:"ro"` }Properties *
FileShareItem - The file share properties be listed out.
type FileShareItems ¶
type FileShareItems struct { // maximum page size. NextLink *string `json:"nextLink,omitempty" azure:"ro"` Value []*FileShareItem `json:"value,omitempty" azure:"ro"` }
FileShareItems - Response schema. Contains list of shares returned, and if paging is requested or required, a URL to next page of shares.
func (FileShareItems) MarshalJSON ¶
func (f FileShareItems) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FileShareItems.
type FileShareProperties ¶
type FileShareProperties struct { // account can choose Premium. AccessTier *ShareAccessTier `json:"accessTier,omitempty"` EnabledProtocols *EnabledProtocols `json:"enabledProtocols,omitempty"` Metadata map[string]*string `json:"metadata,omitempty"` RootSquash *RootSquashType `json:"rootSquash,omitempty"` // Shares, the maximum size is 102400. ShareQuota *int32 `json:"shareQuota,omitempty"` SignedIdentifiers []*SignedIdentifier `json:"signedIdentifiers,omitempty"` AccessTierChangeTime *time.Time `json:"accessTierChangeTime,omitempty" azure:"ro"` AccessTierStatus *string `json:"accessTierStatus,omitempty" azure:"ro"` Deleted *bool `json:"deleted,omitempty" azure:"ro"` DeletedTime *time.Time `json:"deletedTime,omitempty" azure:"ro"` LastModifiedTime *time.Time `json:"lastModifiedTime,omitempty" azure:"ro"` LeaseDuration *LeaseDuration `json:"leaseDuration,omitempty" azure:"ro"` LeaseState *LeaseState `json:"leaseState,omitempty" azure:"ro"` LeaseStatus *LeaseStatus `json:"leaseStatus,omitempty" azure:"ro"` RemainingRetentionDays *int32 `json:"remainingRetentionDays,omitempty" azure:"ro"` // or recently resized files. ShareUsageBytes *int64 `json:"shareUsageBytes,omitempty" azure:"ro"` SnapshotTime *time.Time `json:"snapshotTime,omitempty" azure:"ro"` Version *string `json:"version,omitempty" azure:"ro"` }
FileShareProperties - The properties of the file share.
func (FileShareProperties) MarshalJSON ¶
func (f FileShareProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FileShareProperties.
func (*FileShareProperties) UnmarshalJSON ¶
func (f *FileShareProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FileShareProperties.
type FileSharesClient ¶
type FileSharesClient struct {
// contains filtered or unexported fields
}
FileSharesClient contains the methods for the FileShares group. Don't use this type directly, use NewFileSharesClient() instead.
func NewFileSharesClient ¶
func NewFileSharesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *FileSharesClient
NewFileSharesClient creates a new instance of FileSharesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*FileSharesClient) Create ¶
func (client *FileSharesClient) Create(ctx context.Context, resourceGroupName string, accountName string, shareName string, fileShare FileShare, options *FileSharesClientCreateOptions) (FileSharesClientCreateResponse, error)
Create - Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. shareName - The name of the file share within the specified storage account. File share names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. fileShare - Properties of the file share to create. options - FileSharesClientCreateOptions contains the optional parameters for the FileSharesClient.Create method.
func (*FileSharesClient) Delete ¶
func (client *FileSharesClient) Delete(ctx context.Context, resourceGroupName string, accountName string, shareName string, options *FileSharesClientDeleteOptions) (FileSharesClientDeleteResponse, error)
Delete - Deletes specified share under its account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. shareName - The name of the file share within the specified storage account. File share names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - FileSharesClientDeleteOptions contains the optional parameters for the FileSharesClient.Delete method.
func (*FileSharesClient) Get ¶
func (client *FileSharesClient) Get(ctx context.Context, resourceGroupName string, accountName string, shareName string, options *FileSharesClientGetOptions) (FileSharesClientGetResponse, error)
Get - Gets properties of a specified share. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. shareName - The name of the file share within the specified storage account. File share names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - FileSharesClientGetOptions contains the optional parameters for the FileSharesClient.Get method.
func (*FileSharesClient) Lease ¶
func (client *FileSharesClient) Lease(ctx context.Context, resourceGroupName string, accountName string, shareName string, options *FileSharesClientLeaseOptions) (FileSharesClientLeaseResponse, error)
Lease - The Lease Share operation establishes and manages a lock on a share for delete operations. The lock duration can be 15 to 60 seconds, or can be infinite. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. shareName - The name of the file share within the specified storage account. File share names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - FileSharesClientLeaseOptions contains the optional parameters for the FileSharesClient.Lease method.
func (*FileSharesClient) List ¶
func (client *FileSharesClient) List(resourceGroupName string, accountName string, options *FileSharesClientListOptions) *FileSharesClientListPager
List - Lists all shares. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - FileSharesClientListOptions contains the optional parameters for the FileSharesClient.List method.
func (*FileSharesClient) Restore ¶
func (client *FileSharesClient) Restore(ctx context.Context, resourceGroupName string, accountName string, shareName string, deletedShare DeletedShare, options *FileSharesClientRestoreOptions) (FileSharesClientRestoreResponse, error)
Restore - Restore a file share within a valid retention days if share soft delete is enabled If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. shareName - The name of the file share within the specified storage account. File share names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. options - FileSharesClientRestoreOptions contains the optional parameters for the FileSharesClient.Restore method.
func (*FileSharesClient) Update ¶
func (client *FileSharesClient) Update(ctx context.Context, resourceGroupName string, accountName string, shareName string, fileShare FileShare, options *FileSharesClientUpdateOptions) (FileSharesClientUpdateResponse, error)
Update - Updates share properties as specified in request body. Properties not mentioned in the request will not be changed. Update fails if the specified share does not already exist. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. shareName - The name of the file share within the specified storage account. File share names must be between 3 and 63 characters in length and use numbers, lower-case letters and dash (-) only. Every dash (-) character must be immediately preceded and followed by a letter or number. fileShare - Properties to update for the file share. options - FileSharesClientUpdateOptions contains the optional parameters for the FileSharesClient.Update method.
type FileSharesClientCreateOptions ¶ added in v0.3.0
type FileSharesClientCreateOptions struct { // with delimiter ',' Expand *string }
FileSharesClientCreateOptions contains the optional parameters for the FileSharesClient.Create method.
type FileSharesClientCreateResponse ¶ added in v0.3.0
FileSharesClientCreateResponse contains the response from method FileSharesClient.Create.
type FileSharesClientCreateResult ¶ added in v0.3.0
type FileSharesClientCreateResult struct {
}FileSharesClientCreateResult contains the result from method FileSharesClient.Create.
type FileSharesClientDeleteOptions ¶ added in v0.3.0
type FileSharesClientDeleteOptions struct { // share is deleted including all of its file share snapshots. If the file share // contains leased-snapshots, the deletion fails. For 'leased-snapshots', the file share is deleted included all of its file // share snapshots (leased/unleased). For 'none', the file share is deleted if it // has no share snapshots. If the file share contains any snapshots (leased or unleased), the deletion fails. Include *string XMSSnapshot *string }
FileSharesClientDeleteOptions contains the optional parameters for the FileSharesClient.Delete method.
type FileSharesClientDeleteResponse ¶ added in v0.3.0
FileSharesClientDeleteResponse contains the response from method FileSharesClient.Delete.
type FileSharesClientGetOptions ¶ added in v0.3.0
type FileSharesClientGetOptions struct { // with delimiter ','. Expand *string XMSSnapshot *string }
FileSharesClientGetOptions contains the optional parameters for the FileSharesClient.Get method.
type FileSharesClientGetResponse ¶ added in v0.3.0
FileSharesClientGetResponse contains the response from method FileSharesClient.Get.
type FileSharesClientGetResult ¶ added in v0.3.0
type FileSharesClientGetResult struct {
}FileSharesClientGetResult contains the result from method FileSharesClient.Get.
type FileSharesClientLeaseOptions ¶ added in v0.3.0
type FileSharesClientLeaseOptions struct { LeaseShareRequest XMSSnapshot *string }Parameters *
FileSharesClientLeaseOptions contains the optional parameters for the FileSharesClient.Lease method.
type FileSharesClientLeaseResponse ¶ added in v0.3.0
FileSharesClientLeaseResponse contains the response from method FileSharesClient.Lease.
type FileSharesClientLeaseResult ¶ added in v0.3.0
type FileSharesClientLeaseResult struct { string }ETag *
FileSharesClientLeaseResult contains the result from method FileSharesClient.Lease.
type FileSharesClientListOptions ¶ added in v0.3.0
type FileSharesClientListOptions struct { // as a string with delimiter ',' Expand *string Filter *string Maxpagesize *string }
FileSharesClientListOptions contains the optional parameters for the FileSharesClient.List method.
type FileSharesClientListPager ¶ added in v0.3.0
type FileSharesClientListPager struct {
// contains filtered or unexported fields
}
FileSharesClientListPager provides operations for iterating over paged responses.
func (*FileSharesClientListPager) Err ¶ added in v0.3.0
func (p *FileSharesClientListPager) Err() error
Err returns the last error encountered while paging.
func (*FileSharesClientListPager) NextPage ¶ added in v0.3.0
func (p *FileSharesClientListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*FileSharesClientListPager) PageResponse ¶ added in v0.3.0
func (p *FileSharesClientListPager) PageResponse() FileSharesClientListResponse
PageResponse returns the current FileSharesClientListResponse page.
type FileSharesClientListResponse ¶ added in v0.3.0
FileSharesClientListResponse contains the response from method FileSharesClient.List.
type FileSharesClientListResult ¶ added in v0.3.0
type FileSharesClientListResult struct {
}FileSharesClientListResult contains the result from method FileSharesClient.List.
type FileSharesClientRestoreOptions ¶ added in v0.3.0
type FileSharesClientRestoreOptions struct { }
FileSharesClientRestoreOptions contains the optional parameters for the FileSharesClient.Restore method.
type FileSharesClientRestoreResponse ¶ added in v0.3.0
FileSharesClientRestoreResponse contains the response from method FileSharesClient.Restore.
type FileSharesClientUpdateOptions ¶ added in v0.3.0
type FileSharesClientUpdateOptions struct { }
FileSharesClientUpdateOptions contains the optional parameters for the FileSharesClient.Update method.
type FileSharesClientUpdateResponse ¶ added in v0.3.0
FileSharesClientUpdateResponse contains the response from method FileSharesClient.Update.
type FileSharesClientUpdateResult ¶ added in v0.3.0
type FileSharesClientUpdateResult struct {
}FileSharesClientUpdateResult contains the result from method FileSharesClient.Update.
type Format ¶
type Format string
Format - This is a required field, it specifies the format for the inventory files.
func PossibleFormatValues ¶
func PossibleFormatValues() []Format
PossibleFormatValues returns the possible values for the Format const type.
type GeoReplicationStats ¶
type GeoReplicationStats struct { // READ-ONLY; A boolean flag which indicates whether or not account failover is supported for the account. CanFailover *bool `json:"canFailover,omitempty" azure:"ro"` // READ-ONLY; All primary writes preceding this UTC date/time value are guaranteed to be available for read operations. Primary // writes following this point in time may or may not be available for reads. Element may // be default value if value of LastSyncTime is not available, this can happen if secondary is offline or we are in bootstrap. LastSyncTime *time.Time `json:"lastSyncTime,omitempty" azure:"ro"` // READ-ONLY; The status of the secondary location. Possible values are: - Live: Indicates that the secondary location is // active and operational. - Bootstrap: Indicates initial synchronization from the primary // location to the secondary location is in progress.This typically occurs when replication is first enabled. - Unavailable: // Indicates that the secondary location is temporarily unavailable. Status *GeoReplicationStatus `json:"status,omitempty" azure:"ro"` }
GeoReplicationStats - Statistics related to replication for storage account's Blob, Table, Queue and File services. It is only available when geo-redundant replication is enabled for the storage account.
func (GeoReplicationStats) MarshalJSON ¶
func (g GeoReplicationStats) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type GeoReplicationStats.
func (*GeoReplicationStats) UnmarshalJSON ¶
func (g *GeoReplicationStats) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type GeoReplicationStats.
type GeoReplicationStatus ¶
type GeoReplicationStatus string
GeoReplicationStatus - The status of the secondary location. Possible values are: - Live: Indicates that the secondary location is active and operational. - Bootstrap: Indicates initial synchronization from the primary location to the secondary location is in progress.This typically occurs when replication is first enabled. - Unavailable: Indicates that the secondary location is temporarily unavailable.
const ( GeoReplicationStatusBootstrap GeoReplicationStatus = "Bootstrap" GeoReplicationStatusLive GeoReplicationStatus = "Live" )
func PossibleGeoReplicationStatusValues ¶
func PossibleGeoReplicationStatusValues() []GeoReplicationStatus
PossibleGeoReplicationStatusValues returns the possible values for the GeoReplicationStatus const type.
func (GeoReplicationStatus) ToPtr ¶
func (c GeoReplicationStatus) ToPtr() *GeoReplicationStatus
ToPtr returns a *GeoReplicationStatus pointing to the current value.
type HTTPProtocol ¶
type HTTPProtocol string
HTTPProtocol - The protocol permitted for a request made with the account SAS.
const ( HTTPProtocolHTTPSHTTP HTTPProtocol = "https,http" HTTPProtocolHTTPS HTTPProtocol = "https" )
func PossibleHTTPProtocolValues ¶
func PossibleHTTPProtocolValues() []HTTPProtocol
PossibleHTTPProtocolValues returns the possible values for the HTTPProtocol const type.
func (HTTPProtocol) ToPtr ¶
func (c HTTPProtocol) ToPtr() *HTTPProtocol
ToPtr returns a *HTTPProtocol pointing to the current value.
type IPRule ¶
type IPRule struct { // REQUIRED; Specifies the IP or IP range in CIDR format. Only IPV4 address is allowed. IPAddressOrRange *string `json:"value,omitempty"` // The action of IP ACL rule. Action *string `json:"action,omitempty"` }
IPRule - IP rule with specific IP or IP range in CIDR format.
type Identity ¶
type Identity struct { // REQUIRED; The identity type. Type *IdentityType `json:"type,omitempty"` // Gets or sets a list of key value pairs that describe the set of User Assigned identities that will be used with this storage // account. The key is the ARM resource identifier of the identity. Only 1 // User Assigned identity is permitted here. UserAssignedIdentities map[string]*UserAssignedIdentity `json:"userAssignedIdentities,omitempty"` // READ-ONLY; The principal ID of resource identity. PrincipalID *string `json:"principalId,omitempty" azure:"ro"` // READ-ONLY; The tenant ID of resource. TenantID *string `json:"tenantId,omitempty" azure:"ro"` }
Identity for the resource.
func (Identity) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Identity.
type IdentityType ¶
type IdentityType string
IdentityType - The identity type.
const ( IdentityTypeNone IdentityType = "None" IdentityTypeSystemAssigned IdentityType = "SystemAssigned" IdentityTypeSystemAssignedUserAssigned IdentityType = "SystemAssigned,UserAssigned" IdentityTypeUserAssigned IdentityType = "UserAssigned" )
func PossibleIdentityTypeValues ¶
func PossibleIdentityTypeValues() []IdentityType
PossibleIdentityTypeValues returns the possible values for the IdentityType const type.
func (IdentityType) ToPtr ¶
func (c IdentityType) ToPtr() *IdentityType
ToPtr returns a *IdentityType pointing to the current value.
type ImmutabilityPolicy ¶
type ImmutabilityPolicy struct { // REQUIRED; The properties of an ImmutabilityPolicy of a blob container. Properties *ImmutabilityPolicyProperty `json:"properties,omitempty"` // READ-ONLY; Resource Etag. Etag *string `json:"etag,omitempty" azure:"ro"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
ImmutabilityPolicy - The ImmutabilityPolicy property of a blob container, including Id, resource name, resource type, Etag.
type ImmutabilityPolicyProperties ¶
type ImmutabilityPolicyProperties struct { // The properties of an ImmutabilityPolicy of a blob container. Properties *ImmutabilityPolicyProperty `json:"properties,omitempty"` // READ-ONLY; ImmutabilityPolicy Etag. Etag *string `json:"etag,omitempty" azure:"ro"` // READ-ONLY; The ImmutabilityPolicy update history of the blob container. UpdateHistory []*UpdateHistoryProperty `json:"updateHistory,omitempty" azure:"ro"` }
ImmutabilityPolicyProperties - The properties of an ImmutabilityPolicy of a blob container.
func (ImmutabilityPolicyProperties) MarshalJSON ¶
func (i ImmutabilityPolicyProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ImmutabilityPolicyProperties.
type ImmutabilityPolicyProperty ¶
type ImmutabilityPolicyProperty struct { // This property can only be changed for unlocked time-based retention policies. When enabled, new blocks can be written to // an append blob while maintaining immutability protection and compliance. Only // new blocks can be added and any existing blocks cannot be modified or deleted. This property cannot be changed with ExtendImmutabilityPolicy // API. AllowProtectedAppendWrites *bool `json:"allowProtectedAppendWrites,omitempty"` // This property can only be changed for unlocked time-based retention policies. When enabled, new blocks can be written to // both 'Append and Bock Blobs' while maintaining immutability protection and // compliance. Only new blocks can be added and any existing blocks cannot be modified or deleted. This property cannot be // changed with ExtendImmutabilityPolicy API. The 'allowProtectedAppendWrites' and // 'allowProtectedAppendWritesAll' properties are mutually exclusive. AllowProtectedAppendWritesAll *bool `json:"allowProtectedAppendWritesAll,omitempty"` // The immutability period for the blobs in the container since the policy creation, in days. ImmutabilityPeriodSinceCreationInDays *int32 `json:"immutabilityPeriodSinceCreationInDays,omitempty"` // READ-ONLY; The ImmutabilityPolicy state of a blob container, possible values include: Locked and Unlocked. State *ImmutabilityPolicyState `json:"state,omitempty" azure:"ro"` }
ImmutabilityPolicyProperty - The properties of an ImmutabilityPolicy of a blob container.
type ImmutabilityPolicyState ¶
type ImmutabilityPolicyState string
ImmutabilityPolicyState - The ImmutabilityPolicy state of a blob container, possible values include: Locked and Unlocked.
const ( ImmutabilityPolicyStateLocked ImmutabilityPolicyState = "Locked" ImmutabilityPolicyStateUnlocked ImmutabilityPolicyState = "Unlocked" )
func PossibleImmutabilityPolicyStateValues ¶
func PossibleImmutabilityPolicyStateValues() []ImmutabilityPolicyState
PossibleImmutabilityPolicyStateValues returns the possible values for the ImmutabilityPolicyState const type.
func (ImmutabilityPolicyState) ToPtr ¶
func (c ImmutabilityPolicyState) ToPtr() *ImmutabilityPolicyState
ToPtr returns a *ImmutabilityPolicyState pointing to the current value.
type ImmutabilityPolicyUpdateType ¶
type ImmutabilityPolicyUpdateType string
ImmutabilityPolicyUpdateType - The ImmutabilityPolicy update type of a blob container, possible values include: put, lock and extend.
const ( ImmutabilityPolicyUpdateTypeExtend ImmutabilityPolicyUpdateType = "extend" ImmutabilityPolicyUpdateTypeLock ImmutabilityPolicyUpdateType = "lock" ImmutabilityPolicyUpdateTypePut ImmutabilityPolicyUpdateType = "put" )
func PossibleImmutabilityPolicyUpdateTypeValues ¶
func PossibleImmutabilityPolicyUpdateTypeValues() []ImmutabilityPolicyUpdateType
PossibleImmutabilityPolicyUpdateTypeValues returns the possible values for the ImmutabilityPolicyUpdateType const type.
func (ImmutabilityPolicyUpdateType) ToPtr ¶
func (c ImmutabilityPolicyUpdateType) ToPtr() *ImmutabilityPolicyUpdateType
ToPtr returns a *ImmutabilityPolicyUpdateType pointing to the current value.
type ImmutableStorageAccount ¶
type ImmutableStorageAccount struct { // A boolean flag which enables account-level immutability. All the containers under such an account have object-level immutability // enabled by default. Enabled *bool `json:"enabled,omitempty"` // Specifies the default account-level immutability policy which is inherited and applied to objects that do not possess an // explicit immutability policy at the object level. The object-level immutability // policy has higher precedence than the container-level immutability policy, which has a higher precedence than the account-level // immutability policy. ImmutabilityPolicy *AccountImmutabilityPolicyProperties `json:"immutabilityPolicy,omitempty"` }
ImmutableStorageAccount - This property enables and defines account-level immutability. Enabling the feature auto-enables Blob Versioning.
type ImmutableStorageWithVersioning ¶
type ImmutableStorageWithVersioning struct { // This is an immutable property, when set to true it enables object level immutability at the container level. Enabled *bool `json:"enabled,omitempty"` // READ-ONLY; This property denotes the container level immutability to object level immutability migration state. MigrationState *MigrationState `json:"migrationState,omitempty" azure:"ro"` // READ-ONLY; Returns the date and time the object level immutability was enabled. TimeStamp *time.Time `json:"timeStamp,omitempty" azure:"ro"` }
ImmutableStorageWithVersioning - Object level immutability properties of the container.
func (ImmutableStorageWithVersioning) MarshalJSON ¶
func (i ImmutableStorageWithVersioning) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ImmutableStorageWithVersioning.
func (*ImmutableStorageWithVersioning) UnmarshalJSON ¶
func (i *ImmutableStorageWithVersioning) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ImmutableStorageWithVersioning.
type InventoryRuleType ¶
type InventoryRuleType string
InventoryRuleType - The valid value is Inventory
const (
InventoryRuleTypeInventory InventoryRuleType = "Inventory"
)
func PossibleInventoryRuleTypeValues ¶
func PossibleInventoryRuleTypeValues() []InventoryRuleType
PossibleInventoryRuleTypeValues returns the possible values for the InventoryRuleType const type.
func (InventoryRuleType) ToPtr ¶
func (c InventoryRuleType) ToPtr() *InventoryRuleType
ToPtr returns a *InventoryRuleType pointing to the current value.
type KeyCreationTime ¶
type KeyCreationTime struct { Key1 *time.Time `json:"key1,omitempty"` Key2 *time.Time `json:"key2,omitempty"` }
KeyCreationTime - Storage account keys creation time.
func (KeyCreationTime) MarshalJSON ¶
func (k KeyCreationTime) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type KeyCreationTime.
func (*KeyCreationTime) UnmarshalJSON ¶
func (k *KeyCreationTime) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type KeyCreationTime.
type KeyPermission ¶
type KeyPermission string
KeyPermission - Permissions for the key -- read-only or full permissions.
const ( KeyPermissionRead KeyPermission = "Read" KeyPermissionFull KeyPermission = "Full" )
func PossibleKeyPermissionValues ¶
func PossibleKeyPermissionValues() []KeyPermission
PossibleKeyPermissionValues returns the possible values for the KeyPermission const type.
func (KeyPermission) ToPtr ¶
func (c KeyPermission) ToPtr() *KeyPermission
ToPtr returns a *KeyPermission pointing to the current value.
type KeyPolicy ¶
type KeyPolicy struct { // REQUIRED; The key expiration period in days. KeyExpirationPeriodInDays *int32 `json:"keyExpirationPeriodInDays,omitempty"` }
KeyPolicy assigned to the storage account.
type KeySource ¶
type KeySource string
KeySource - The encryption keySource (provider). Possible values (case-insensitive): Microsoft.Storage, Microsoft.Keyvault
func PossibleKeySourceValues ¶
func PossibleKeySourceValues() []KeySource
PossibleKeySourceValues returns the possible values for the KeySource const type.
type KeyType ¶
type KeyType string
KeyType - Encryption key type to be used for the encryption service. 'Account' key type implies that an account-scoped encryption key will be used. 'Service' key type implies that a default service key is used.
func PossibleKeyTypeValues ¶
func PossibleKeyTypeValues() []KeyType
PossibleKeyTypeValues returns the possible values for the KeyType const type.
type KeyVaultProperties ¶
type KeyVaultProperties struct { // The name of KeyVault key. KeyName *string `json:"keyname,omitempty"` // The Uri of KeyVault. KeyVaultURI *string `json:"keyvaulturi,omitempty"` // The version of KeyVault key. KeyVersion *string `json:"keyversion,omitempty"` // READ-ONLY; The object identifier of the current versioned Key Vault Key in use. CurrentVersionedKeyIdentifier *string `json:"currentVersionedKeyIdentifier,omitempty" azure:"ro"` // READ-ONLY; Timestamp of last rotation of the Key Vault Key. LastKeyRotationTimestamp *time.Time `json:"lastKeyRotationTimestamp,omitempty" azure:"ro"` }
KeyVaultProperties - Properties of key vault.
func (KeyVaultProperties) MarshalJSON ¶
func (k KeyVaultProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type KeyVaultProperties.
func (*KeyVaultProperties) UnmarshalJSON ¶
func (k *KeyVaultProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type KeyVaultProperties.
type Kind ¶
type Kind string
Kind - Indicates the type of storage account.
func PossibleKindValues ¶
func PossibleKindValues() []Kind
PossibleKindValues returns the possible values for the Kind const type.
type LargeFileSharesState ¶
type LargeFileSharesState string
LargeFileSharesState - Allow large file shares if sets to Enabled. It cannot be disabled once it is enabled.
const ()
func PossibleLargeFileSharesStateValues ¶
func PossibleLargeFileSharesStateValues() []LargeFileSharesState
PossibleLargeFileSharesStateValues returns the possible values for the LargeFileSharesState const type.
func (LargeFileSharesState) ToPtr ¶
func (c LargeFileSharesState) ToPtr() *LargeFileSharesState
ToPtr returns a *LargeFileSharesState pointing to the current value.
type LastAccessTimeTrackingPolicy ¶
type LastAccessTimeTrackingPolicy struct { // REQUIRED; When set to true last access time based tracking is enabled. Enable *bool `json:"enable,omitempty"` // An array of predefined supported blob types. Only blockBlob is the supported value. This field is currently read only BlobType []*string `json:"blobType,omitempty"` // Name of the policy. The valid value is AccessTimeTracking. This field is currently read only Name *Name `json:"name,omitempty"` // The field specifies blob object tracking granularity in days, typically how often the blob object should be tracked.This // field is currently read only with value as 1 TrackingGranularityInDays *int32 `json:"trackingGranularityInDays,omitempty"` }
LastAccessTimeTrackingPolicy - The blob service properties for Last access time based tracking policy.
func (LastAccessTimeTrackingPolicy) MarshalJSON ¶
func (l LastAccessTimeTrackingPolicy) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LastAccessTimeTrackingPolicy.
type LeaseContainerRequest ¶
type LeaseContainerRequest struct { // REQUIRED; Specifies the lease action. Can be one of the available actions. Action *LeaseContainerRequestAction `json:"action,omitempty"` // Optional. For a break action, proposed duration the lease should continue before it is broken, in seconds, between 0 and // 60. BreakPeriod *int32 `json:"breakPeriod,omitempty"` // Required for acquire. Specifies the duration of the lease, in seconds, or negative one (-1) for a lease that never expires. LeaseDuration *int32 `json:"leaseDuration,omitempty"` // Identifies the lease. Can be specified in any valid GUID string format. LeaseID *string `json:"leaseId,omitempty"` // Optional for acquire, required for change. Proposed lease ID, in a GUID string format. ProposedLeaseID *string `json:"proposedLeaseId,omitempty"` }
LeaseContainerRequest - Lease Container request schema.
type LeaseContainerRequestAction ¶
type LeaseContainerRequestAction string
LeaseContainerRequestAction - Specifies the lease action. Can be one of the available actions.
const ( LeaseContainerRequestActionAcquire LeaseContainerRequestAction = "Acquire" LeaseContainerRequestActionBreak LeaseContainerRequestAction = "Break" LeaseContainerRequestActionChange LeaseContainerRequestAction = "Change" LeaseContainerRequestActionRelease LeaseContainerRequestAction = "Release" LeaseContainerRequestActionRenew LeaseContainerRequestAction = "Renew" )
func PossibleLeaseContainerRequestActionValues ¶
func PossibleLeaseContainerRequestActionValues() []LeaseContainerRequestAction
PossibleLeaseContainerRequestActionValues returns the possible values for the LeaseContainerRequestAction const type.
func (LeaseContainerRequestAction) ToPtr ¶
func (c LeaseContainerRequestAction) ToPtr() *LeaseContainerRequestAction
ToPtr returns a *LeaseContainerRequestAction pointing to the current value.
type LeaseContainerResponse ¶
type LeaseContainerResponse struct { // Returned unique lease ID that must be included with any request to delete the container, or to renew, change, or release // the lease. LeaseID *string `json:"leaseId,omitempty"` // Approximate time remaining in the lease period, in seconds. LeaseTimeSeconds *string `json:"leaseTimeSeconds,omitempty"` }
LeaseContainerResponse - Lease Container response schema.
type LeaseDuration ¶
type LeaseDuration string
LeaseDuration - Specifies whether the lease on a container is of infinite or fixed duration, only when the container is leased.
const ( LeaseDurationFixed LeaseDuration = "Fixed" LeaseDurationInfinite LeaseDuration = "Infinite" )
func PossibleLeaseDurationValues ¶
func PossibleLeaseDurationValues() []LeaseDuration
PossibleLeaseDurationValues returns the possible values for the LeaseDuration const type.
func (LeaseDuration) ToPtr ¶
func (c LeaseDuration) ToPtr() *LeaseDuration
ToPtr returns a *LeaseDuration pointing to the current value.
type LeaseShareAction ¶
type LeaseShareAction string
LeaseShareAction - Specifies the lease action. Can be one of the available actions.
const ()
func PossibleLeaseShareActionValues ¶
func PossibleLeaseShareActionValues() []LeaseShareAction
PossibleLeaseShareActionValues returns the possible values for the LeaseShareAction const type.
func (LeaseShareAction) ToPtr ¶
func (c LeaseShareAction) ToPtr() *LeaseShareAction
ToPtr returns a *LeaseShareAction pointing to the current value.
type LeaseShareRequest ¶
type LeaseShareRequest struct { LeaseShareAction `json:"action,omitempty"` // 60. BreakPeriod *int32 `json:"breakPeriod,omitempty"` LeaseDuration *int32 `json:"leaseDuration,omitempty"` LeaseID *string `json:"leaseId,omitempty"` ProposedLeaseID *string `json:"proposedLeaseId,omitempty"` }Action *
LeaseShareRequest - Lease Share request schema.
type LeaseShareResponse ¶
type LeaseShareResponse struct { // lease. LeaseID *string `json:"leaseId,omitempty"` LeaseTimeSeconds *string `json:"leaseTimeSeconds,omitempty"` }
LeaseShareResponse - Lease Share response schema.
type LeaseState ¶
type LeaseState string
LeaseState - Lease state of the container.
const ( LeaseStateAvailable LeaseState = "Available" LeaseStateBreaking LeaseState = "Breaking" LeaseStateBroken LeaseState = "Broken" LeaseStateExpired LeaseState = "Expired" LeaseStateLeased LeaseState = "Leased" )
func PossibleLeaseStateValues ¶
func PossibleLeaseStateValues() []LeaseState
PossibleLeaseStateValues returns the possible values for the LeaseState const type.
func (LeaseState) ToPtr ¶
func (c LeaseState) ToPtr() *LeaseState
ToPtr returns a *LeaseState pointing to the current value.
type LeaseStatus ¶
type LeaseStatus string
LeaseStatus - The lease status of the container.
const ( LeaseStatusLocked LeaseStatus = "Locked" LeaseStatusUnlocked LeaseStatus = "Unlocked" )
func PossibleLeaseStatusValues ¶
func PossibleLeaseStatusValues() []LeaseStatus
PossibleLeaseStatusValues returns the possible values for the LeaseStatus const type.
func (LeaseStatus) ToPtr ¶
func (c LeaseStatus) ToPtr() *LeaseStatus
ToPtr returns a *LeaseStatus pointing to the current value.
type LegalHold ¶
type LegalHold struct { // REQUIRED; Each tag should be 3 to 23 alphanumeric characters and is normalized to lower case at SRP. Tags []*string `json:"tags,omitempty"` // When enabled, new blocks can be written to both 'Append and Bock Blobs' while maintaining legal hold protection and compliance. // Only new blocks can be added and any existing blocks cannot be modified // or deleted. AllowProtectedAppendWritesAll *bool `json:"allowProtectedAppendWritesAll,omitempty"` // READ-ONLY; The hasLegalHold public property is set to true by SRP if there are at least one existing tag. The hasLegalHold // public property is set to false by SRP if all existing legal hold tags are cleared out. // There can be a maximum of 1000 blob containers with hasLegalHold=true for a given account. HasLegalHold *bool `json:"hasLegalHold,omitempty" azure:"ro"` }
LegalHold - The LegalHold property of a blob container.
func (LegalHold) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type LegalHold.
type LegalHoldProperties ¶
type LegalHoldProperties struct { // Protected append blob writes history. ProtectedAppendWritesHistory *ProtectedAppendWritesHistory `json:"protectedAppendWritesHistory,omitempty"` // The list of LegalHold tags of a blob container. Tags []*TagProperty `json:"tags,omitempty"` // READ-ONLY; The hasLegalHold public property is set to true by SRP if there are at least one existing tag. The hasLegalHold // public property is set to false by SRP if all existing legal hold tags are cleared out. // There can be a maximum of 1000 blob containers with hasLegalHold=true for a given account. HasLegalHold *bool `json:"hasLegalHold,omitempty" azure:"ro"` }
LegalHoldProperties - The LegalHold property of a blob container.
func (LegalHoldProperties) MarshalJSON ¶
func (l LegalHoldProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LegalHoldProperties.
type ListAccountSasResponse ¶
type ListAccountSasResponse struct { // READ-ONLY; List SAS credentials of storage account. AccountSasToken *string `json:"accountSasToken,omitempty" azure:"ro"` }
ListAccountSasResponse - The List SAS credentials operation response.
type ListBlobInventoryPolicy ¶
type ListBlobInventoryPolicy struct { // READ-ONLY; List of blob inventory policies. Value []*BlobInventoryPolicy `json:"value,omitempty" azure:"ro"` }
ListBlobInventoryPolicy - List of blob inventory policies returned.
func (ListBlobInventoryPolicy) MarshalJSON ¶
func (l ListBlobInventoryPolicy) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ListBlobInventoryPolicy.
type ListContainerItem ¶
type ListContainerItem struct { // The blob container properties be listed out. Properties *ContainerProperties `json:"properties,omitempty"` // READ-ONLY; Resource Etag. Etag *string `json:"etag,omitempty" azure:"ro"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
ListContainerItem - The blob container properties be listed out.
type ListContainerItems ¶
type ListContainerItems struct { // READ-ONLY; Request URL that can be used to query next page of containers. Returned when total number of requested containers // exceed maximum page size. NextLink *string `json:"nextLink,omitempty" azure:"ro"` // READ-ONLY; List of blobs containers returned. Value []*ListContainerItem `json:"value,omitempty" azure:"ro"` }
ListContainerItems - Response schema. Contains list of blobs returned, and if paging is requested or required, a URL to next page of containers.
func (ListContainerItems) MarshalJSON ¶
func (l ListContainerItems) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ListContainerItems.
type ListContainersInclude ¶
type ListContainersInclude string
const (
ListContainersIncludeDeleted ListContainersInclude = "deleted"
)
func PossibleListContainersIncludeValues ¶
func PossibleListContainersIncludeValues() []ListContainersInclude
PossibleListContainersIncludeValues returns the possible values for the ListContainersInclude const type.
func (ListContainersInclude) ToPtr ¶
func (c ListContainersInclude) ToPtr() *ListContainersInclude
ToPtr returns a *ListContainersInclude pointing to the current value.
type ListQueue ¶
type ListQueue struct { // List Queue resource properties. QueueProperties *ListQueueProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
type ListQueueProperties ¶
type ListQueueProperties struct { // A name-value pair that represents queue metadata. Metadata map[string]*string `json:"metadata,omitempty"` }
func (ListQueueProperties) MarshalJSON ¶
func (l ListQueueProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ListQueueProperties.
type ListQueueResource ¶
type ListQueueResource struct { // READ-ONLY; Request URL that can be used to list next page of queues NextLink *string `json:"nextLink,omitempty" azure:"ro"` // READ-ONLY; List of queues returned. Value []*ListQueue `json:"value,omitempty" azure:"ro"` }
ListQueueResource - Response schema. Contains list of queues returned
func (ListQueueResource) MarshalJSON ¶
func (l ListQueueResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ListQueueResource.
type ListQueueServices ¶
type ListQueueServices struct { // READ-ONLY; List of queue services returned. Value []*QueueServiceProperties `json:"value,omitempty" azure:"ro"` }
func (ListQueueServices) MarshalJSON ¶
func (l ListQueueServices) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ListQueueServices.
type ListServiceSasResponse ¶
type ListServiceSasResponse struct { // READ-ONLY; List service SAS credentials of specific resource. ServiceSasToken *string `json:"serviceSasToken,omitempty" azure:"ro"` }
ListServiceSasResponse - The List service SAS credentials operation response.
type ListTableResource ¶
type ListTableResource struct { // READ-ONLY; Request URL that can be used to query next page of tables NextLink *string `json:"nextLink,omitempty" azure:"ro"` // READ-ONLY; List of tables returned. Value []*Table `json:"value,omitempty" azure:"ro"` }
ListTableResource - Response schema. Contains list of tables returned
func (ListTableResource) MarshalJSON ¶
func (l ListTableResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ListTableResource.
type ListTableServices ¶
type ListTableServices struct { // READ-ONLY; List of table services returned. Value []*TableServiceProperties `json:"value,omitempty" azure:"ro"` }
func (ListTableServices) MarshalJSON ¶
func (l ListTableServices) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ListTableServices.
type LocalUser ¶ added in v0.3.0
type LocalUser struct { // Storage account local user properties. Properties *LocalUserProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; Metadata pertaining to creation and last modification of the resource. SystemData *SystemData `json:"systemData,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
LocalUser - The local user associated with the storage accounts.
type LocalUserKeys ¶ added in v0.3.0
type LocalUserKeys struct { // Optional, local user ssh authorized keys for SFTP. SSHAuthorizedKeys []*SSHPublicKey `json:"sshAuthorizedKeys,omitempty"` SharedKey *string `json:"sharedKey,omitempty" azure:"ro"` }
LocalUserKeys - The Storage Account Local User keys.
func (LocalUserKeys) MarshalJSON ¶ added in v0.3.0
func (l LocalUserKeys) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LocalUserKeys.
type LocalUserProperties ¶ added in v0.3.0
type LocalUserProperties struct { // Indicates whether ssh key exists. Set it to false to remove existing SSH key. HasSSHKey *bool `json:"hasSshKey,omitempty"` // Indicates whether ssh password exists. Set it to false to remove existing SSH password. HasSSHPassword *bool `json:"hasSshPassword,omitempty"` HasSharedKey *bool `json:"hasSharedKey,omitempty"` // Optional, local user home directory. HomeDirectory *string `json:"homeDirectory,omitempty"` // The permission scopes of the local user. PermissionScopes []*PermissionScope `json:"permissionScopes,omitempty"` // Optional, local user ssh authorized keys for SFTP. SSHAuthorizedKeys []*SSHPublicKey `json:"sshAuthorizedKeys,omitempty"` // READ-ONLY; A unique Security Identifier that is generated by the server. Sid *string `json:"sid,omitempty" azure:"ro"` }
LocalUserProperties - The Storage Account Local User properties.
func (LocalUserProperties) MarshalJSON ¶ added in v0.3.0
func (l LocalUserProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LocalUserProperties.
type LocalUserRegeneratePasswordResult ¶ added in v0.3.0
type LocalUserRegeneratePasswordResult struct { // READ-ONLY; Auto generated password by the server for SSH authentication if hasSshPassword is set to true on the creation // of local user. SSHPassword *string `json:"sshPassword,omitempty" azure:"ro"` }
LocalUserRegeneratePasswordResult - The secrets of Storage Account Local User.
type LocalUsers ¶ added in v0.3.0
type LocalUsers struct { // The local users associated with the storage account. Value []*LocalUser `json:"value,omitempty"` }
LocalUsers - List storage account local users.
func (LocalUsers) MarshalJSON ¶ added in v0.3.0
func (l LocalUsers) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LocalUsers.
type LocalUsersClient ¶ added in v0.3.0
type LocalUsersClient struct {
// contains filtered or unexported fields
}
LocalUsersClient contains the methods for the LocalUsers group. Don't use this type directly, use NewLocalUsersClient() instead.
func NewLocalUsersClient ¶ added in v0.3.0
func NewLocalUsersClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *LocalUsersClient
NewLocalUsersClient creates a new instance of LocalUsersClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*LocalUsersClient) CreateOrUpdate ¶ added in v0.3.0
func (client *LocalUsersClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, accountName string, username string, properties LocalUser, options *LocalUsersClientCreateOrUpdateOptions) (LocalUsersClientCreateOrUpdateResponse, error)
CreateOrUpdate - Create or update the properties of a local user associated with the storage account If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. username - The name of local user. The username must contain lowercase letters and numbers only. It must be unique only within the storage account. properties - The local user associated with a storage account. options - LocalUsersClientCreateOrUpdateOptions contains the optional parameters for the LocalUsersClient.CreateOrUpdate method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/LocalUserCreate.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewLocalUsersClient("<subscription-id>", cred, nil) res, err := client.CreateOrUpdate(ctx, "<resource-group-name>", "<account-name>", "<username>", armstorage.LocalUser{ Properties: &armstorage.LocalUserProperties{ HasSSHPassword: to.BoolPtr(true), HomeDirectory: to.StringPtr("<home-directory>"), PermissionScopes: []*armstorage.PermissionScope{ { Permissions: to.StringPtr("<permissions>"), ResourceName: to.StringPtr("<resource-name>"), Service: to.StringPtr("<service>"), }, { Permissions: to.StringPtr("<permissions>"), ResourceName: to.StringPtr("<resource-name>"), Service: to.StringPtr("<service>"), }}, SSHAuthorizedKeys: []*armstorage.SSHPublicKey{ { Description: to.StringPtr("<description>"), Key: to.StringPtr("<key>"), }}, }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.LocalUsersClientCreateOrUpdateResult) }
Output:
func (*LocalUsersClient) Delete ¶ added in v0.3.0
func (client *LocalUsersClient) Delete(ctx context.Context, resourceGroupName string, accountName string, username string, options *LocalUsersClientDeleteOptions) (LocalUsersClientDeleteResponse, error)
Delete - Deletes the local user associated with the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. username - The name of local user. The username must contain lowercase letters and numbers only. It must be unique only within the storage account. options - LocalUsersClientDeleteOptions contains the optional parameters for the LocalUsersClient.Delete method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/LocalUserDelete.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewLocalUsersClient("<subscription-id>", cred, nil) _, err = client.Delete(ctx, "<resource-group-name>", "<account-name>", "<username>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*LocalUsersClient) Get ¶ added in v0.3.0
func (client *LocalUsersClient) Get(ctx context.Context, resourceGroupName string, accountName string, username string, options *LocalUsersClientGetOptions) (LocalUsersClientGetResponse, error)
Get - Get the local user of the storage account by username. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. username - The name of local user. The username must contain lowercase letters and numbers only. It must be unique only within the storage account. options - LocalUsersClientGetOptions contains the optional parameters for the LocalUsersClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/LocalUserGet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewLocalUsersClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<resource-group-name>", "<account-name>", "<username>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.LocalUsersClientGetResult) }
Output:
func (*LocalUsersClient) List ¶ added in v0.3.0
func (client *LocalUsersClient) List(ctx context.Context, resourceGroupName string, accountName string, options *LocalUsersClientListOptions) (LocalUsersClientListResponse, error)
List - List the local users associated with the storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - LocalUsersClientListOptions contains the optional parameters for the LocalUsersClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/LocalUsersList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewLocalUsersClient("<subscription-id>", cred, nil) res, err := client.List(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.LocalUsersClientListResult) }
Output:
func (*LocalUsersClient) ListKeys ¶ added in v0.3.0
func (client *LocalUsersClient) ListKeys(ctx context.Context, resourceGroupName string, accountName string, username string, options *LocalUsersClientListKeysOptions) (LocalUsersClientListKeysResponse, error)
ListKeys - List SSH authorized keys and shared key of the local user. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. username - The name of local user. The username must contain lowercase letters and numbers only. It must be unique only within the storage account. options - LocalUsersClientListKeysOptions contains the optional parameters for the LocalUsersClient.ListKeys method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/LocalUserListKeys.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewLocalUsersClient("<subscription-id>", cred, nil) res, err := client.ListKeys(ctx, "<resource-group-name>", "<account-name>", "<username>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.LocalUsersClientListKeysResult) }
Output:
func (*LocalUsersClient) RegeneratePassword ¶ added in v0.3.0
func (client *LocalUsersClient) RegeneratePassword(ctx context.Context, resourceGroupName string, accountName string, username string, options *LocalUsersClientRegeneratePasswordOptions) (LocalUsersClientRegeneratePasswordResponse, error)
RegeneratePassword - Regenerate the local user SSH password. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. username - The name of local user. The username must contain lowercase letters and numbers only. It must be unique only within the storage account. options - LocalUsersClientRegeneratePasswordOptions contains the optional parameters for the LocalUsersClient.RegeneratePassword method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/LocalUserRegeneratePassword.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewLocalUsersClient("<subscription-id>", cred, nil) res, err := client.RegeneratePassword(ctx, "<resource-group-name>", "<account-name>", "<username>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.LocalUsersClientRegeneratePasswordResult) }
Output:
type LocalUsersClientCreateOrUpdateOptions ¶ added in v0.3.0
type LocalUsersClientCreateOrUpdateOptions struct { }
LocalUsersClientCreateOrUpdateOptions contains the optional parameters for the LocalUsersClient.CreateOrUpdate method.
type LocalUsersClientCreateOrUpdateResponse ¶ added in v0.3.0
type LocalUsersClientCreateOrUpdateResponse struct { LocalUsersClientCreateOrUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
LocalUsersClientCreateOrUpdateResponse contains the response from method LocalUsersClient.CreateOrUpdate.
type LocalUsersClientCreateOrUpdateResult ¶ added in v0.3.0
type LocalUsersClientCreateOrUpdateResult struct {
LocalUser
}
LocalUsersClientCreateOrUpdateResult contains the result from method LocalUsersClient.CreateOrUpdate.
type LocalUsersClientDeleteOptions ¶ added in v0.3.0
type LocalUsersClientDeleteOptions struct { }
LocalUsersClientDeleteOptions contains the optional parameters for the LocalUsersClient.Delete method.
type LocalUsersClientDeleteResponse ¶ added in v0.3.0
type LocalUsersClientDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
LocalUsersClientDeleteResponse contains the response from method LocalUsersClient.Delete.
type LocalUsersClientGetOptions ¶ added in v0.3.0
type LocalUsersClientGetOptions struct { }
LocalUsersClientGetOptions contains the optional parameters for the LocalUsersClient.Get method.
type LocalUsersClientGetResponse ¶ added in v0.3.0
type LocalUsersClientGetResponse struct { LocalUsersClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
LocalUsersClientGetResponse contains the response from method LocalUsersClient.Get.
type LocalUsersClientGetResult ¶ added in v0.3.0
type LocalUsersClientGetResult struct {
LocalUser
}
LocalUsersClientGetResult contains the result from method LocalUsersClient.Get.
type LocalUsersClientListKeysOptions ¶ added in v0.3.0
type LocalUsersClientListKeysOptions struct { }
LocalUsersClientListKeysOptions contains the optional parameters for the LocalUsersClient.ListKeys method.
type LocalUsersClientListKeysResponse ¶ added in v0.3.0
type LocalUsersClientListKeysResponse struct { LocalUsersClientListKeysResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
LocalUsersClientListKeysResponse contains the response from method LocalUsersClient.ListKeys.
type LocalUsersClientListKeysResult ¶ added in v0.3.0
type LocalUsersClientListKeysResult struct {
LocalUserKeys
}
LocalUsersClientListKeysResult contains the result from method LocalUsersClient.ListKeys.
type LocalUsersClientListOptions ¶ added in v0.3.0
type LocalUsersClientListOptions struct { }
LocalUsersClientListOptions contains the optional parameters for the LocalUsersClient.List method.
type LocalUsersClientListResponse ¶ added in v0.3.0
type LocalUsersClientListResponse struct { LocalUsersClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
LocalUsersClientListResponse contains the response from method LocalUsersClient.List.
type LocalUsersClientListResult ¶ added in v0.3.0
type LocalUsersClientListResult struct {
LocalUsers
}
LocalUsersClientListResult contains the result from method LocalUsersClient.List.
type LocalUsersClientRegeneratePasswordOptions ¶ added in v0.3.0
type LocalUsersClientRegeneratePasswordOptions struct { }
LocalUsersClientRegeneratePasswordOptions contains the optional parameters for the LocalUsersClient.RegeneratePassword method.
type LocalUsersClientRegeneratePasswordResponse ¶ added in v0.3.0
type LocalUsersClientRegeneratePasswordResponse struct { LocalUsersClientRegeneratePasswordResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
LocalUsersClientRegeneratePasswordResponse contains the response from method LocalUsersClient.RegeneratePassword.
type LocalUsersClientRegeneratePasswordResult ¶ added in v0.3.0
type LocalUsersClientRegeneratePasswordResult struct {
LocalUserRegeneratePasswordResult
}
LocalUsersClientRegeneratePasswordResult contains the result from method LocalUsersClient.RegeneratePassword.
type ManagementPoliciesClient ¶
type ManagementPoliciesClient struct {
// contains filtered or unexported fields
}
ManagementPoliciesClient contains the methods for the ManagementPolicies group. Don't use this type directly, use NewManagementPoliciesClient() instead.
func NewManagementPoliciesClient ¶
func NewManagementPoliciesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *ManagementPoliciesClient
NewManagementPoliciesClient creates a new instance of ManagementPoliciesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*ManagementPoliciesClient) CreateOrUpdate ¶
func (client *ManagementPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, accountName string, managementPolicyName ManagementPolicyName, properties ManagementPolicy, options *ManagementPoliciesClientCreateOrUpdateOptions) (ManagementPoliciesClientCreateOrUpdateResponse, error)
CreateOrUpdate - Sets the managementpolicy to the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. managementPolicyName - The name of the Storage Account Management Policy. It should always be 'default' properties - The ManagementPolicy set to a storage account. options - ManagementPoliciesClientCreateOrUpdateOptions contains the optional parameters for the ManagementPoliciesClient.CreateOrUpdate method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountSetManagementPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewManagementPoliciesClient("<subscription-id>", cred, nil) res, err := client.CreateOrUpdate(ctx, "<resource-group-name>", "<account-name>", armstorage.ManagementPolicyName("default"), armstorage.ManagementPolicy{ Properties: &armstorage.ManagementPolicyProperties{ Policy: &armstorage.ManagementPolicySchema{ Rules: []*armstorage.ManagementPolicyRule{ { Name: to.StringPtr("<name>"), Type: armstorage.RuleType("Lifecycle").ToPtr(), Definition: &armstorage.ManagementPolicyDefinition{ Actions: &armstorage.ManagementPolicyAction{ BaseBlob: &armstorage.ManagementPolicyBaseBlob{ Delete: &armstorage.DateAfterModification{ DaysAfterModificationGreaterThan: to.Float32Ptr(1000), }, TierToArchive: &armstorage.DateAfterModification{ DaysAfterModificationGreaterThan: to.Float32Ptr(90), }, TierToCool: &armstorage.DateAfterModification{ DaysAfterModificationGreaterThan: to.Float32Ptr(30), }, }, Snapshot: &armstorage.ManagementPolicySnapShot{ Delete: &armstorage.DateAfterCreation{ DaysAfterCreationGreaterThan: to.Float32Ptr(30), }, }, }, Filters: &armstorage.ManagementPolicyFilter{ BlobTypes: []*string{ to.StringPtr("blockBlob")}, PrefixMatch: []*string{ to.StringPtr("olcmtestcontainer1")}, }, }, Enabled: to.BoolPtr(true), }, { Name: to.StringPtr("<name>"), Type: armstorage.RuleType("Lifecycle").ToPtr(), Definition: &armstorage.ManagementPolicyDefinition{ Actions: &armstorage.ManagementPolicyAction{ BaseBlob: &armstorage.ManagementPolicyBaseBlob{ Delete: &armstorage.DateAfterModification{ DaysAfterModificationGreaterThan: to.Float32Ptr(1000), }, TierToArchive: &armstorage.DateAfterModification{ DaysAfterModificationGreaterThan: to.Float32Ptr(90), }, TierToCool: &armstorage.DateAfterModification{ DaysAfterModificationGreaterThan: to.Float32Ptr(30), }, }, }, Filters: &armstorage.ManagementPolicyFilter{ BlobIndexMatch: []*armstorage.TagFilter{ { Name: to.StringPtr("<name>"), Op: to.StringPtr("<op>"), Value: to.StringPtr("<value>"), }, { Name: to.StringPtr("<name>"), Op: to.StringPtr("<op>"), Value: to.StringPtr("<value>"), }}, BlobTypes: []*string{ to.StringPtr("blockBlob")}, PrefixMatch: []*string{ to.StringPtr("olcmtestcontainer2")}, }, }, Enabled: to.BoolPtr(true), }}, }, }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.ManagementPoliciesClientCreateOrUpdateResult) }
Output:
func (*ManagementPoliciesClient) Delete ¶
func (client *ManagementPoliciesClient) Delete(ctx context.Context, resourceGroupName string, accountName string, managementPolicyName ManagementPolicyName, options *ManagementPoliciesClientDeleteOptions) (ManagementPoliciesClientDeleteResponse, error)
Delete - Deletes the managementpolicy associated with the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. managementPolicyName - The name of the Storage Account Management Policy. It should always be 'default' options - ManagementPoliciesClientDeleteOptions contains the optional parameters for the ManagementPoliciesClient.Delete method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountDeleteManagementPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewManagementPoliciesClient("<subscription-id>", cred, nil) _, err = client.Delete(ctx, "<resource-group-name>", "<account-name>", armstorage.ManagementPolicyName("default"), nil) if err != nil { log.Fatal(err) } }
Output:
func (*ManagementPoliciesClient) Get ¶
func (client *ManagementPoliciesClient) Get(ctx context.Context, resourceGroupName string, accountName string, managementPolicyName ManagementPolicyName, options *ManagementPoliciesClientGetOptions) (ManagementPoliciesClientGetResponse, error)
Get - Gets the managementpolicy associated with the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. managementPolicyName - The name of the Storage Account Management Policy. It should always be 'default' options - ManagementPoliciesClientGetOptions contains the optional parameters for the ManagementPoliciesClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountGetManagementPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewManagementPoliciesClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<resource-group-name>", "<account-name>", armstorage.ManagementPolicyName("default"), nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.ManagementPoliciesClientGetResult) }
Output:
type ManagementPoliciesClientCreateOrUpdateOptions ¶ added in v0.3.0
type ManagementPoliciesClientCreateOrUpdateOptions struct { }
ManagementPoliciesClientCreateOrUpdateOptions contains the optional parameters for the ManagementPoliciesClient.CreateOrUpdate method.
type ManagementPoliciesClientCreateOrUpdateResponse ¶ added in v0.3.0
type ManagementPoliciesClientCreateOrUpdateResponse struct { ManagementPoliciesClientCreateOrUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
ManagementPoliciesClientCreateOrUpdateResponse contains the response from method ManagementPoliciesClient.CreateOrUpdate.
type ManagementPoliciesClientCreateOrUpdateResult ¶ added in v0.3.0
type ManagementPoliciesClientCreateOrUpdateResult struct {
ManagementPolicy
}
ManagementPoliciesClientCreateOrUpdateResult contains the result from method ManagementPoliciesClient.CreateOrUpdate.
type ManagementPoliciesClientDeleteOptions ¶ added in v0.3.0
type ManagementPoliciesClientDeleteOptions struct { }
ManagementPoliciesClientDeleteOptions contains the optional parameters for the ManagementPoliciesClient.Delete method.
type ManagementPoliciesClientDeleteResponse ¶ added in v0.3.0
type ManagementPoliciesClientDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
ManagementPoliciesClientDeleteResponse contains the response from method ManagementPoliciesClient.Delete.
type ManagementPoliciesClientGetOptions ¶ added in v0.3.0
type ManagementPoliciesClientGetOptions struct { }
ManagementPoliciesClientGetOptions contains the optional parameters for the ManagementPoliciesClient.Get method.
type ManagementPoliciesClientGetResponse ¶ added in v0.3.0
type ManagementPoliciesClientGetResponse struct { ManagementPoliciesClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
ManagementPoliciesClientGetResponse contains the response from method ManagementPoliciesClient.Get.
type ManagementPoliciesClientGetResult ¶ added in v0.3.0
type ManagementPoliciesClientGetResult struct {
ManagementPolicy
}
ManagementPoliciesClientGetResult contains the result from method ManagementPoliciesClient.Get.
type ManagementPolicy ¶
type ManagementPolicy struct { // Returns the Storage Account Data Policies Rules. Properties *ManagementPolicyProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
ManagementPolicy - The Get Storage Account ManagementPolicies operation response.
type ManagementPolicyAction ¶
type ManagementPolicyAction struct { // The management policy action for base blob BaseBlob *ManagementPolicyBaseBlob `json:"baseBlob,omitempty"` // The management policy action for snapshot Snapshot *ManagementPolicySnapShot `json:"snapshot,omitempty"` // The management policy action for version Version *ManagementPolicyVersion `json:"version,omitempty"` }
ManagementPolicyAction - Actions are applied to the filtered blobs when the execution condition is met.
type ManagementPolicyBaseBlob ¶
type ManagementPolicyBaseBlob struct { // The function to delete the blob Delete *DateAfterModification `json:"delete,omitempty"` // This property enables auto tiering of a blob from cool to hot on a blob access. This property requires tierToCool.daysAfterLastAccessTimeGreaterThan. EnableAutoTierToHotFromCool *bool `json:"enableAutoTierToHotFromCool,omitempty"` // The function to tier blobs to archive storage. Support blobs currently at Hot or Cool tier TierToArchive *DateAfterModification `json:"tierToArchive,omitempty"` // The function to tier blobs to cool storage. Support blobs currently at Hot tier TierToCool *DateAfterModification `json:"tierToCool,omitempty"` }
ManagementPolicyBaseBlob - Management policy action for base blob.
type ManagementPolicyDefinition ¶
type ManagementPolicyDefinition struct { // REQUIRED; An object that defines the action set. Actions *ManagementPolicyAction `json:"actions,omitempty"` // An object that defines the filter set. Filters *ManagementPolicyFilter `json:"filters,omitempty"` }
ManagementPolicyDefinition - An object that defines the Lifecycle rule. Each definition is made up with a filters set and an actions set.
type ManagementPolicyFilter ¶
type ManagementPolicyFilter struct { // REQUIRED; An array of predefined enum values. Currently blockBlob supports all tiering and delete actions. Only delete // actions are supported for appendBlob. BlobTypes []*string `json:"blobTypes,omitempty"` // An array of blob index tag based filters, there can be at most 10 tag filters BlobIndexMatch []*TagFilter `json:"blobIndexMatch,omitempty"` // An array of strings for prefixes to be match. PrefixMatch []*string `json:"prefixMatch,omitempty"` }
ManagementPolicyFilter - Filters limit rule actions to a subset of blobs within the storage account. If multiple filters are defined, a logical AND is performed on all filters.
func (ManagementPolicyFilter) MarshalJSON ¶
func (m ManagementPolicyFilter) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagementPolicyFilter.
type ManagementPolicyName ¶
type ManagementPolicyName string
const (
ManagementPolicyNameDefault ManagementPolicyName = "default"
)
func PossibleManagementPolicyNameValues ¶
func PossibleManagementPolicyNameValues() []ManagementPolicyName
PossibleManagementPolicyNameValues returns the possible values for the ManagementPolicyName const type.
func (ManagementPolicyName) ToPtr ¶
func (c ManagementPolicyName) ToPtr() *ManagementPolicyName
ToPtr returns a *ManagementPolicyName pointing to the current value.
type ManagementPolicyProperties ¶
type ManagementPolicyProperties struct { // REQUIRED; The Storage Account ManagementPolicy, in JSON format. See more details in: https://docs.microsoft.com/en-us/azure/storage/common/storage-lifecycle-managment-concepts. Policy *ManagementPolicySchema `json:"policy,omitempty"` // READ-ONLY; Returns the date and time the ManagementPolicies was last modified. LastModifiedTime *time.Time `json:"lastModifiedTime,omitempty" azure:"ro"` }
ManagementPolicyProperties - The Storage Account ManagementPolicy properties.
func (ManagementPolicyProperties) MarshalJSON ¶
func (m ManagementPolicyProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagementPolicyProperties.
func (*ManagementPolicyProperties) UnmarshalJSON ¶
func (m *ManagementPolicyProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ManagementPolicyProperties.
type ManagementPolicyRule ¶
type ManagementPolicyRule struct { // REQUIRED; An object that defines the Lifecycle rule. Definition *ManagementPolicyDefinition `json:"definition,omitempty"` // REQUIRED; A rule name can contain any combination of alpha numeric characters. Rule name is case-sensitive. It must be // unique within a policy. Name *string `json:"name,omitempty"` // REQUIRED; The valid value is Lifecycle Type *RuleType `json:"type,omitempty"` // Rule is enabled if set to true. Enabled *bool `json:"enabled,omitempty"` }
ManagementPolicyRule - An object that wraps the Lifecycle rule. Each rule is uniquely defined by name.
type ManagementPolicySchema ¶
type ManagementPolicySchema struct { // REQUIRED; The Storage Account ManagementPolicies Rules. See more details in: https://docs.microsoft.com/en-us/azure/storage/common/storage-lifecycle-managment-concepts. Rules []*ManagementPolicyRule `json:"rules,omitempty"` }
ManagementPolicySchema - The Storage Account ManagementPolicies Rules. See more details in: https://docs.microsoft.com/en-us/azure/storage/common/storage-lifecycle-managment-concepts.
func (ManagementPolicySchema) MarshalJSON ¶
func (m ManagementPolicySchema) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagementPolicySchema.
type ManagementPolicySnapShot ¶
type ManagementPolicySnapShot struct { // The function to delete the blob snapshot Delete *DateAfterCreation `json:"delete,omitempty"` // The function to tier blob snapshot to archive storage. Support blob snapshot currently at Hot or Cool tier TierToArchive *DateAfterCreation `json:"tierToArchive,omitempty"` // The function to tier blob snapshot to cool storage. Support blob snapshot currently at Hot tier TierToCool *DateAfterCreation `json:"tierToCool,omitempty"` }
ManagementPolicySnapShot - Management policy action for snapshot.
type ManagementPolicyVersion ¶
type ManagementPolicyVersion struct { // The function to delete the blob version Delete *DateAfterCreation `json:"delete,omitempty"` // The function to tier blob version to archive storage. Support blob version currently at Hot or Cool tier TierToArchive *DateAfterCreation `json:"tierToArchive,omitempty"` // The function to tier blob version to cool storage. Support blob version currently at Hot tier TierToCool *DateAfterCreation `json:"tierToCool,omitempty"` }
ManagementPolicyVersion - Management policy action for blob version.
type MetricSpecification ¶
type MetricSpecification struct { // Aggregation type could be Average. AggregationType *string `json:"aggregationType,omitempty"` // The category this metric specification belong to, could be Capacity. Category *string `json:"category,omitempty"` // Dimensions of blobs, including blob type and access tier. Dimensions []*Dimension `json:"dimensions,omitempty"` // Display description of metric specification. DisplayDescription *string `json:"displayDescription,omitempty"` // Display name of metric specification. DisplayName *string `json:"displayName,omitempty"` // The property to decide fill gap with zero or not. FillGapWithZero *bool `json:"fillGapWithZero,omitempty"` // Name of metric specification. Name *string `json:"name,omitempty"` // Account Resource Id. ResourceIDDimensionNameOverride *string `json:"resourceIdDimensionNameOverride,omitempty"` // Unit could be Bytes or Count. Unit *string `json:"unit,omitempty"` }
MetricSpecification - Metric specification of operation.
func (MetricSpecification) MarshalJSON ¶
func (m MetricSpecification) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MetricSpecification.
type MigrationState ¶
type MigrationState string
MigrationState - This property denotes the container level immutability to object level immutability migration state.
const ( MigrationStateCompleted MigrationState = "Completed" MigrationStateInProgress MigrationState = "InProgress" )
func PossibleMigrationStateValues ¶
func PossibleMigrationStateValues() []MigrationState
PossibleMigrationStateValues returns the possible values for the MigrationState const type.
func (MigrationState) ToPtr ¶
func (c MigrationState) ToPtr() *MigrationState
ToPtr returns a *MigrationState pointing to the current value.
type MinimumTLSVersion ¶
type MinimumTLSVersion string
MinimumTLSVersion - Set the minimum TLS version to be permitted on requests to storage. The default interpretation is TLS 1.0 for this property.
const ( MinimumTLSVersionTLS10 MinimumTLSVersion = "TLS1_0" MinimumTLSVersionTLS11 MinimumTLSVersion = "TLS1_1" MinimumTLSVersionTLS12 MinimumTLSVersion = "TLS1_2" )
func PossibleMinimumTLSVersionValues ¶
func PossibleMinimumTLSVersionValues() []MinimumTLSVersion
PossibleMinimumTLSVersionValues returns the possible values for the MinimumTLSVersion const type.
func (MinimumTLSVersion) ToPtr ¶
func (c MinimumTLSVersion) ToPtr() *MinimumTLSVersion
ToPtr returns a *MinimumTLSVersion pointing to the current value.
type Multichannel ¶
type Multichannel struct { // Indicates whether multichannel is enabled Enabled *bool `json:"enabled,omitempty"` }
Multichannel setting. Applies to Premium FileStorage only.
type Name ¶
type Name string
Name - Name of the policy. The valid value is AccessTimeTracking. This field is currently read only
const (
NameAccessTimeTracking Name = "AccessTimeTracking"
)
func PossibleNameValues ¶
func PossibleNameValues() []Name
PossibleNameValues returns the possible values for the Name const type.
type NetworkRuleSet ¶
type NetworkRuleSet struct { // REQUIRED; Specifies the default action of allow or deny when no other rules match. DefaultAction *DefaultAction `json:"defaultAction,omitempty"` // Specifies whether traffic is bypassed for Logging/Metrics/AzureServices. Possible values are any combination of Logging|Metrics|AzureServices // (For example, "Logging, Metrics"), or None to bypass none // of those traffics. Bypass *Bypass `json:"bypass,omitempty"` // Sets the IP ACL rules IPRules []*IPRule `json:"ipRules,omitempty"` // Sets the resource access rules ResourceAccessRules []*ResourceAccessRule `json:"resourceAccessRules,omitempty"` // Sets the virtual network rules VirtualNetworkRules []*VirtualNetworkRule `json:"virtualNetworkRules,omitempty"` }
NetworkRuleSet - Network rule set
func (NetworkRuleSet) MarshalJSON ¶
func (n NetworkRuleSet) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NetworkRuleSet.
type ObjectReplicationPolicies ¶
type ObjectReplicationPolicies struct { // The replication policy between two storage accounts. Value []*ObjectReplicationPolicy `json:"value,omitempty"` }
ObjectReplicationPolicies - List storage account object replication policies.
func (ObjectReplicationPolicies) MarshalJSON ¶
func (o ObjectReplicationPolicies) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ObjectReplicationPolicies.
type ObjectReplicationPoliciesClient ¶
type ObjectReplicationPoliciesClient struct {
// contains filtered or unexported fields
}
ObjectReplicationPoliciesClient contains the methods for the ObjectReplicationPolicies group. Don't use this type directly, use NewObjectReplicationPoliciesClient() instead.
func NewObjectReplicationPoliciesClient ¶
func NewObjectReplicationPoliciesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *ObjectReplicationPoliciesClient
NewObjectReplicationPoliciesClient creates a new instance of ObjectReplicationPoliciesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*ObjectReplicationPoliciesClient) CreateOrUpdate ¶
func (client *ObjectReplicationPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, accountName string, objectReplicationPolicyID string, properties ObjectReplicationPolicy, options *ObjectReplicationPoliciesClientCreateOrUpdateOptions) (ObjectReplicationPoliciesClientCreateOrUpdateResponse, error)
CreateOrUpdate - Create or update the object replication policy of the storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. objectReplicationPolicyID - For the destination account, provide the value 'default'. Configure the policy on the destination account first. For the source account, provide the value of the policy ID that is returned when you download the policy that was defined on the destination account. The policy is downloaded as a JSON file. properties - The object replication policy set to a storage account. A unique policy ID will be created if absent. options - ObjectReplicationPoliciesClientCreateOrUpdateOptions contains the optional parameters for the ObjectReplicationPoliciesClient.CreateOrUpdate method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountCreateObjectReplicationPolicyOnDestination.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewObjectReplicationPoliciesClient("<subscription-id>", cred, nil) res, err := client.CreateOrUpdate(ctx, "<resource-group-name>", "<account-name>", "<object-replication-policy-id>", armstorage.ObjectReplicationPolicy{ Properties: &armstorage.ObjectReplicationPolicyProperties{ DestinationAccount: to.StringPtr("<destination-account>"), Rules: []*armstorage.ObjectReplicationPolicyRule{ { DestinationContainer: to.StringPtr("<destination-container>"), Filters: &armstorage.ObjectReplicationPolicyFilter{ PrefixMatch: []*string{ to.StringPtr("blobA"), to.StringPtr("blobB")}, }, SourceContainer: to.StringPtr("<source-container>"), }}, SourceAccount: to.StringPtr("<source-account>"), }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.ObjectReplicationPoliciesClientCreateOrUpdateResult) }
Output:
func (*ObjectReplicationPoliciesClient) Delete ¶
func (client *ObjectReplicationPoliciesClient) Delete(ctx context.Context, resourceGroupName string, accountName string, objectReplicationPolicyID string, options *ObjectReplicationPoliciesClientDeleteOptions) (ObjectReplicationPoliciesClientDeleteResponse, error)
Delete - Deletes the object replication policy associated with the specified storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. objectReplicationPolicyID - For the destination account, provide the value 'default'. Configure the policy on the destination account first. For the source account, provide the value of the policy ID that is returned when you download the policy that was defined on the destination account. The policy is downloaded as a JSON file. options - ObjectReplicationPoliciesClientDeleteOptions contains the optional parameters for the ObjectReplicationPoliciesClient.Delete method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountDeleteObjectReplicationPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewObjectReplicationPoliciesClient("<subscription-id>", cred, nil) _, err = client.Delete(ctx, "<resource-group-name>", "<account-name>", "<object-replication-policy-id>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*ObjectReplicationPoliciesClient) Get ¶
func (client *ObjectReplicationPoliciesClient) Get(ctx context.Context, resourceGroupName string, accountName string, objectReplicationPolicyID string, options *ObjectReplicationPoliciesClientGetOptions) (ObjectReplicationPoliciesClientGetResponse, error)
Get - Get the object replication policy of the storage account by policy ID. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. objectReplicationPolicyID - For the destination account, provide the value 'default'. Configure the policy on the destination account first. For the source account, provide the value of the policy ID that is returned when you download the policy that was defined on the destination account. The policy is downloaded as a JSON file. options - ObjectReplicationPoliciesClientGetOptions contains the optional parameters for the ObjectReplicationPoliciesClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountGetObjectReplicationPolicy.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewObjectReplicationPoliciesClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<resource-group-name>", "<account-name>", "<object-replication-policy-id>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.ObjectReplicationPoliciesClientGetResult) }
Output:
func (*ObjectReplicationPoliciesClient) List ¶
func (client *ObjectReplicationPoliciesClient) List(ctx context.Context, resourceGroupName string, accountName string, options *ObjectReplicationPoliciesClientListOptions) (ObjectReplicationPoliciesClientListResponse, error)
List - List the object replication policies associated with the storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - ObjectReplicationPoliciesClientListOptions contains the optional parameters for the ObjectReplicationPoliciesClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountListObjectReplicationPolicies.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewObjectReplicationPoliciesClient("<subscription-id>", cred, nil) res, err := client.List(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.ObjectReplicationPoliciesClientListResult) }
Output:
type ObjectReplicationPoliciesClientCreateOrUpdateOptions ¶ added in v0.3.0
type ObjectReplicationPoliciesClientCreateOrUpdateOptions struct { }
ObjectReplicationPoliciesClientCreateOrUpdateOptions contains the optional parameters for the ObjectReplicationPoliciesClient.CreateOrUpdate method.
type ObjectReplicationPoliciesClientCreateOrUpdateResponse ¶ added in v0.3.0
type ObjectReplicationPoliciesClientCreateOrUpdateResponse struct { ObjectReplicationPoliciesClientCreateOrUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
ObjectReplicationPoliciesClientCreateOrUpdateResponse contains the response from method ObjectReplicationPoliciesClient.CreateOrUpdate.
type ObjectReplicationPoliciesClientCreateOrUpdateResult ¶ added in v0.3.0
type ObjectReplicationPoliciesClientCreateOrUpdateResult struct {
ObjectReplicationPolicy
}
ObjectReplicationPoliciesClientCreateOrUpdateResult contains the result from method ObjectReplicationPoliciesClient.CreateOrUpdate.
type ObjectReplicationPoliciesClientDeleteOptions ¶ added in v0.3.0
type ObjectReplicationPoliciesClientDeleteOptions struct { }
ObjectReplicationPoliciesClientDeleteOptions contains the optional parameters for the ObjectReplicationPoliciesClient.Delete method.
type ObjectReplicationPoliciesClientDeleteResponse ¶ added in v0.3.0
type ObjectReplicationPoliciesClientDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
ObjectReplicationPoliciesClientDeleteResponse contains the response from method ObjectReplicationPoliciesClient.Delete.
type ObjectReplicationPoliciesClientGetOptions ¶ added in v0.3.0
type ObjectReplicationPoliciesClientGetOptions struct { }
ObjectReplicationPoliciesClientGetOptions contains the optional parameters for the ObjectReplicationPoliciesClient.Get method.
type ObjectReplicationPoliciesClientGetResponse ¶ added in v0.3.0
type ObjectReplicationPoliciesClientGetResponse struct { ObjectReplicationPoliciesClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
ObjectReplicationPoliciesClientGetResponse contains the response from method ObjectReplicationPoliciesClient.Get.
type ObjectReplicationPoliciesClientGetResult ¶ added in v0.3.0
type ObjectReplicationPoliciesClientGetResult struct {
ObjectReplicationPolicy
}
ObjectReplicationPoliciesClientGetResult contains the result from method ObjectReplicationPoliciesClient.Get.
type ObjectReplicationPoliciesClientListOptions ¶ added in v0.3.0
type ObjectReplicationPoliciesClientListOptions struct { }
ObjectReplicationPoliciesClientListOptions contains the optional parameters for the ObjectReplicationPoliciesClient.List method.
type ObjectReplicationPoliciesClientListResponse ¶ added in v0.3.0
type ObjectReplicationPoliciesClientListResponse struct { ObjectReplicationPoliciesClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
ObjectReplicationPoliciesClientListResponse contains the response from method ObjectReplicationPoliciesClient.List.
type ObjectReplicationPoliciesClientListResult ¶ added in v0.3.0
type ObjectReplicationPoliciesClientListResult struct {
ObjectReplicationPolicies
}
ObjectReplicationPoliciesClientListResult contains the result from method ObjectReplicationPoliciesClient.List.
type ObjectReplicationPolicy ¶
type ObjectReplicationPolicy struct { // Returns the Storage Account Object Replication Policy. Properties *ObjectReplicationPolicyProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
ObjectReplicationPolicy - The replication policy between two storage accounts. Multiple rules can be defined in one policy.
type ObjectReplicationPolicyFilter ¶
type ObjectReplicationPolicyFilter struct { // Blobs created after the time will be replicated to the destination. It must be in datetime format 'yyyy-MM-ddTHH:mm:ssZ'. // Example: 2020-02-19T16:05:00Z MinCreationTime *string `json:"minCreationTime,omitempty"` // Optional. Filters the results to replicate only blobs whose names begin with the specified prefix. PrefixMatch []*string `json:"prefixMatch,omitempty"` }
ObjectReplicationPolicyFilter - Filters limit replication to a subset of blobs within the storage account. A logical OR is performed on values in the filter. If multiple filters are defined, a logical AND is performed on all filters.
func (ObjectReplicationPolicyFilter) MarshalJSON ¶
func (o ObjectReplicationPolicyFilter) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ObjectReplicationPolicyFilter.
type ObjectReplicationPolicyProperties ¶
type ObjectReplicationPolicyProperties struct { // REQUIRED; Required. Destination account name. It should be full resource id if allowCrossTenantReplication set to false. DestinationAccount *string `json:"destinationAccount,omitempty"` // REQUIRED; Required. Source account name. It should be full resource id if allowCrossTenantReplication set to false. SourceAccount *string `json:"sourceAccount,omitempty"` // The storage account object replication rules. Rules []*ObjectReplicationPolicyRule `json:"rules,omitempty"` // READ-ONLY; Indicates when the policy is enabled on the source account. EnabledTime *time.Time `json:"enabledTime,omitempty" azure:"ro"` // READ-ONLY; A unique id for object replication policy. PolicyID *string `json:"policyId,omitempty" azure:"ro"` }
ObjectReplicationPolicyProperties - The Storage Account ObjectReplicationPolicy properties.
func (ObjectReplicationPolicyProperties) MarshalJSON ¶
func (o ObjectReplicationPolicyProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ObjectReplicationPolicyProperties.
func (*ObjectReplicationPolicyProperties) UnmarshalJSON ¶
func (o *ObjectReplicationPolicyProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ObjectReplicationPolicyProperties.
type ObjectReplicationPolicyRule ¶
type ObjectReplicationPolicyRule struct { // REQUIRED; Required. Destination container name. DestinationContainer *string `json:"destinationContainer,omitempty"` // REQUIRED; Required. Source container name. SourceContainer *string `json:"sourceContainer,omitempty"` // Optional. An object that defines the filter set. Filters *ObjectReplicationPolicyFilter `json:"filters,omitempty"` // Rule Id is auto-generated for each new rule on destination account. It is required for put policy on source account. RuleID *string `json:"ruleId,omitempty"` }
ObjectReplicationPolicyRule - The replication policy rule between two containers.
type ObjectType ¶
type ObjectType string
ObjectType - This is a required field. This field specifies the scope of the inventory created either at the blob or container level.
const ( ObjectTypeBlob ObjectType = "Blob" ObjectTypeContainer ObjectType = "Container" )
func PossibleObjectTypeValues ¶
func PossibleObjectTypeValues() []ObjectType
PossibleObjectTypeValues returns the possible values for the ObjectType const type.
func (ObjectType) ToPtr ¶
func (c ObjectType) ToPtr() *ObjectType
ToPtr returns a *ObjectType pointing to the current value.
type Operation ¶
type Operation struct { // Display metadata associated with the operation. Display *OperationDisplay `json:"display,omitempty"` // Operation name: {provider}/{resource}/{operation} Name *string `json:"name,omitempty"` // Properties of operation, include metric specifications. OperationProperties *OperationProperties `json:"properties,omitempty"` // The origin of operations. Origin *string `json:"origin,omitempty"` }
Operation - Storage REST API operation definition.
type OperationDisplay ¶
type OperationDisplay struct { // Description of the operation. Description *string `json:"description,omitempty"` // Type of operation: get, read, delete, etc. Operation *string `json:"operation,omitempty"` // Service provider: Microsoft Storage. Provider *string `json:"provider,omitempty"` // Resource on which the operation is performed etc. Resource *string `json:"resource,omitempty"` }
OperationDisplay - Display metadata associated with the operation.
type OperationListResult ¶
type OperationListResult struct { // List of Storage operations supported by the Storage resource provider. Value []*Operation `json:"value,omitempty"` }
OperationListResult - Result of the request to list Storage operations. It contains a list of operations and a URL link to get the next set of results.
func (OperationListResult) MarshalJSON ¶
func (o OperationListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationListResult.
type OperationProperties ¶
type OperationProperties struct { // One property of operation, include metric specifications. ServiceSpecification *ServiceSpecification `json:"serviceSpecification,omitempty"` }
OperationProperties - Properties of operation, include metric specifications.
type OperationsClient ¶
type OperationsClient struct {
// contains filtered or unexported fields
}
OperationsClient contains the methods for the Operations group. Don't use this type directly, use NewOperationsClient() instead.
func NewOperationsClient ¶
func NewOperationsClient(credential azcore.TokenCredential, options *arm.ClientOptions) *OperationsClient
NewOperationsClient creates a new instance of OperationsClient with the specified values. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*OperationsClient) List ¶
func (client *OperationsClient) List(ctx context.Context, options *OperationsClientListOptions) (OperationsClientListResponse, error)
List - Lists all of the available Storage Rest API operations. If the operation fails it returns an *azcore.ResponseError type. options - OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/OperationsList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewOperationsClient(cred, nil) res, err := client.List(ctx, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.OperationsClientListResult) }
Output:
type OperationsClientListOptions ¶ added in v0.3.0
type OperationsClientListOptions struct { }
OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.
type OperationsClientListResponse ¶ added in v0.3.0
type OperationsClientListResponse struct { OperationsClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
OperationsClientListResponse contains the response from method OperationsClient.List.
type OperationsClientListResult ¶ added in v0.3.0
type OperationsClientListResult struct {
OperationListResult
}
OperationsClientListResult contains the result from method OperationsClient.List.
type PermissionScope ¶ added in v0.3.0
type PermissionScope struct { // REQUIRED; The permissions for the local user. Possible values include: Read (r), Write (w), Delete (d), List (l), and Create // (c). Permissions *string `json:"permissions,omitempty"` // REQUIRED; The name of resource, normally the container name or the file share name, used by the local user. ResourceName *string `json:"resourceName,omitempty"` // REQUIRED; The service used by the local user, e.g. blob, file. Service *string `json:"service,omitempty"` }
type Permissions ¶
type Permissions string
Permissions - The signed permissions for the account SAS. Possible values include: Read (r), Write (w), Delete (d), List (l), Add (a), Create (c), Update (u) and Process (p).
const ( PermissionsA Permissions = "a" PermissionsC Permissions = "c" PermissionsD Permissions = "d" PermissionsL Permissions = "l" PermissionsP Permissions = "p" PermissionsR Permissions = "r" PermissionsU Permissions = "u" PermissionsW Permissions = "w" )
func PossiblePermissionsValues ¶
func PossiblePermissionsValues() []Permissions
PossiblePermissionsValues returns the possible values for the Permissions const type.
func (Permissions) ToPtr ¶
func (c Permissions) ToPtr() *Permissions
ToPtr returns a *Permissions pointing to the current value.
type PrivateEndpoint ¶
type PrivateEndpoint struct { // READ-ONLY; The ARM identifier for Private Endpoint ID *string `json:"id,omitempty" azure:"ro"` }
PrivateEndpoint - The Private Endpoint resource.
type PrivateEndpointConnection ¶
type PrivateEndpointConnection struct { // Resource properties. Properties *PrivateEndpointConnectionProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
PrivateEndpointConnection - The Private Endpoint Connection resource.
type PrivateEndpointConnectionListResult ¶
type PrivateEndpointConnectionListResult struct { // Array of private endpoint connections Value []*PrivateEndpointConnection `json:"value,omitempty"` }
PrivateEndpointConnectionListResult - List of private endpoint connection associated with the specified storage account
func (PrivateEndpointConnectionListResult) MarshalJSON ¶
func (p PrivateEndpointConnectionListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnectionListResult.
type PrivateEndpointConnectionProperties ¶
type PrivateEndpointConnectionProperties struct { // REQUIRED; A collection of information about the state of the connection between service consumer and provider. PrivateLinkServiceConnectionState *PrivateLinkServiceConnectionState `json:"privateLinkServiceConnectionState,omitempty"` // The resource of private end point. PrivateEndpoint *PrivateEndpoint `json:"privateEndpoint,omitempty"` // READ-ONLY; The provisioning state of the private endpoint connection resource. ProvisioningState *PrivateEndpointConnectionProvisioningState `json:"provisioningState,omitempty" azure:"ro"` }
PrivateEndpointConnectionProperties - Properties of the PrivateEndpointConnectProperties.
type PrivateEndpointConnectionProvisioningState ¶
type PrivateEndpointConnectionProvisioningState string
PrivateEndpointConnectionProvisioningState - The current provisioning state.
const ( PrivateEndpointConnectionProvisioningStateCreating PrivateEndpointConnectionProvisioningState = "Creating" PrivateEndpointConnectionProvisioningStateDeleting PrivateEndpointConnectionProvisioningState = "Deleting" PrivateEndpointConnectionProvisioningStateFailed PrivateEndpointConnectionProvisioningState = "Failed" PrivateEndpointConnectionProvisioningStateSucceeded PrivateEndpointConnectionProvisioningState = "Succeeded" )
func PossiblePrivateEndpointConnectionProvisioningStateValues ¶
func PossiblePrivateEndpointConnectionProvisioningStateValues() []PrivateEndpointConnectionProvisioningState
PossiblePrivateEndpointConnectionProvisioningStateValues returns the possible values for the PrivateEndpointConnectionProvisioningState const type.
func (PrivateEndpointConnectionProvisioningState) ToPtr ¶
func (c PrivateEndpointConnectionProvisioningState) ToPtr() *PrivateEndpointConnectionProvisioningState
ToPtr returns a *PrivateEndpointConnectionProvisioningState pointing to the current value.
type PrivateEndpointConnectionsClient ¶
type PrivateEndpointConnectionsClient struct {
// contains filtered or unexported fields
}
PrivateEndpointConnectionsClient contains the methods for the PrivateEndpointConnections group. Don't use this type directly, use NewPrivateEndpointConnectionsClient() instead.
func NewPrivateEndpointConnectionsClient ¶
func NewPrivateEndpointConnectionsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *PrivateEndpointConnectionsClient
NewPrivateEndpointConnectionsClient creates a new instance of PrivateEndpointConnectionsClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*PrivateEndpointConnectionsClient) Delete ¶
func (client *PrivateEndpointConnectionsClient) Delete(ctx context.Context, resourceGroupName string, accountName string, privateEndpointConnectionName string, options *PrivateEndpointConnectionsClientDeleteOptions) (PrivateEndpointConnectionsClientDeleteResponse, error)
Delete - Deletes the specified private endpoint connection associated with the storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. privateEndpointConnectionName - The name of the private endpoint connection associated with the Azure resource options - PrivateEndpointConnectionsClientDeleteOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Delete method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountDeletePrivateEndpointConnection.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewPrivateEndpointConnectionsClient("<subscription-id>", cred, nil) _, err = client.Delete(ctx, "<resource-group-name>", "<account-name>", "<private-endpoint-connection-name>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*PrivateEndpointConnectionsClient) Get ¶
func (client *PrivateEndpointConnectionsClient) Get(ctx context.Context, resourceGroupName string, accountName string, privateEndpointConnectionName string, options *PrivateEndpointConnectionsClientGetOptions) (PrivateEndpointConnectionsClientGetResponse, error)
Get - Gets the specified private endpoint connection associated with the storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. privateEndpointConnectionName - The name of the private endpoint connection associated with the Azure resource options - PrivateEndpointConnectionsClientGetOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountGetPrivateEndpointConnection.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewPrivateEndpointConnectionsClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<resource-group-name>", "<account-name>", "<private-endpoint-connection-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.PrivateEndpointConnectionsClientGetResult) }
Output:
func (*PrivateEndpointConnectionsClient) List ¶
func (client *PrivateEndpointConnectionsClient) List(ctx context.Context, resourceGroupName string, accountName string, options *PrivateEndpointConnectionsClientListOptions) (PrivateEndpointConnectionsClientListResponse, error)
List - List all the private endpoint connections associated with the storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - PrivateEndpointConnectionsClientListOptions contains the optional parameters for the PrivateEndpointConnectionsClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountListPrivateEndpointConnections.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewPrivateEndpointConnectionsClient("<subscription-id>", cred, nil) res, err := client.List(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.PrivateEndpointConnectionsClientListResult) }
Output:
func (*PrivateEndpointConnectionsClient) Put ¶
func (client *PrivateEndpointConnectionsClient) Put(ctx context.Context, resourceGroupName string, accountName string, privateEndpointConnectionName string, properties PrivateEndpointConnection, options *PrivateEndpointConnectionsClientPutOptions) (PrivateEndpointConnectionsClientPutResponse, error)
Put - Update the state of specified private endpoint connection associated with the storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. privateEndpointConnectionName - The name of the private endpoint connection associated with the Azure resource properties - The private endpoint connection properties. options - PrivateEndpointConnectionsClientPutOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Put method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountPutPrivateEndpointConnection.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewPrivateEndpointConnectionsClient("<subscription-id>", cred, nil) res, err := client.Put(ctx, "<resource-group-name>", "<account-name>", "<private-endpoint-connection-name>", armstorage.PrivateEndpointConnection{ Properties: &armstorage.PrivateEndpointConnectionProperties{ PrivateLinkServiceConnectionState: &armstorage.PrivateLinkServiceConnectionState{ Description: to.StringPtr("<description>"), Status: armstorage.PrivateEndpointServiceConnectionStatus("Approved").ToPtr(), }, }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.PrivateEndpointConnectionsClientPutResult) }
Output:
type PrivateEndpointConnectionsClientDeleteOptions ¶ added in v0.3.0
type PrivateEndpointConnectionsClientDeleteOptions struct { }
PrivateEndpointConnectionsClientDeleteOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Delete method.
type PrivateEndpointConnectionsClientDeleteResponse ¶ added in v0.3.0
type PrivateEndpointConnectionsClientDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
PrivateEndpointConnectionsClientDeleteResponse contains the response from method PrivateEndpointConnectionsClient.Delete.
type PrivateEndpointConnectionsClientGetOptions ¶ added in v0.3.0
type PrivateEndpointConnectionsClientGetOptions struct { }
PrivateEndpointConnectionsClientGetOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Get method.
type PrivateEndpointConnectionsClientGetResponse ¶ added in v0.3.0
type PrivateEndpointConnectionsClientGetResponse struct { PrivateEndpointConnectionsClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
PrivateEndpointConnectionsClientGetResponse contains the response from method PrivateEndpointConnectionsClient.Get.
type PrivateEndpointConnectionsClientGetResult ¶ added in v0.3.0
type PrivateEndpointConnectionsClientGetResult struct {
PrivateEndpointConnection
}
PrivateEndpointConnectionsClientGetResult contains the result from method PrivateEndpointConnectionsClient.Get.
type PrivateEndpointConnectionsClientListOptions ¶ added in v0.3.0
type PrivateEndpointConnectionsClientListOptions struct { }
PrivateEndpointConnectionsClientListOptions contains the optional parameters for the PrivateEndpointConnectionsClient.List method.
type PrivateEndpointConnectionsClientListResponse ¶ added in v0.3.0
type PrivateEndpointConnectionsClientListResponse struct { PrivateEndpointConnectionsClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
PrivateEndpointConnectionsClientListResponse contains the response from method PrivateEndpointConnectionsClient.List.
type PrivateEndpointConnectionsClientListResult ¶ added in v0.3.0
type PrivateEndpointConnectionsClientListResult struct {
PrivateEndpointConnectionListResult
}
PrivateEndpointConnectionsClientListResult contains the result from method PrivateEndpointConnectionsClient.List.
type PrivateEndpointConnectionsClientPutOptions ¶ added in v0.3.0
type PrivateEndpointConnectionsClientPutOptions struct { }
PrivateEndpointConnectionsClientPutOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Put method.
type PrivateEndpointConnectionsClientPutResponse ¶ added in v0.3.0
type PrivateEndpointConnectionsClientPutResponse struct { PrivateEndpointConnectionsClientPutResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
PrivateEndpointConnectionsClientPutResponse contains the response from method PrivateEndpointConnectionsClient.Put.
type PrivateEndpointConnectionsClientPutResult ¶ added in v0.3.0
type PrivateEndpointConnectionsClientPutResult struct {
PrivateEndpointConnection
}
PrivateEndpointConnectionsClientPutResult contains the result from method PrivateEndpointConnectionsClient.Put.
type PrivateEndpointServiceConnectionStatus ¶
type PrivateEndpointServiceConnectionStatus string
PrivateEndpointServiceConnectionStatus - The private endpoint connection status.
const ( PrivateEndpointServiceConnectionStatusApproved PrivateEndpointServiceConnectionStatus = "Approved" PrivateEndpointServiceConnectionStatusPending PrivateEndpointServiceConnectionStatus = "Pending" PrivateEndpointServiceConnectionStatusRejected PrivateEndpointServiceConnectionStatus = "Rejected" )
func PossiblePrivateEndpointServiceConnectionStatusValues ¶
func PossiblePrivateEndpointServiceConnectionStatusValues() []PrivateEndpointServiceConnectionStatus
PossiblePrivateEndpointServiceConnectionStatusValues returns the possible values for the PrivateEndpointServiceConnectionStatus const type.
func (PrivateEndpointServiceConnectionStatus) ToPtr ¶
func (c PrivateEndpointServiceConnectionStatus) ToPtr() *PrivateEndpointServiceConnectionStatus
ToPtr returns a *PrivateEndpointServiceConnectionStatus pointing to the current value.
type PrivateLinkResource ¶
type PrivateLinkResource struct { // Resource properties. Properties *PrivateLinkResourceProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
PrivateLinkResource - A private link resource
type PrivateLinkResourceListResult ¶
type PrivateLinkResourceListResult struct { // Array of private link resources Value []*PrivateLinkResource `json:"value,omitempty"` }
PrivateLinkResourceListResult - A list of private link resources
func (PrivateLinkResourceListResult) MarshalJSON ¶
func (p PrivateLinkResourceListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkResourceListResult.
type PrivateLinkResourceProperties ¶
type PrivateLinkResourceProperties struct { // The private link resource Private link DNS zone name. RequiredZoneNames []*string `json:"requiredZoneNames,omitempty"` // READ-ONLY; The private link resource group id. GroupID *string `json:"groupId,omitempty" azure:"ro"` // READ-ONLY; The private link resource required member names. RequiredMembers []*string `json:"requiredMembers,omitempty" azure:"ro"` }
PrivateLinkResourceProperties - Properties of a private link resource.
func (PrivateLinkResourceProperties) MarshalJSON ¶
func (p PrivateLinkResourceProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkResourceProperties.
type PrivateLinkResourcesClient ¶
type PrivateLinkResourcesClient struct {
// contains filtered or unexported fields
}
PrivateLinkResourcesClient contains the methods for the PrivateLinkResources group. Don't use this type directly, use NewPrivateLinkResourcesClient() instead.
func NewPrivateLinkResourcesClient ¶
func NewPrivateLinkResourcesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *PrivateLinkResourcesClient
NewPrivateLinkResourcesClient creates a new instance of PrivateLinkResourcesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*PrivateLinkResourcesClient) ListByStorageAccount ¶
func (client *PrivateLinkResourcesClient) ListByStorageAccount(ctx context.Context, resourceGroupName string, accountName string, options *PrivateLinkResourcesClientListByStorageAccountOptions) (PrivateLinkResourcesClientListByStorageAccountResponse, error)
ListByStorageAccount - Gets the private link resources that need to be created for a storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - PrivateLinkResourcesClientListByStorageAccountOptions contains the optional parameters for the PrivateLinkResourcesClient.ListByStorageAccount method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountListPrivateLinkResources.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewPrivateLinkResourcesClient("<subscription-id>", cred, nil) res, err := client.ListByStorageAccount(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.PrivateLinkResourcesClientListByStorageAccountResult) }
Output:
type PrivateLinkResourcesClientListByStorageAccountOptions ¶ added in v0.3.0
type PrivateLinkResourcesClientListByStorageAccountOptions struct { }
PrivateLinkResourcesClientListByStorageAccountOptions contains the optional parameters for the PrivateLinkResourcesClient.ListByStorageAccount method.
type PrivateLinkResourcesClientListByStorageAccountResponse ¶ added in v0.3.0
type PrivateLinkResourcesClientListByStorageAccountResponse struct { PrivateLinkResourcesClientListByStorageAccountResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
PrivateLinkResourcesClientListByStorageAccountResponse contains the response from method PrivateLinkResourcesClient.ListByStorageAccount.
type PrivateLinkResourcesClientListByStorageAccountResult ¶ added in v0.3.0
type PrivateLinkResourcesClientListByStorageAccountResult struct {
PrivateLinkResourceListResult
}
PrivateLinkResourcesClientListByStorageAccountResult contains the result from method PrivateLinkResourcesClient.ListByStorageAccount.
type PrivateLinkServiceConnectionState ¶
type PrivateLinkServiceConnectionState struct { // A message indicating if changes on the service provider require any updates on the consumer. ActionRequired *string `json:"actionRequired,omitempty"` // The reason for approval/rejection of the connection. Description *string `json:"description,omitempty"` // Indicates whether the connection has been Approved/Rejected/Removed by the owner of the service. Status *PrivateEndpointServiceConnectionStatus `json:"status,omitempty"` }
PrivateLinkServiceConnectionState - A collection of information about the state of the connection between service consumer and provider.
type ProtectedAppendWritesHistory ¶
type ProtectedAppendWritesHistory struct { // When enabled, new blocks can be written to both 'Append and Bock Blobs' while maintaining legal hold protection and compliance. // Only new blocks can be added and any existing blocks cannot be modified // or deleted. AllowProtectedAppendWritesAll *bool `json:"allowProtectedAppendWritesAll,omitempty"` // READ-ONLY; Returns the date and time the tag was added. Timestamp *time.Time `json:"timestamp,omitempty" azure:"ro"` }
ProtectedAppendWritesHistory - Protected append writes history setting for the blob container with Legal holds.
func (ProtectedAppendWritesHistory) MarshalJSON ¶
func (p ProtectedAppendWritesHistory) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ProtectedAppendWritesHistory.
func (*ProtectedAppendWritesHistory) UnmarshalJSON ¶
func (p *ProtectedAppendWritesHistory) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ProtectedAppendWritesHistory.
type ProtocolSettings ¶
type ProtocolSettings struct { // Setting for SMB protocol Smb *SmbSetting `json:"smb,omitempty"` }
ProtocolSettings - Protocol settings for file service
type ProvisioningState ¶
type ProvisioningState string
ProvisioningState - Gets the status of the storage account at the time the operation was called.
const ( ProvisioningStateCreating ProvisioningState = "Creating" ProvisioningStateResolvingDNS ProvisioningState = "ResolvingDNS" ProvisioningStateSucceeded ProvisioningState = "Succeeded" )
func PossibleProvisioningStateValues ¶
func PossibleProvisioningStateValues() []ProvisioningState
PossibleProvisioningStateValues returns the possible values for the ProvisioningState const type.
func (ProvisioningState) ToPtr ¶
func (c ProvisioningState) ToPtr() *ProvisioningState
ToPtr returns a *ProvisioningState pointing to the current value.
type ProxyResource ¶
type ProxyResource struct { // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
ProxyResource - The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location
type PublicAccess ¶
type PublicAccess string
PublicAccess - Specifies whether data in the container may be accessed publicly and the level of access.
const ( PublicAccessContainer PublicAccess = "Container" PublicAccessBlob PublicAccess = "Blob" PublicAccessNone PublicAccess = "None" )
func PossiblePublicAccessValues ¶
func PossiblePublicAccessValues() []PublicAccess
PossiblePublicAccessValues returns the possible values for the PublicAccess const type.
func (PublicAccess) ToPtr ¶
func (c PublicAccess) ToPtr() *PublicAccess
ToPtr returns a *PublicAccess pointing to the current value.
type PublicNetworkAccess ¶
type PublicNetworkAccess string
PublicNetworkAccess - Allow or disallow public network access to Storage Account. Value is optional but if passed in, must be 'Enabled' or 'Disabled'.
const ( PublicNetworkAccessDisabled PublicNetworkAccess = "Disabled" PublicNetworkAccessEnabled PublicNetworkAccess = "Enabled" )
func PossiblePublicNetworkAccessValues ¶
func PossiblePublicNetworkAccessValues() []PublicNetworkAccess
PossiblePublicNetworkAccessValues returns the possible values for the PublicNetworkAccess const type.
func (PublicNetworkAccess) ToPtr ¶
func (c PublicNetworkAccess) ToPtr() *PublicNetworkAccess
ToPtr returns a *PublicNetworkAccess pointing to the current value.
type Queue ¶ added in v0.3.0
type Queue struct { // Queue resource properties. QueueProperties *QueueProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
func (Queue) MarshalJSON ¶ added in v0.3.0
MarshalJSON implements the json.Marshaller interface for type Queue.
type QueueClient ¶
type QueueClient struct {
// contains filtered or unexported fields
}
QueueClient contains the methods for the Queue group. Don't use this type directly, use NewQueueClient() instead.
func NewQueueClient ¶
func NewQueueClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *QueueClient
NewQueueClient creates a new instance of QueueClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*QueueClient) Create ¶
func (client *QueueClient) Create(ctx context.Context, resourceGroupName string, accountName string, queueName string, queue Queue, options *QueueClientCreateOptions) (QueueClientCreateResponse, error)
Create - Creates a new queue with the specified queue name, under the specified account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. queueName - A queue name must be unique within a storage account and must be between 3 and 63 characters.The name must comprise of lowercase alphanumeric and dash(-) characters only, it should begin and end with an alphanumeric character and it cannot have two consecutive dash(-) characters. queue - Queue properties and metadata to be created with options - QueueClientCreateOptions contains the optional parameters for the QueueClient.Create method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/QueueOperationPut.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewQueueClient("<subscription-id>", cred, nil) res, err := client.Create(ctx, "<resource-group-name>", "<account-name>", "<queue-name>", armstorage.Queue{}, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.QueueClientCreateResult) }
Output:
func (*QueueClient) Delete ¶
func (client *QueueClient) Delete(ctx context.Context, resourceGroupName string, accountName string, queueName string, options *QueueClientDeleteOptions) (QueueClientDeleteResponse, error)
Delete - Deletes the queue with the specified queue name, under the specified account if it exists. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. queueName - A queue name must be unique within a storage account and must be between 3 and 63 characters.The name must comprise of lowercase alphanumeric and dash(-) characters only, it should begin and end with an alphanumeric character and it cannot have two consecutive dash(-) characters. options - QueueClientDeleteOptions contains the optional parameters for the QueueClient.Delete method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/QueueOperationDelete.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewQueueClient("<subscription-id>", cred, nil) _, err = client.Delete(ctx, "<resource-group-name>", "<account-name>", "<queue-name>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*QueueClient) Get ¶
func (client *QueueClient) Get(ctx context.Context, resourceGroupName string, accountName string, queueName string, options *QueueClientGetOptions) (QueueClientGetResponse, error)
Get - Gets the queue with the specified queue name, under the specified account if it exists. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. queueName - A queue name must be unique within a storage account and must be between 3 and 63 characters.The name must comprise of lowercase alphanumeric and dash(-) characters only, it should begin and end with an alphanumeric character and it cannot have two consecutive dash(-) characters. options - QueueClientGetOptions contains the optional parameters for the QueueClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/QueueOperationGet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewQueueClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<resource-group-name>", "<account-name>", "<queue-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.QueueClientGetResult) }
Output:
func (*QueueClient) List ¶
func (client *QueueClient) List(resourceGroupName string, accountName string, options *QueueClientListOptions) *QueueClientListPager
List - Gets a list of all the queues under the specified storage account If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - QueueClientListOptions contains the optional parameters for the QueueClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/QueueOperationList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewQueueClient("<subscription-id>", cred, nil) pager := client.List("<resource-group-name>", "<account-name>", &armstorage.QueueClientListOptions{Maxpagesize: nil, Filter: nil, }) for { nextResult := pager.NextPage(ctx) if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } if !nextResult { break } for _, v := range pager.PageResponse().Value { log.Printf("Pager result: %#v\n", v) } } }
Output:
func (*QueueClient) Update ¶
func (client *QueueClient) Update(ctx context.Context, resourceGroupName string, accountName string, queueName string, queue Queue, options *QueueClientUpdateOptions) (QueueClientUpdateResponse, error)
Update - Creates a new queue with the specified queue name, under the specified account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. queueName - A queue name must be unique within a storage account and must be between 3 and 63 characters.The name must comprise of lowercase alphanumeric and dash(-) characters only, it should begin and end with an alphanumeric character and it cannot have two consecutive dash(-) characters. queue - Queue properties and metadata to be created with options - QueueClientUpdateOptions contains the optional parameters for the QueueClient.Update method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/QueueOperationPatch.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewQueueClient("<subscription-id>", cred, nil) res, err := client.Update(ctx, "<resource-group-name>", "<account-name>", "<queue-name>", armstorage.Queue{}, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.QueueClientUpdateResult) }
Output:
type QueueClientCreateOptions ¶ added in v0.3.0
type QueueClientCreateOptions struct { }
QueueClientCreateOptions contains the optional parameters for the QueueClient.Create method.
type QueueClientCreateResponse ¶ added in v0.3.0
type QueueClientCreateResponse struct { QueueClientCreateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
QueueClientCreateResponse contains the response from method QueueClient.Create.
type QueueClientCreateResult ¶ added in v0.3.0
type QueueClientCreateResult struct {
Queue
}
QueueClientCreateResult contains the result from method QueueClient.Create.
type QueueClientDeleteOptions ¶ added in v0.3.0
type QueueClientDeleteOptions struct { }
QueueClientDeleteOptions contains the optional parameters for the QueueClient.Delete method.
type QueueClientDeleteResponse ¶ added in v0.3.0
type QueueClientDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
QueueClientDeleteResponse contains the response from method QueueClient.Delete.
type QueueClientGetOptions ¶ added in v0.3.0
type QueueClientGetOptions struct { }
QueueClientGetOptions contains the optional parameters for the QueueClient.Get method.
type QueueClientGetResponse ¶ added in v0.3.0
type QueueClientGetResponse struct { QueueClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
QueueClientGetResponse contains the response from method QueueClient.Get.
type QueueClientGetResult ¶ added in v0.3.0
type QueueClientGetResult struct {
Queue
}
QueueClientGetResult contains the result from method QueueClient.Get.
type QueueClientListOptions ¶ added in v0.3.0
type QueueClientListOptions struct { // Optional, When specified, only the queues with a name starting with the given filter will be listed. Filter *string // Optional, a maximum number of queues that should be included in a list queue response Maxpagesize *string }
QueueClientListOptions contains the optional parameters for the QueueClient.List method.
type QueueClientListPager ¶ added in v0.3.0
type QueueClientListPager struct {
// contains filtered or unexported fields
}
QueueClientListPager provides operations for iterating over paged responses.
func (*QueueClientListPager) Err ¶ added in v0.3.0
func (p *QueueClientListPager) Err() error
Err returns the last error encountered while paging.
func (*QueueClientListPager) NextPage ¶ added in v0.3.0
func (p *QueueClientListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*QueueClientListPager) PageResponse ¶ added in v0.3.0
func (p *QueueClientListPager) PageResponse() QueueClientListResponse
PageResponse returns the current QueueClientListResponse page.
type QueueClientListResponse ¶ added in v0.3.0
type QueueClientListResponse struct { QueueClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
QueueClientListResponse contains the response from method QueueClient.List.
type QueueClientListResult ¶ added in v0.3.0
type QueueClientListResult struct {
ListQueueResource
}
QueueClientListResult contains the result from method QueueClient.List.
type QueueClientUpdateOptions ¶ added in v0.3.0
type QueueClientUpdateOptions struct { }
QueueClientUpdateOptions contains the optional parameters for the QueueClient.Update method.
type QueueClientUpdateResponse ¶ added in v0.3.0
type QueueClientUpdateResponse struct { QueueClientUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
QueueClientUpdateResponse contains the response from method QueueClient.Update.
type QueueClientUpdateResult ¶ added in v0.3.0
type QueueClientUpdateResult struct {
Queue
}
QueueClientUpdateResult contains the result from method QueueClient.Update.
type QueueProperties ¶
type QueueProperties struct { // A name-value pair that represents queue metadata. Metadata map[string]*string `json:"metadata,omitempty"` // READ-ONLY; Integer indicating an approximate number of messages in the queue. This number is not lower than the actual // number of messages in the queue, but could be higher. ApproximateMessageCount *int32 `json:"approximateMessageCount,omitempty" azure:"ro"` }
func (QueueProperties) MarshalJSON ¶
func (q QueueProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type QueueProperties.
type QueueServiceProperties ¶
type QueueServiceProperties struct { // The properties of a storage account’s Queue service. QueueServiceProperties *QueueServicePropertiesProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
QueueServiceProperties - The properties of a storage account’s Queue service.
type QueueServicePropertiesProperties ¶
type QueueServicePropertiesProperties struct { // Specifies CORS rules for the Queue service. You can include up to five CorsRule elements in the request. If no CorsRule // elements are included in the request body, all CORS rules will be deleted, and // CORS will be disabled for the Queue service. Cors *CorsRules `json:"cors,omitempty"` }
QueueServicePropertiesProperties - The properties of a storage account’s Queue service.
type QueueServicesClient ¶
type QueueServicesClient struct {
// contains filtered or unexported fields
}
QueueServicesClient contains the methods for the QueueServices group. Don't use this type directly, use NewQueueServicesClient() instead.
func NewQueueServicesClient ¶
func NewQueueServicesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *QueueServicesClient
NewQueueServicesClient creates a new instance of QueueServicesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*QueueServicesClient) GetServiceProperties ¶
func (client *QueueServicesClient) GetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, options *QueueServicesClientGetServicePropertiesOptions) (QueueServicesClientGetServicePropertiesResponse, error)
GetServiceProperties - Gets the properties of a storage account’s Queue service, including properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - QueueServicesClientGetServicePropertiesOptions contains the optional parameters for the QueueServicesClient.GetServiceProperties method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/QueueServicesGet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewQueueServicesClient("<subscription-id>", cred, nil) res, err := client.GetServiceProperties(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.QueueServicesClientGetServicePropertiesResult) }
Output:
func (*QueueServicesClient) List ¶
func (client *QueueServicesClient) List(ctx context.Context, resourceGroupName string, accountName string, options *QueueServicesClientListOptions) (QueueServicesClientListResponse, error)
List - List all queue services for the storage account If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - QueueServicesClientListOptions contains the optional parameters for the QueueServicesClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/QueueServicesList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewQueueServicesClient("<subscription-id>", cred, nil) res, err := client.List(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.QueueServicesClientListResult) }
Output:
func (*QueueServicesClient) SetServiceProperties ¶
func (client *QueueServicesClient) SetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, parameters QueueServiceProperties, options *QueueServicesClientSetServicePropertiesOptions) (QueueServicesClientSetServicePropertiesResponse, error)
SetServiceProperties - Sets the properties of a storage account’s Queue service, including properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. parameters - The properties of a storage account’s Queue service, only properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules can be specified. options - QueueServicesClientSetServicePropertiesOptions contains the optional parameters for the QueueServicesClient.SetServiceProperties method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/QueueServicesPut.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewQueueServicesClient("<subscription-id>", cred, nil) res, err := client.SetServiceProperties(ctx, "<resource-group-name>", "<account-name>", armstorage.QueueServiceProperties{ QueueServiceProperties: &armstorage.QueueServicePropertiesProperties{ Cors: &armstorage.CorsRules{ CorsRules: []*armstorage.CorsRule{ { AllowedHeaders: []*string{ to.StringPtr("x-ms-meta-abc"), to.StringPtr("x-ms-meta-data*"), to.StringPtr("x-ms-meta-target*")}, AllowedMethods: []*armstorage.CorsRuleAllowedMethodsItem{ armstorage.CorsRuleAllowedMethodsItem("GET").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("HEAD").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("POST").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("OPTIONS").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("MERGE").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("PUT").ToPtr()}, AllowedOrigins: []*string{ to.StringPtr("http://www.contoso.com"), to.StringPtr("http://www.fabrikam.com")}, ExposedHeaders: []*string{ to.StringPtr("x-ms-meta-*")}, MaxAgeInSeconds: to.Int32Ptr(100), }, { AllowedHeaders: []*string{ to.StringPtr("*")}, AllowedMethods: []*armstorage.CorsRuleAllowedMethodsItem{ armstorage.CorsRuleAllowedMethodsItem("GET").ToPtr()}, AllowedOrigins: []*string{ to.StringPtr("*")}, ExposedHeaders: []*string{ to.StringPtr("*")}, MaxAgeInSeconds: to.Int32Ptr(2), }, { AllowedHeaders: []*string{ to.StringPtr("x-ms-meta-12345675754564*")}, AllowedMethods: []*armstorage.CorsRuleAllowedMethodsItem{ armstorage.CorsRuleAllowedMethodsItem("GET").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("PUT").ToPtr()}, AllowedOrigins: []*string{ to.StringPtr("http://www.abc23.com"), to.StringPtr("https://www.fabrikam.com/*")}, ExposedHeaders: []*string{ to.StringPtr("x-ms-meta-abc"), to.StringPtr("x-ms-meta-data*"), to.StringPtr("x-ms-meta-target*")}, MaxAgeInSeconds: to.Int32Ptr(2000), }}, }, }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.QueueServicesClientSetServicePropertiesResult) }
Output:
type QueueServicesClientGetServicePropertiesOptions ¶ added in v0.3.0
type QueueServicesClientGetServicePropertiesOptions struct { }
QueueServicesClientGetServicePropertiesOptions contains the optional parameters for the QueueServicesClient.GetServiceProperties method.
type QueueServicesClientGetServicePropertiesResponse ¶ added in v0.3.0
type QueueServicesClientGetServicePropertiesResponse struct { QueueServicesClientGetServicePropertiesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
QueueServicesClientGetServicePropertiesResponse contains the response from method QueueServicesClient.GetServiceProperties.
type QueueServicesClientGetServicePropertiesResult ¶ added in v0.3.0
type QueueServicesClientGetServicePropertiesResult struct {
QueueServiceProperties
}
QueueServicesClientGetServicePropertiesResult contains the result from method QueueServicesClient.GetServiceProperties.
type QueueServicesClientListOptions ¶ added in v0.3.0
type QueueServicesClientListOptions struct { }
QueueServicesClientListOptions contains the optional parameters for the QueueServicesClient.List method.
type QueueServicesClientListResponse ¶ added in v0.3.0
type QueueServicesClientListResponse struct { QueueServicesClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
QueueServicesClientListResponse contains the response from method QueueServicesClient.List.
type QueueServicesClientListResult ¶ added in v0.3.0
type QueueServicesClientListResult struct {
ListQueueServices
}
QueueServicesClientListResult contains the result from method QueueServicesClient.List.
type QueueServicesClientSetServicePropertiesOptions ¶ added in v0.3.0
type QueueServicesClientSetServicePropertiesOptions struct { }
QueueServicesClientSetServicePropertiesOptions contains the optional parameters for the QueueServicesClient.SetServiceProperties method.
type QueueServicesClientSetServicePropertiesResponse ¶ added in v0.3.0
type QueueServicesClientSetServicePropertiesResponse struct { QueueServicesClientSetServicePropertiesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
QueueServicesClientSetServicePropertiesResponse contains the response from method QueueServicesClient.SetServiceProperties.
type QueueServicesClientSetServicePropertiesResult ¶ added in v0.3.0
type QueueServicesClientSetServicePropertiesResult struct {
QueueServiceProperties
}
QueueServicesClientSetServicePropertiesResult contains the result from method QueueServicesClient.SetServiceProperties.
type Reason ¶
type Reason string
Reason - Gets the reason that a storage account name could not be used. The Reason element is only returned if NameAvailable is false.
func PossibleReasonValues ¶
func PossibleReasonValues() []Reason
PossibleReasonValues returns the possible values for the Reason const type.
type ReasonCode ¶
type ReasonCode string
ReasonCode - The reason for the restriction. As of now this can be "QuotaId" or "NotAvailableForSubscription". Quota Id is set when the SKU has requiredQuotas parameter as the subscription does not belong to that quota. The "NotAvailableForSubscription" is related to capacity at DC.
const ( ReasonCodeNotAvailableForSubscription ReasonCode = "NotAvailableForSubscription" ReasonCodeQuotaID ReasonCode = "QuotaId" )
func PossibleReasonCodeValues ¶
func PossibleReasonCodeValues() []ReasonCode
PossibleReasonCodeValues returns the possible values for the ReasonCode const type.
func (ReasonCode) ToPtr ¶
func (c ReasonCode) ToPtr() *ReasonCode
ToPtr returns a *ReasonCode pointing to the current value.
type Resource ¶
type Resource struct { // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
Resource - Common fields that are returned in the response for all Azure Resource Manager resources
type ResourceAccessRule ¶
type ResourceAccessRule struct { // Resource Id ResourceID *string `json:"resourceId,omitempty"` // Tenant Id TenantID *string `json:"tenantId,omitempty"` }
ResourceAccessRule - Resource Access Rule.
type RestorePolicyProperties ¶
type RestorePolicyProperties struct { // REQUIRED; Blob restore is enabled if set to true. Enabled *bool `json:"enabled,omitempty"` // how long this blob can be restored. It should be great than zero and less than DeleteRetentionPolicy.days. Days *int32 `json:"days,omitempty"` // READ-ONLY; Deprecated in favor of minRestoreTime property. LastEnabledTime *time.Time `json:"lastEnabledTime,omitempty" azure:"ro"` // READ-ONLY; Returns the minimum date and time that the restore can be started. MinRestoreTime *time.Time `json:"minRestoreTime,omitempty" azure:"ro"` }
RestorePolicyProperties - The blob service properties for blob restore policy
func (RestorePolicyProperties) MarshalJSON ¶
func (r RestorePolicyProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type RestorePolicyProperties.
func (*RestorePolicyProperties) UnmarshalJSON ¶
func (r *RestorePolicyProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type RestorePolicyProperties.
type Restriction ¶
type Restriction struct { // The reason for the restriction. As of now this can be "QuotaId" or "NotAvailableForSubscription". Quota Id is set when // the SKU has requiredQuotas parameter as the subscription does not belong to that // quota. The "NotAvailableForSubscription" is related to capacity at DC. ReasonCode *ReasonCode `json:"reasonCode,omitempty"` // READ-ONLY; The type of restrictions. As of now only possible value for this is location. Type *string `json:"type,omitempty" azure:"ro"` // READ-ONLY; The value of restrictions. If the restriction type is set to location. This would be different locations where // the SKU is restricted. Values []*string `json:"values,omitempty" azure:"ro"` }
Restriction - The restriction because of which SKU cannot be used.
func (Restriction) MarshalJSON ¶
func (r Restriction) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type Restriction.
type RootSquashType ¶
type RootSquashType string
RootSquashType - The property is for NFS share only. The default is NoRootSquash.
const ( RootSquashTypeAllSquash RootSquashType = "AllSquash" RootSquashTypeNoRootSquash RootSquashType = "NoRootSquash" RootSquashTypeRootSquash RootSquashType = "RootSquash" )
func PossibleRootSquashTypeValues ¶
func PossibleRootSquashTypeValues() []RootSquashType
PossibleRootSquashTypeValues returns the possible values for the RootSquashType const type.
func (RootSquashType) ToPtr ¶
func (c RootSquashType) ToPtr() *RootSquashType
ToPtr returns a *RootSquashType pointing to the current value.
type RoutingChoice ¶
type RoutingChoice string
RoutingChoice - Routing Choice defines the kind of network routing opted by the user.
const ( RoutingChoiceInternetRouting RoutingChoice = "InternetRouting" RoutingChoiceMicrosoftRouting RoutingChoice = "MicrosoftRouting" )
func PossibleRoutingChoiceValues ¶
func PossibleRoutingChoiceValues() []RoutingChoice
PossibleRoutingChoiceValues returns the possible values for the RoutingChoice const type.
func (RoutingChoice) ToPtr ¶
func (c RoutingChoice) ToPtr() *RoutingChoice
ToPtr returns a *RoutingChoice pointing to the current value.
type RoutingPreference ¶
type RoutingPreference struct { // A boolean flag which indicates whether internet routing storage endpoints are to be published PublishInternetEndpoints *bool `json:"publishInternetEndpoints,omitempty"` // A boolean flag which indicates whether microsoft routing storage endpoints are to be published PublishMicrosoftEndpoints *bool `json:"publishMicrosoftEndpoints,omitempty"` // Routing Choice defines the kind of network routing opted by the user. RoutingChoice *RoutingChoice `json:"routingChoice,omitempty"` }
RoutingPreference - Routing preference defines the type of network, either microsoft or internet routing to be used to deliver the user data, the default option is microsoft routing
type RuleType ¶
type RuleType string
RuleType - The valid value is Lifecycle
const (
RuleTypeLifecycle RuleType = "Lifecycle"
)
func PossibleRuleTypeValues ¶
func PossibleRuleTypeValues() []RuleType
PossibleRuleTypeValues returns the possible values for the RuleType const type.
type SKU ¶
type SKU struct { // REQUIRED; The SKU name. Required for account creation; optional for update. Note that in older versions, SKU name was called // accountType. Name *SKUName `json:"name,omitempty"` // READ-ONLY; The SKU tier. This is based on the SKU name. Tier *SKUTier `json:"tier,omitempty" azure:"ro"` }
SKU - The SKU of the storage account.
type SKUCapability ¶
type SKUCapability struct { // READ-ONLY; The name of capability, The capability information in the specified SKU, including file encryption, network // ACLs, change notification, etc. Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; A string value to indicate states of given capability. Possibly 'true' or 'false'. Value *string `json:"value,omitempty" azure:"ro"` }
SKUCapability - The capability information in the specified SKU, including file encryption, network ACLs, change notification, etc.
type SKUInformation ¶
type SKUInformation struct { // REQUIRED; The SKU name. Required for account creation; optional for update. Note that in older versions, SKU name was called // accountType. Name *SKUName `json:"name,omitempty"` // The restrictions because of which SKU cannot be used. This is empty if there are no restrictions. Restrictions []*Restriction `json:"restrictions,omitempty"` // READ-ONLY; The capability information in the specified SKU, including file encryption, network ACLs, change notification, // etc. Capabilities []*SKUCapability `json:"capabilities,omitempty" azure:"ro"` // READ-ONLY; Indicates the type of storage account. Kind *Kind `json:"kind,omitempty" azure:"ro"` // READ-ONLY; The set of locations that the SKU is available. This will be supported and registered Azure Geo Regions (e.g. // West US, East US, Southeast Asia, etc.). Locations []*string `json:"locations,omitempty" azure:"ro"` // READ-ONLY; The type of the resource, usually it is 'storageAccounts'. ResourceType *string `json:"resourceType,omitempty" azure:"ro"` // READ-ONLY; The SKU tier. This is based on the SKU name. Tier *SKUTier `json:"tier,omitempty" azure:"ro"` }
SKUInformation - Storage SKU and its properties
func (SKUInformation) MarshalJSON ¶
func (s SKUInformation) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SKUInformation.
type SKUListResult ¶ added in v0.3.0
type SKUListResult struct { // READ-ONLY; Get the list result of storage SKUs and their properties. Value []*SKUInformation `json:"value,omitempty" azure:"ro"` }
SKUListResult - The response from the List Storage SKUs operation.
func (SKUListResult) MarshalJSON ¶ added in v0.3.0
func (s SKUListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SKUListResult.
type SKUName ¶
type SKUName string
SKUName - The SKU name. Required for account creation; optional for update. Note that in older versions, SKU name was called accountType.
const ( SKUNamePremiumLRS SKUName = "Premium_LRS" SKUNamePremiumZRS SKUName = "Premium_ZRS" SKUNameStandardGRS SKUName = "Standard_GRS" SKUNameStandardGZRS SKUName = "Standard_GZRS" SKUNameStandardLRS SKUName = "Standard_LRS" SKUNameStandardRAGRS SKUName = "Standard_RAGRS" SKUNameStandardRAGZRS SKUName = "Standard_RAGZRS" SKUNameStandardZRS SKUName = "Standard_ZRS" )
func PossibleSKUNameValues ¶
func PossibleSKUNameValues() []SKUName
PossibleSKUNameValues returns the possible values for the SKUName const type.
type SKUTier ¶
type SKUTier string
SKUTier - The SKU tier. This is based on the SKU name.
func PossibleSKUTierValues ¶
func PossibleSKUTierValues() []SKUTier
PossibleSKUTierValues returns the possible values for the SKUTier const type.
type SKUsClient ¶
type SKUsClient struct {
// contains filtered or unexported fields
}
SKUsClient contains the methods for the SKUs group. Don't use this type directly, use NewSKUsClient() instead.
func NewSKUsClient ¶
func NewSKUsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *SKUsClient
NewSKUsClient creates a new instance of SKUsClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*SKUsClient) List ¶
func (client *SKUsClient) List(ctx context.Context, options *SKUsClientListOptions) (SKUsClientListResponse, error)
List - Lists the available SKUs supported by Microsoft.Storage for given subscription. If the operation fails it returns an *azcore.ResponseError type. options - SKUsClientListOptions contains the optional parameters for the SKUsClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/SKUList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewSKUsClient("<subscription-id>", cred, nil) res, err := client.List(ctx, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.SKUsClientListResult) }
Output:
type SKUsClientListOptions ¶ added in v0.3.0
type SKUsClientListOptions struct { }
SKUsClientListOptions contains the optional parameters for the SKUsClient.List method.
type SKUsClientListResponse ¶ added in v0.3.0
type SKUsClientListResponse struct { SKUsClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
SKUsClientListResponse contains the response from method SKUsClient.List.
type SKUsClientListResult ¶ added in v0.3.0
type SKUsClientListResult struct {
SKUListResult
}
SKUsClientListResult contains the result from method SKUsClient.List.
type SSHPublicKey ¶ added in v0.3.0
type SasPolicy ¶
type SasPolicy struct { // REQUIRED; The SAS expiration action. Can only be Log. ExpirationAction *ExpirationAction `json:"expirationAction,omitempty"` // REQUIRED; The SAS expiration period, DD.HH:MM:SS. SasExpirationPeriod *string `json:"sasExpirationPeriod,omitempty"` }
SasPolicy assigned to the storage account.
type Schedule ¶
type Schedule string
Schedule - This is a required field. This field is used to schedule an inventory formation.
func PossibleScheduleValues ¶
func PossibleScheduleValues() []Schedule
PossibleScheduleValues returns the possible values for the Schedule const type.
type ServiceSasParameters ¶
type ServiceSasParameters struct { // REQUIRED; The canonical path to the signed resource. CanonicalizedResource *string `json:"canonicalizedResource,omitempty"` // The response header override for cache control. CacheControl *string `json:"rscc,omitempty"` // The response header override for content disposition. ContentDisposition *string `json:"rscd,omitempty"` // The response header override for content encoding. ContentEncoding *string `json:"rsce,omitempty"` // The response header override for content language. ContentLanguage *string `json:"rscl,omitempty"` // The response header override for content type. ContentType *string `json:"rsct,omitempty"` // An IP address or a range of IP addresses from which to accept requests. IPAddressOrRange *string `json:"signedIp,omitempty"` // A unique value up to 64 characters in length that correlates to an access policy specified for the container, queue, or // table. Identifier *string `json:"signedIdentifier,omitempty"` // The key to sign the account SAS token with. KeyToSign *string `json:"keyToSign,omitempty"` // The end of partition key. PartitionKeyEnd *string `json:"endPk,omitempty"` // The start of partition key. PartitionKeyStart *string `json:"startPk,omitempty"` // The signed permissions for the service SAS. Possible values include: Read (r), Write (w), Delete (d), List (l), Add (a), // Create (c), Update (u) and Process (p). Permissions *Permissions `json:"signedPermission,omitempty"` // The protocol permitted for a request made with the account SAS. Protocols *HTTPProtocol `json:"signedProtocol,omitempty"` // The signed services accessible with the service SAS. Possible values include: Blob (b), Container (c), File (f), Share // (s). Resource *SignedResource `json:"signedResource,omitempty"` // The end of row key. RowKeyEnd *string `json:"endRk,omitempty"` // The start of row key. RowKeyStart *string `json:"startRk,omitempty"` SharedAccessExpiryTime *time.Time `json:"signedExpiry,omitempty"` SharedAccessStartTime *time.Time `json:"signedStart,omitempty"` }
ServiceSasParameters - The parameters to list service SAS credentials of a specific resource.
func (ServiceSasParameters) MarshalJSON ¶
func (s ServiceSasParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ServiceSasParameters.
func (*ServiceSasParameters) UnmarshalJSON ¶
func (s *ServiceSasParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ServiceSasParameters.
type ServiceSpecification ¶
type ServiceSpecification struct { // Metric specifications of operation. MetricSpecifications []*MetricSpecification `json:"metricSpecifications,omitempty"` }
ServiceSpecification - One property of operation, include metric specifications.
func (ServiceSpecification) MarshalJSON ¶
func (s ServiceSpecification) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ServiceSpecification.
type Services ¶
type Services string
Services - The signed services accessible with the account SAS. Possible values include: Blob (b), Queue (q), Table (t), File (f).
func PossibleServicesValues ¶
func PossibleServicesValues() []Services
PossibleServicesValues returns the possible values for the Services const type.
type ShareAccessTier ¶
type ShareAccessTier string
ShareAccessTier - Access tier for specific share. GpV2 account can choose between TransactionOptimized (default), Hot, and Cool. FileStorage account can choose Premium.
const ()
func PossibleShareAccessTierValues ¶
func PossibleShareAccessTierValues() []ShareAccessTier
PossibleShareAccessTierValues returns the possible values for the ShareAccessTier const type.
func (ShareAccessTier) ToPtr ¶
func (c ShareAccessTier) ToPtr() *ShareAccessTier
ToPtr returns a *ShareAccessTier pointing to the current value.
type SignedIdentifier ¶
type SignedIdentifier struct { // Access policy AccessPolicy *AccessPolicy `json:"accessPolicy,omitempty"` // An unique identifier of the stored access policy. ID *string `json:"id,omitempty"` }
type SignedResource ¶
type SignedResource string
SignedResource - The signed services accessible with the service SAS. Possible values include: Blob (b), Container (c), File (f), Share (s).
const ( SignedResourceB SignedResource = "b" SignedResourceC SignedResource = "c" SignedResourceF SignedResource = "f" SignedResourceS SignedResource = "s" )
func PossibleSignedResourceValues ¶
func PossibleSignedResourceValues() []SignedResource
PossibleSignedResourceValues returns the possible values for the SignedResource const type.
func (SignedResource) ToPtr ¶
func (c SignedResource) ToPtr() *SignedResource
ToPtr returns a *SignedResource pointing to the current value.
type SignedResourceTypes ¶
type SignedResourceTypes string
SignedResourceTypes - The signed resource types that are accessible with the account SAS. Service (s): Access to service-level APIs; Container (c): Access to container-level APIs; Object (o): Access to object-level APIs for blobs, queue messages, table entities, and files.
const ( SignedResourceTypesC SignedResourceTypes = "c" SignedResourceTypesO SignedResourceTypes = "o" SignedResourceTypesS SignedResourceTypes = "s" )
func PossibleSignedResourceTypesValues ¶
func PossibleSignedResourceTypesValues() []SignedResourceTypes
PossibleSignedResourceTypesValues returns the possible values for the SignedResourceTypes const type.
func (SignedResourceTypes) ToPtr ¶
func (c SignedResourceTypes) ToPtr() *SignedResourceTypes
ToPtr returns a *SignedResourceTypes pointing to the current value.
type SmbSetting ¶
type SmbSetting struct { // SMB authentication methods supported by server. Valid values are NTLMv2, Kerberos. Should be passed as a string with delimiter // ';'. AuthenticationMethods *string `json:"authenticationMethods,omitempty"` // SMB channel encryption supported by server. Valid values are AES-128-CCM, AES-128-GCM, AES-256-GCM. Should be passed as // a string with delimiter ';'. ChannelEncryption *string `json:"channelEncryption,omitempty"` // Kerberos ticket encryption supported by server. Valid values are RC4-HMAC, AES-256. Should be passed as a string with delimiter // ';' KerberosTicketEncryption *string `json:"kerberosTicketEncryption,omitempty"` // Multichannel setting. Applies to Premium FileStorage only. Multichannel *Multichannel `json:"multichannel,omitempty"` // SMB protocol versions supported by server. Valid values are SMB2.1, SMB3.0, SMB3.1.1. Should be passed as a string with // delimiter ';'. Versions *string `json:"versions,omitempty"` }
SmbSetting - Setting for SMB protocol
type State ¶
type State string
State - Gets the state of virtual network rule.
func PossibleStateValues ¶
func PossibleStateValues() []State
PossibleStateValues returns the possible values for the State const type.
type StorageAccountExpand ¶
type StorageAccountExpand string
const ( StorageAccountExpandGeoReplicationStats StorageAccountExpand = "geoReplicationStats" StorageAccountExpandBlobRestoreStatus StorageAccountExpand = "blobRestoreStatus" )
func PossibleStorageAccountExpandValues ¶
func PossibleStorageAccountExpandValues() []StorageAccountExpand
PossibleStorageAccountExpandValues returns the possible values for the StorageAccountExpand const type.
func (StorageAccountExpand) ToPtr ¶
func (c StorageAccountExpand) ToPtr() *StorageAccountExpand
ToPtr returns a *StorageAccountExpand pointing to the current value.
type SystemData ¶
type SystemData struct { // The timestamp of resource creation (UTC). CreatedAt *time.Time `json:"createdAt,omitempty"` // The identity that created the resource. CreatedBy *string `json:"createdBy,omitempty"` // The type of identity that created the resource. CreatedByType *CreatedByType `json:"createdByType,omitempty"` // The timestamp of resource last modification (UTC) LastModifiedAt *time.Time `json:"lastModifiedAt,omitempty"` // The identity that last modified the resource. LastModifiedBy *string `json:"lastModifiedBy,omitempty"` // The type of identity that last modified the resource. LastModifiedByType *CreatedByType `json:"lastModifiedByType,omitempty"` }
SystemData - Metadata pertaining to creation and last modification of the resource.
func (SystemData) MarshalJSON ¶
func (s SystemData) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SystemData.
func (*SystemData) UnmarshalJSON ¶
func (s *SystemData) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type SystemData.
type Table ¶
type Table struct { // Table resource properties. TableProperties *TableProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
Table - Properties of the table, including Id, resource name, resource type.
type TableClient ¶
type TableClient struct {
// contains filtered or unexported fields
}
TableClient contains the methods for the Table group. Don't use this type directly, use NewTableClient() instead.
func NewTableClient ¶
func NewTableClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *TableClient
NewTableClient creates a new instance of TableClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*TableClient) Create ¶
func (client *TableClient) Create(ctx context.Context, resourceGroupName string, accountName string, tableName string, options *TableClientCreateOptions) (TableClientCreateResponse, error)
Create - Creates a new table with the specified table name, under the specified account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. tableName - A table name must be unique within a storage account and must be between 3 and 63 characters.The name must comprise of only alphanumeric characters and it cannot begin with a numeric character. options - TableClientCreateOptions contains the optional parameters for the TableClient.Create method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/TableOperationPut.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewTableClient("<subscription-id>", cred, nil) res, err := client.Create(ctx, "<resource-group-name>", "<account-name>", "<table-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.TableClientCreateResult) }
Output:
func (*TableClient) Delete ¶
func (client *TableClient) Delete(ctx context.Context, resourceGroupName string, accountName string, tableName string, options *TableClientDeleteOptions) (TableClientDeleteResponse, error)
Delete - Deletes the table with the specified table name, under the specified account if it exists. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. tableName - A table name must be unique within a storage account and must be between 3 and 63 characters.The name must comprise of only alphanumeric characters and it cannot begin with a numeric character. options - TableClientDeleteOptions contains the optional parameters for the TableClient.Delete method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/TableOperationDelete.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewTableClient("<subscription-id>", cred, nil) _, err = client.Delete(ctx, "<resource-group-name>", "<account-name>", "<table-name>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*TableClient) Get ¶
func (client *TableClient) Get(ctx context.Context, resourceGroupName string, accountName string, tableName string, options *TableClientGetOptions) (TableClientGetResponse, error)
Get - Gets the table with the specified table name, under the specified account if it exists. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. tableName - A table name must be unique within a storage account and must be between 3 and 63 characters.The name must comprise of only alphanumeric characters and it cannot begin with a numeric character. options - TableClientGetOptions contains the optional parameters for the TableClient.Get method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/TableOperationGet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewTableClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<resource-group-name>", "<account-name>", "<table-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.TableClientGetResult) }
Output:
func (*TableClient) List ¶
func (client *TableClient) List(resourceGroupName string, accountName string, options *TableClientListOptions) *TableClientListPager
List - Gets a list of all the tables under the specified storage account If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - TableClientListOptions contains the optional parameters for the TableClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/TableOperationList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewTableClient("<subscription-id>", cred, nil) pager := client.List("<resource-group-name>", "<account-name>", nil) for { nextResult := pager.NextPage(ctx) if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } if !nextResult { break } for _, v := range pager.PageResponse().Value { log.Printf("Pager result: %#v\n", v) } } }
Output:
func (*TableClient) Update ¶
func (client *TableClient) Update(ctx context.Context, resourceGroupName string, accountName string, tableName string, options *TableClientUpdateOptions) (TableClientUpdateResponse, error)
Update - Creates a new table with the specified table name, under the specified account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. tableName - A table name must be unique within a storage account and must be between 3 and 63 characters.The name must comprise of only alphanumeric characters and it cannot begin with a numeric character. options - TableClientUpdateOptions contains the optional parameters for the TableClient.Update method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/TableOperationPatch.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewTableClient("<subscription-id>", cred, nil) res, err := client.Update(ctx, "<resource-group-name>", "<account-name>", "<table-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.TableClientUpdateResult) }
Output:
type TableClientCreateOptions ¶ added in v0.3.0
type TableClientCreateOptions struct { }
TableClientCreateOptions contains the optional parameters for the TableClient.Create method.
type TableClientCreateResponse ¶ added in v0.3.0
type TableClientCreateResponse struct { TableClientCreateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TableClientCreateResponse contains the response from method TableClient.Create.
type TableClientCreateResult ¶ added in v0.3.0
type TableClientCreateResult struct {
Table
}
TableClientCreateResult contains the result from method TableClient.Create.
type TableClientDeleteOptions ¶ added in v0.3.0
type TableClientDeleteOptions struct { }
TableClientDeleteOptions contains the optional parameters for the TableClient.Delete method.
type TableClientDeleteResponse ¶ added in v0.3.0
type TableClientDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TableClientDeleteResponse contains the response from method TableClient.Delete.
type TableClientGetOptions ¶ added in v0.3.0
type TableClientGetOptions struct { }
TableClientGetOptions contains the optional parameters for the TableClient.Get method.
type TableClientGetResponse ¶ added in v0.3.0
type TableClientGetResponse struct { TableClientGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TableClientGetResponse contains the response from method TableClient.Get.
type TableClientGetResult ¶ added in v0.3.0
type TableClientGetResult struct {
Table
}
TableClientGetResult contains the result from method TableClient.Get.
type TableClientListOptions ¶ added in v0.3.0
type TableClientListOptions struct { }
TableClientListOptions contains the optional parameters for the TableClient.List method.
type TableClientListPager ¶ added in v0.3.0
type TableClientListPager struct {
// contains filtered or unexported fields
}
TableClientListPager provides operations for iterating over paged responses.
func (*TableClientListPager) Err ¶ added in v0.3.0
func (p *TableClientListPager) Err() error
Err returns the last error encountered while paging.
func (*TableClientListPager) NextPage ¶ added in v0.3.0
func (p *TableClientListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*TableClientListPager) PageResponse ¶ added in v0.3.0
func (p *TableClientListPager) PageResponse() TableClientListResponse
PageResponse returns the current TableClientListResponse page.
type TableClientListResponse ¶ added in v0.3.0
type TableClientListResponse struct { TableClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TableClientListResponse contains the response from method TableClient.List.
type TableClientListResult ¶ added in v0.3.0
type TableClientListResult struct {
ListTableResource
}
TableClientListResult contains the result from method TableClient.List.
type TableClientUpdateOptions ¶ added in v0.3.0
type TableClientUpdateOptions struct { }
TableClientUpdateOptions contains the optional parameters for the TableClient.Update method.
type TableClientUpdateResponse ¶ added in v0.3.0
type TableClientUpdateResponse struct { TableClientUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TableClientUpdateResponse contains the response from method TableClient.Update.
type TableClientUpdateResult ¶ added in v0.3.0
type TableClientUpdateResult struct {
Table
}
TableClientUpdateResult contains the result from method TableClient.Update.
type TableProperties ¶
type TableProperties struct { // READ-ONLY; Table name under the specified account TableName *string `json:"tableName,omitempty" azure:"ro"` }
type TableServiceProperties ¶
type TableServiceProperties struct { // The properties of a storage account’s Table service. TableServiceProperties *TableServicePropertiesProperties `json:"properties,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
TableServiceProperties - The properties of a storage account’s Table service.
type TableServicePropertiesProperties ¶
type TableServicePropertiesProperties struct { // Specifies CORS rules for the Table service. You can include up to five CorsRule elements in the request. If no CorsRule // elements are included in the request body, all CORS rules will be deleted, and // CORS will be disabled for the Table service. Cors *CorsRules `json:"cors,omitempty"` }
TableServicePropertiesProperties - The properties of a storage account’s Table service.
type TableServicesClient ¶
type TableServicesClient struct {
// contains filtered or unexported fields
}
TableServicesClient contains the methods for the TableServices group. Don't use this type directly, use NewTableServicesClient() instead.
func NewTableServicesClient ¶
func NewTableServicesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *TableServicesClient
NewTableServicesClient creates a new instance of TableServicesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*TableServicesClient) GetServiceProperties ¶
func (client *TableServicesClient) GetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, options *TableServicesClientGetServicePropertiesOptions) (TableServicesClientGetServicePropertiesResponse, error)
GetServiceProperties - Gets the properties of a storage account’s Table service, including properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - TableServicesClientGetServicePropertiesOptions contains the optional parameters for the TableServicesClient.GetServiceProperties method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/TableServicesGet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewTableServicesClient("<subscription-id>", cred, nil) res, err := client.GetServiceProperties(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.TableServicesClientGetServicePropertiesResult) }
Output:
func (*TableServicesClient) List ¶
func (client *TableServicesClient) List(ctx context.Context, resourceGroupName string, accountName string, options *TableServicesClientListOptions) (TableServicesClientListResponse, error)
List - List all table services for the storage account. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. options - TableServicesClientListOptions contains the optional parameters for the TableServicesClient.List method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/TableServicesList.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewTableServicesClient("<subscription-id>", cred, nil) res, err := client.List(ctx, "<resource-group-name>", "<account-name>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.TableServicesClientListResult) }
Output:
func (*TableServicesClient) SetServiceProperties ¶
func (client *TableServicesClient) SetServiceProperties(ctx context.Context, resourceGroupName string, accountName string, parameters TableServiceProperties, options *TableServicesClientSetServicePropertiesOptions) (TableServicesClientSetServicePropertiesResponse, error)
SetServiceProperties - Sets the properties of a storage account’s Table service, including properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules. If the operation fails it returns an *azcore.ResponseError type. resourceGroupName - The name of the resource group within the user's subscription. The name is case insensitive. accountName - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. parameters - The properties of a storage account’s Table service, only properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules can be specified. options - TableServicesClientSetServicePropertiesOptions contains the optional parameters for the TableServicesClient.SetServiceProperties method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/TableServicesPut.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewTableServicesClient("<subscription-id>", cred, nil) res, err := client.SetServiceProperties(ctx, "<resource-group-name>", "<account-name>", armstorage.TableServiceProperties{ TableServiceProperties: &armstorage.TableServicePropertiesProperties{ Cors: &armstorage.CorsRules{ CorsRules: []*armstorage.CorsRule{ { AllowedHeaders: []*string{ to.StringPtr("x-ms-meta-abc"), to.StringPtr("x-ms-meta-data*"), to.StringPtr("x-ms-meta-target*")}, AllowedMethods: []*armstorage.CorsRuleAllowedMethodsItem{ armstorage.CorsRuleAllowedMethodsItem("GET").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("HEAD").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("POST").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("OPTIONS").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("MERGE").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("PUT").ToPtr()}, AllowedOrigins: []*string{ to.StringPtr("http://www.contoso.com"), to.StringPtr("http://www.fabrikam.com")}, ExposedHeaders: []*string{ to.StringPtr("x-ms-meta-*")}, MaxAgeInSeconds: to.Int32Ptr(100), }, { AllowedHeaders: []*string{ to.StringPtr("*")}, AllowedMethods: []*armstorage.CorsRuleAllowedMethodsItem{ armstorage.CorsRuleAllowedMethodsItem("GET").ToPtr()}, AllowedOrigins: []*string{ to.StringPtr("*")}, ExposedHeaders: []*string{ to.StringPtr("*")}, MaxAgeInSeconds: to.Int32Ptr(2), }, { AllowedHeaders: []*string{ to.StringPtr("x-ms-meta-12345675754564*")}, AllowedMethods: []*armstorage.CorsRuleAllowedMethodsItem{ armstorage.CorsRuleAllowedMethodsItem("GET").ToPtr(), armstorage.CorsRuleAllowedMethodsItem("PUT").ToPtr()}, AllowedOrigins: []*string{ to.StringPtr("http://www.abc23.com"), to.StringPtr("https://www.fabrikam.com/*")}, ExposedHeaders: []*string{ to.StringPtr("x-ms-meta-abc"), to.StringPtr("x-ms-meta-data*"), to.StringPtr("x-ms-meta-target*")}, MaxAgeInSeconds: to.Int32Ptr(2000), }}, }, }, }, nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.TableServicesClientSetServicePropertiesResult) }
Output:
type TableServicesClientGetServicePropertiesOptions ¶ added in v0.3.0
type TableServicesClientGetServicePropertiesOptions struct { }
TableServicesClientGetServicePropertiesOptions contains the optional parameters for the TableServicesClient.GetServiceProperties method.
type TableServicesClientGetServicePropertiesResponse ¶ added in v0.3.0
type TableServicesClientGetServicePropertiesResponse struct { TableServicesClientGetServicePropertiesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TableServicesClientGetServicePropertiesResponse contains the response from method TableServicesClient.GetServiceProperties.
type TableServicesClientGetServicePropertiesResult ¶ added in v0.3.0
type TableServicesClientGetServicePropertiesResult struct {
TableServiceProperties
}
TableServicesClientGetServicePropertiesResult contains the result from method TableServicesClient.GetServiceProperties.
type TableServicesClientListOptions ¶ added in v0.3.0
type TableServicesClientListOptions struct { }
TableServicesClientListOptions contains the optional parameters for the TableServicesClient.List method.
type TableServicesClientListResponse ¶ added in v0.3.0
type TableServicesClientListResponse struct { TableServicesClientListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TableServicesClientListResponse contains the response from method TableServicesClient.List.
type TableServicesClientListResult ¶ added in v0.3.0
type TableServicesClientListResult struct {
ListTableServices
}
TableServicesClientListResult contains the result from method TableServicesClient.List.
type TableServicesClientSetServicePropertiesOptions ¶ added in v0.3.0
type TableServicesClientSetServicePropertiesOptions struct { }
TableServicesClientSetServicePropertiesOptions contains the optional parameters for the TableServicesClient.SetServiceProperties method.
type TableServicesClientSetServicePropertiesResponse ¶ added in v0.3.0
type TableServicesClientSetServicePropertiesResponse struct { TableServicesClientSetServicePropertiesResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TableServicesClientSetServicePropertiesResponse contains the response from method TableServicesClient.SetServiceProperties.
type TableServicesClientSetServicePropertiesResult ¶ added in v0.3.0
type TableServicesClientSetServicePropertiesResult struct {
TableServiceProperties
}
TableServicesClientSetServicePropertiesResult contains the result from method TableServicesClient.SetServiceProperties.
type TagFilter ¶
type TagFilter struct { // REQUIRED; This is the filter tag name, it can have 1 - 128 characters Name *string `json:"name,omitempty"` // REQUIRED; This is the comparison operator which is used for object comparison and filtering. Only == (equality operator) // is currently supported Op *string `json:"op,omitempty"` // REQUIRED; This is the filter tag value field used for tag based filtering, it can have 0 - 256 characters Value *string `json:"value,omitempty"` }
TagFilter - Blob index tag based filtering for blob objects
type TagProperty ¶
type TagProperty struct { // READ-ONLY; Returns the Object ID of the user who added the tag. ObjectIdentifier *string `json:"objectIdentifier,omitempty" azure:"ro"` // READ-ONLY; The tag value. Tag *string `json:"tag,omitempty" azure:"ro"` // READ-ONLY; Returns the Tenant ID that issued the token for the user who added the tag. TenantID *string `json:"tenantId,omitempty" azure:"ro"` // READ-ONLY; Returns the date and time the tag was added. Timestamp *time.Time `json:"timestamp,omitempty" azure:"ro"` // READ-ONLY; Returns the User Principal Name of the user who added the tag. Upn *string `json:"upn,omitempty" azure:"ro"` }
TagProperty - A tag of the LegalHold of a blob container.
func (TagProperty) MarshalJSON ¶
func (t TagProperty) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type TagProperty.
func (*TagProperty) UnmarshalJSON ¶
func (t *TagProperty) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type TagProperty.
type TrackedResource ¶
type TrackedResource struct { // REQUIRED; The geo-location where the resource lives Location *string `json:"location,omitempty"` // Resource tags. Tags map[string]*string `json:"tags,omitempty"` // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string `json:"type,omitempty" azure:"ro"` }
TrackedResource - The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location'
func (TrackedResource) MarshalJSON ¶
func (t TrackedResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type TrackedResource.
type UpdateHistoryProperty ¶
type UpdateHistoryProperty struct { // This property can only be changed for unlocked time-based retention policies. When enabled, new blocks can be written to // an append blob while maintaining immutability protection and compliance. Only // new blocks can be added and any existing blocks cannot be modified or deleted. This property cannot be changed with ExtendImmutabilityPolicy // API. AllowProtectedAppendWrites *bool `json:"allowProtectedAppendWrites,omitempty"` // This property can only be changed for unlocked time-based retention policies. When enabled, new blocks can be written to // both 'Append and Bock Blobs' while maintaining immutability protection and // compliance. Only new blocks can be added and any existing blocks cannot be modified or deleted. This property cannot be // changed with ExtendImmutabilityPolicy API. The 'allowProtectedAppendWrites' and // 'allowProtectedAppendWritesAll' properties are mutually exclusive. AllowProtectedAppendWritesAll *bool `json:"allowProtectedAppendWritesAll,omitempty"` // READ-ONLY; The immutability period for the blobs in the container since the policy creation, in days. ImmutabilityPeriodSinceCreationInDays *int32 `json:"immutabilityPeriodSinceCreationInDays,omitempty" azure:"ro"` // READ-ONLY; Returns the Object ID of the user who updated the ImmutabilityPolicy. ObjectIdentifier *string `json:"objectIdentifier,omitempty" azure:"ro"` // READ-ONLY; Returns the Tenant ID that issued the token for the user who updated the ImmutabilityPolicy. TenantID *string `json:"tenantId,omitempty" azure:"ro"` // READ-ONLY; Returns the date and time the ImmutabilityPolicy was updated. Timestamp *time.Time `json:"timestamp,omitempty" azure:"ro"` // READ-ONLY; The ImmutabilityPolicy update type of a blob container, possible values include: put, lock and extend. Update *ImmutabilityPolicyUpdateType `json:"update,omitempty" azure:"ro"` // READ-ONLY; Returns the User Principal Name of the user who updated the ImmutabilityPolicy. Upn *string `json:"upn,omitempty" azure:"ro"` }
UpdateHistoryProperty - An update history of the ImmutabilityPolicy of a blob container.
func (UpdateHistoryProperty) MarshalJSON ¶
func (u UpdateHistoryProperty) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateHistoryProperty.
func (*UpdateHistoryProperty) UnmarshalJSON ¶
func (u *UpdateHistoryProperty) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateHistoryProperty.
type Usage ¶
type Usage struct { // READ-ONLY; Gets the current count of the allocated resources in the subscription. CurrentValue *int32 `json:"currentValue,omitempty" azure:"ro"` // READ-ONLY; Gets the maximum count of the resources that can be allocated in the subscription. Limit *int32 `json:"limit,omitempty" azure:"ro"` // READ-ONLY; Gets the name of the type of usage. Name *UsageName `json:"name,omitempty" azure:"ro"` // READ-ONLY; Gets the unit of measurement. Unit *UsageUnit `json:"unit,omitempty" azure:"ro"` }
Usage - Describes Storage Resource Usage.
type UsageListResult ¶
type UsageListResult struct { // Gets or sets the list of Storage Resource Usages. Value []*Usage `json:"value,omitempty"` }
UsageListResult - The response from the List Usages operation.
func (UsageListResult) MarshalJSON ¶
func (u UsageListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UsageListResult.
type UsageName ¶
type UsageName struct { // READ-ONLY; Gets a localized string describing the resource name. LocalizedValue *string `json:"localizedValue,omitempty" azure:"ro"` // READ-ONLY; Gets a string describing the resource name. Value *string `json:"value,omitempty" azure:"ro"` }
UsageName - The usage names that can be used; currently limited to StorageAccount.
type UsageUnit ¶
type UsageUnit string
UsageUnit - Gets the unit of measurement.
func PossibleUsageUnitValues ¶
func PossibleUsageUnitValues() []UsageUnit
PossibleUsageUnitValues returns the possible values for the UsageUnit const type.
type UsagesClient ¶
type UsagesClient struct {
// contains filtered or unexported fields
}
UsagesClient contains the methods for the Usages group. Don't use this type directly, use NewUsagesClient() instead.
func NewUsagesClient ¶
func NewUsagesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *UsagesClient
NewUsagesClient creates a new instance of UsagesClient with the specified values. subscriptionID - The ID of the target subscription. credential - used to authorize requests. Usually a credential from azidentity. options - pass nil to accept the default values.
func (*UsagesClient) ListByLocation ¶
func (client *UsagesClient) ListByLocation(ctx context.Context, location string, options *UsagesClientListByLocationOptions) (UsagesClientListByLocationResponse, error)
ListByLocation - Gets the current usage count and the limit for the resources of the location under the subscription. If the operation fails it returns an *azcore.ResponseError type. location - The location of the Azure Storage resource. options - UsagesClientListByLocationOptions contains the optional parameters for the UsagesClient.ListByLocation method.
Example ¶
x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2021-08-01/examples/StorageAccountListLocationUsage.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armstorage.NewUsagesClient("<subscription-id>", cred, nil) res, err := client.ListByLocation(ctx, "<location>", nil) if err != nil { log.Fatal(err) } log.Printf("Response result: %#v\n", res.UsagesClientListByLocationResult) }
Output:
type UsagesClientListByLocationOptions ¶ added in v0.3.0
type UsagesClientListByLocationOptions struct { }
UsagesClientListByLocationOptions contains the optional parameters for the UsagesClient.ListByLocation method.
type UsagesClientListByLocationResponse ¶ added in v0.3.0
type UsagesClientListByLocationResponse struct { UsagesClientListByLocationResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
UsagesClientListByLocationResponse contains the response from method UsagesClient.ListByLocation.
type UsagesClientListByLocationResult ¶ added in v0.3.0
type UsagesClientListByLocationResult struct {
UsageListResult
}
UsagesClientListByLocationResult contains the result from method UsagesClient.ListByLocation.
type UserAssignedIdentity ¶
type UserAssignedIdentity struct { // READ-ONLY; The client ID of the identity. ClientID *string `json:"clientId,omitempty" azure:"ro"` // READ-ONLY; The principal ID of the identity. PrincipalID *string `json:"principalId,omitempty" azure:"ro"` }
UserAssignedIdentity for the resource.
type VirtualNetworkRule ¶
type VirtualNetworkRule struct { // REQUIRED; Resource ID of a subnet, for example: /subscriptions/{subscriptionId}/resourceGroups/{groupName}/providers/Microsoft.Network/virtualNetworks/{vnetName}/subnets/{subnetName}. VirtualNetworkResourceID *string `json:"id,omitempty"` // The action of virtual network rule. Action *string `json:"action,omitempty"` // Gets the state of virtual network rule. State *State `json:"state,omitempty"` }
VirtualNetworkRule - Virtual Network rule.
Source Files ¶
- build.go
- zz_generated_accounts_client.go
- zz_generated_blobcontainers_client.go
- zz_generated_blobinventorypolicies_client.go
- zz_generated_blobservices_client.go
- zz_generated_constants.go
- zz_generated_deletedaccounts_client.go
- zz_generated_encryptionscopes_client.go
- zz_generated_fileservices_client.go
- zz_generated_fileshares_client.go
- zz_generated_localusers_client.go
- zz_generated_managementpolicies_client.go
- zz_generated_models.go
- zz_generated_objectreplicationpolicies_client.go
- zz_generated_operations_client.go
- zz_generated_pagers.go
- zz_generated_pollers.go
- zz_generated_privateendpointconnections_client.go
- zz_generated_privatelinkresources_client.go
- zz_generated_queue_client.go
- zz_generated_queueservices_client.go
- zz_generated_response_types.go
- zz_generated_skus_client.go
- zz_generated_table_client.go
- zz_generated_tableservices_client.go
- zz_generated_time_rfc3339.go
- zz_generated_usages_client.go