galleries

package
v0.20230523.1080931 Latest Latest
Warning

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

Go to latest
Published: May 23, 2023 License: MPL-2.0 Imports: 10 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/compute/2022-03-03/galleries Documentation

The galleries SDK allows for interaction with the Azure Resource Manager Service compute (API Version 2022-03-03).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/compute/2022-03-03/galleries"

Client Initialization

client := galleries.NewGalleriesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: GalleriesClient.CreateOrUpdate

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

payload := galleries.Gallery{
	// ...
}


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

Example Usage: GalleriesClient.Delete

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

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

Example Usage: GalleriesClient.Get

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

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

Example Usage: GalleriesClient.List

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

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

Example Usage: GalleriesClient.ListByResourceGroup

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

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

Example Usage: GalleriesClient.Update

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

payload := galleries.GalleryUpdate{
	// ...
}


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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForGalleryExpandParams

func PossibleValuesForGalleryExpandParams() []string

func PossibleValuesForGalleryProvisioningState

func PossibleValuesForGalleryProvisioningState() []string

func PossibleValuesForGallerySharingPermissionTypes

func PossibleValuesForGallerySharingPermissionTypes() []string

func PossibleValuesForSelectPermissions

func PossibleValuesForSelectPermissions() []string

func PossibleValuesForSharingProfileGroupTypes

func PossibleValuesForSharingProfileGroupTypes() []string

func PossibleValuesForSharingState

func PossibleValuesForSharingState() []string

func ValidateGalleryID

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

ValidateGalleryID checks that 'input' can be parsed as a Gallery ID

Types

type CommunityGalleryInfo

type CommunityGalleryInfo struct {
	CommunityGalleryEnabled *bool     `json:"communityGalleryEnabled,omitempty"`
	Eula                    *string   `json:"eula,omitempty"`
	PublicNamePrefix        *string   `json:"publicNamePrefix,omitempty"`
	PublicNames             *[]string `json:"publicNames,omitempty"`
	PublisherContact        *string   `json:"publisherContact,omitempty"`
	PublisherUri            *string   `json:"publisherUri,omitempty"`
}

type CreateOrUpdateOperationResponse

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

type DeleteOperationResponse

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

type GalleriesClient

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

func NewGalleriesClientWithBaseURI

func NewGalleriesClientWithBaseURI(endpoint string) GalleriesClient

func (GalleriesClient) CreateOrUpdate

func (c GalleriesClient) CreateOrUpdate(ctx context.Context, id GalleryId, input Gallery) (result CreateOrUpdateOperationResponse, err error)

CreateOrUpdate ...

func (GalleriesClient) CreateOrUpdateThenPoll

func (c GalleriesClient) CreateOrUpdateThenPoll(ctx context.Context, id GalleryId, input Gallery) error

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (GalleriesClient) Delete

func (c GalleriesClient) Delete(ctx context.Context, id GalleryId) (result DeleteOperationResponse, err error)

Delete ...

func (GalleriesClient) DeleteThenPoll

func (c GalleriesClient) DeleteThenPoll(ctx context.Context, id GalleryId) error

DeleteThenPoll performs Delete then polls until it's completed

func (GalleriesClient) Get

Get ...

func (GalleriesClient) List

List ...

func (GalleriesClient) ListByResourceGroup

ListByResourceGroup ...

func (GalleriesClient) ListByResourceGroupComplete

ListByResourceGroupComplete retrieves all of the results into a single object

func (GalleriesClient) ListByResourceGroupCompleteMatchingPredicate

func (c GalleriesClient) ListByResourceGroupCompleteMatchingPredicate(ctx context.Context, id commonids.ResourceGroupId, predicate GalleryOperationPredicate) (resp ListByResourceGroupCompleteResult, err error)

ListByResourceGroupCompleteMatchingPredicate retrieves all of the results and then applied the predicate

func (GalleriesClient) ListComplete

ListComplete retrieves all of the results into a single object

func (GalleriesClient) ListCompleteMatchingPredicate

func (c GalleriesClient) ListCompleteMatchingPredicate(ctx context.Context, id commonids.SubscriptionId, predicate GalleryOperationPredicate) (resp ListCompleteResult, err error)

ListCompleteMatchingPredicate retrieves all of the results and then applied the predicate

func (GalleriesClient) Update

func (c GalleriesClient) Update(ctx context.Context, id GalleryId, input GalleryUpdate) (result UpdateOperationResponse, err error)

Update ...

func (GalleriesClient) UpdateThenPoll

func (c GalleriesClient) UpdateThenPoll(ctx context.Context, id GalleryId, input GalleryUpdate) error

UpdateThenPoll performs Update then polls until it's completed

type Gallery struct {
	Id         *string            `json:"id,omitempty"`
	Location   string             `json:"location"`
	Name       *string            `json:"name,omitempty"`
	Properties *GalleryProperties `json:"properties,omitempty"`
	Tags       *map[string]string `json:"tags,omitempty"`
	Type       *string            `json:"type,omitempty"`
}

type GalleryExpandParams

type GalleryExpandParams string
const (
	GalleryExpandParamsSharingProfileGroups GalleryExpandParams = "SharingProfile/Groups"
)

type GalleryId

type GalleryId struct {
	SubscriptionId    string
	ResourceGroupName string
	GalleryName       string
}

GalleryId is a struct representing the Resource ID for a Gallery

func NewGalleryID

func NewGalleryID(subscriptionId string, resourceGroupName string, galleryName string) GalleryId

NewGalleryID returns a new GalleryId struct

func ParseGalleryID

func ParseGalleryID(input string) (*GalleryId, error)

ParseGalleryID parses 'input' into a GalleryId

func ParseGalleryIDInsensitively

func ParseGalleryIDInsensitively(input string) (*GalleryId, error)

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

func (GalleryId) ID

func (id GalleryId) ID() string

ID returns the formatted Gallery ID

func (GalleryId) Segments

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

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

func (GalleryId) String

func (id GalleryId) String() string

String returns a human-readable description of this Gallery ID

type GalleryIdentifier

type GalleryIdentifier struct {
	UniqueName *string `json:"uniqueName,omitempty"`
}

type GalleryOperationPredicate

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

func (GalleryOperationPredicate) Matches

func (p GalleryOperationPredicate) Matches(input Gallery) bool

type GalleryProperties

type GalleryProperties struct {
	Description       *string                   `json:"description,omitempty"`
	Identifier        *GalleryIdentifier        `json:"identifier,omitempty"`
	ProvisioningState *GalleryProvisioningState `json:"provisioningState,omitempty"`
	SharingProfile    *SharingProfile           `json:"sharingProfile,omitempty"`
	SharingStatus     *SharingStatus            `json:"sharingStatus,omitempty"`
	SoftDeletePolicy  *SoftDeletePolicy         `json:"softDeletePolicy,omitempty"`
}

type GalleryProvisioningState

type GalleryProvisioningState string
const (
	GalleryProvisioningStateCreating  GalleryProvisioningState = "Creating"
	GalleryProvisioningStateDeleting  GalleryProvisioningState = "Deleting"
	GalleryProvisioningStateFailed    GalleryProvisioningState = "Failed"
	GalleryProvisioningStateMigrating GalleryProvisioningState = "Migrating"
	GalleryProvisioningStateSucceeded GalleryProvisioningState = "Succeeded"
	GalleryProvisioningStateUpdating  GalleryProvisioningState = "Updating"
)

type GallerySharingPermissionTypes

type GallerySharingPermissionTypes string
const (
	GallerySharingPermissionTypesCommunity GallerySharingPermissionTypes = "Community"
	GallerySharingPermissionTypesGroups    GallerySharingPermissionTypes = "Groups"
	GallerySharingPermissionTypesPrivate   GallerySharingPermissionTypes = "Private"
)

type GalleryUpdate

type GalleryUpdate struct {
	Id         *string            `json:"id,omitempty"`
	Name       *string            `json:"name,omitempty"`
	Properties *GalleryProperties `json:"properties,omitempty"`
	Tags       *map[string]string `json:"tags,omitempty"`
	Type       *string            `json:"type,omitempty"`
}

type GetOperationOptions

type GetOperationOptions struct {
	Expand *GalleryExpandParams
	Select *SelectPermissions
}

func DefaultGetOperationOptions

func DefaultGetOperationOptions() GetOperationOptions

type GetOperationResponse

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

type ListByResourceGroupCompleteResult

type ListByResourceGroupCompleteResult struct {
	Items []Gallery
}

type ListByResourceGroupOperationResponse

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

func (ListByResourceGroupOperationResponse) HasMore

func (ListByResourceGroupOperationResponse) LoadMore

type ListCompleteResult

type ListCompleteResult struct {
	Items []Gallery
}

type ListOperationResponse

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

func (ListOperationResponse) HasMore

func (r ListOperationResponse) HasMore() bool

func (ListOperationResponse) LoadMore

func (r ListOperationResponse) LoadMore(ctx context.Context) (resp ListOperationResponse, err error)

type RegionalSharingStatus

type RegionalSharingStatus struct {
	Details *string       `json:"details,omitempty"`
	Region  *string       `json:"region,omitempty"`
	State   *SharingState `json:"state,omitempty"`
}

type SelectPermissions

type SelectPermissions string
const (
	SelectPermissionsPermissions SelectPermissions = "Permissions"
)

type SharingProfile

type SharingProfile struct {
	CommunityGalleryInfo *CommunityGalleryInfo          `json:"communityGalleryInfo,omitempty"`
	Groups               *[]SharingProfileGroup         `json:"groups,omitempty"`
	Permissions          *GallerySharingPermissionTypes `json:"permissions,omitempty"`
}

type SharingProfileGroup

type SharingProfileGroup struct {
	Ids  *[]string                 `json:"ids,omitempty"`
	Type *SharingProfileGroupTypes `json:"type,omitempty"`
}

type SharingProfileGroupTypes

type SharingProfileGroupTypes string
const (
	SharingProfileGroupTypesAADTenants    SharingProfileGroupTypes = "AADTenants"
	SharingProfileGroupTypesSubscriptions SharingProfileGroupTypes = "Subscriptions"
)

type SharingState

type SharingState string
const (
	SharingStateFailed     SharingState = "Failed"
	SharingStateInProgress SharingState = "InProgress"
	SharingStateSucceeded  SharingState = "Succeeded"
	SharingStateUnknown    SharingState = "Unknown"
)

type SharingStatus

type SharingStatus struct {
	AggregatedState *SharingState            `json:"aggregatedState,omitempty"`
	Summary         *[]RegionalSharingStatus `json:"summary,omitempty"`
}

type SoftDeletePolicy

type SoftDeletePolicy struct {
	IsSoftDeleteEnabled *bool `json:"isSoftDeleteEnabled,omitempty"`
}

type UpdateOperationResponse

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

Jump to

Keyboard shortcuts

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