oraclesubscriptions

package
v0.20241017.1093842 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2024 License: MPL-2.0 Imports: 14 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/oracledatabase/2024-06-01/oraclesubscriptions Documentation

The oraclesubscriptions SDK allows for interaction with Azure Resource Manager oracledatabase (API Version 2024-06-01).

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

Import Path

import "github.com/hashicorp/go-azure-helpers/resourcemanager/commonids"
import "github.com/hashicorp/go-azure-sdk/resource-manager/oracledatabase/2024-06-01/oraclesubscriptions"

Client Initialization

client := oraclesubscriptions.NewOracleSubscriptionsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: OracleSubscriptionsClient.AddAzureSubscriptions

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

payload := oraclesubscriptions.AzureSubscriptions{
	// ...
}


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

Example Usage: OracleSubscriptionsClient.CreateOrUpdate

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

payload := oraclesubscriptions.OracleSubscription{
	// ...
}


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

Example Usage: OracleSubscriptionsClient.Delete

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

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

Example Usage: OracleSubscriptionsClient.Get

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

read, err := client.Get(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}
ctx := context.TODO()
id := commonids.NewSubscriptionID("12345678-1234-9876-4563-123456789012")

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

Example Usage: OracleSubscriptionsClient.ListBySubscription

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

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

Example Usage: OracleSubscriptionsClient.ListCloudAccountDetails

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

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

Example Usage: OracleSubscriptionsClient.ListSaasSubscriptionDetails

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

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

Example Usage: OracleSubscriptionsClient.Update

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

payload := oraclesubscriptions.OracleSubscriptionUpdate{
	// ...
}


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 PossibleValuesForAddSubscriptionOperationState

func PossibleValuesForAddSubscriptionOperationState() []string

func PossibleValuesForCloudAccountProvisioningState

func PossibleValuesForCloudAccountProvisioningState() []string

func PossibleValuesForIntent

func PossibleValuesForIntent() []string

func PossibleValuesForOracleSubscriptionProvisioningState

func PossibleValuesForOracleSubscriptionProvisioningState() []string

Types

type ActivationLinks struct {
	ExistingCloudAccountActivationLink *string `json:"existingCloudAccountActivationLink,omitempty"`
	NewCloudAccountActivationLink      *string `json:"newCloudAccountActivationLink,omitempty"`
}

type AddAzureSubscriptionsOperationResponse

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

type AddSubscriptionOperationState

type AddSubscriptionOperationState string
const (
	AddSubscriptionOperationStateFailed    AddSubscriptionOperationState = "Failed"
	AddSubscriptionOperationStateSucceeded AddSubscriptionOperationState = "Succeeded"
	AddSubscriptionOperationStateUpdating  AddSubscriptionOperationState = "Updating"
)

func (*AddSubscriptionOperationState) UnmarshalJSON

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

type AzureSubscriptions

type AzureSubscriptions struct {
	AzureSubscriptionIds []string `json:"azureSubscriptionIds"`
}

type CloudAccountDetails

type CloudAccountDetails struct {
	CloudAccountHomeRegion *string `json:"cloudAccountHomeRegion,omitempty"`
	CloudAccountName       *string `json:"cloudAccountName,omitempty"`
}

type CloudAccountProvisioningState

type CloudAccountProvisioningState string
const (
	CloudAccountProvisioningStateAvailable    CloudAccountProvisioningState = "Available"
	CloudAccountProvisioningStatePending      CloudAccountProvisioningState = "Pending"
	CloudAccountProvisioningStateProvisioning CloudAccountProvisioningState = "Provisioning"
)

func (*CloudAccountProvisioningState) UnmarshalJSON

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

type CreateOrUpdateOperationResponse

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

type DeleteOperationResponse

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

type GetOperationResponse

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

type Intent

type Intent string
const (
	IntentReset  Intent = "Reset"
	IntentRetain Intent = "Retain"
)

func (*Intent) UnmarshalJSON

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

type ListActivationLinksOperationResponse

type ListActivationLinksOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ActivationLinks
}

type ListBySubscriptionCompleteResult

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

type ListBySubscriptionCustomPager

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

type ListBySubscriptionOperationResponse

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

type ListCloudAccountDetailsOperationResponse

type ListCloudAccountDetailsOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *CloudAccountDetails
}

type ListSaasSubscriptionDetailsOperationResponse

type ListSaasSubscriptionDetailsOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *SaasSubscriptionDetails
}

type OracleSubscription

type OracleSubscription struct {
	Id         *string                       `json:"id,omitempty"`
	Name       *string                       `json:"name,omitempty"`
	Plan       *Plan                         `json:"plan,omitempty"`
	Properties *OracleSubscriptionProperties `json:"properties,omitempty"`
	SystemData *systemdata.SystemData        `json:"systemData,omitempty"`
	Type       *string                       `json:"type,omitempty"`
}

type OracleSubscriptionOperationPredicate

type OracleSubscriptionOperationPredicate struct {
	Id   *string
	Name *string
	Type *string
}

func (OracleSubscriptionOperationPredicate) Matches

type OracleSubscriptionProperties

type OracleSubscriptionProperties struct {
	AddSubscriptionOperationState *AddSubscriptionOperationState       `json:"addSubscriptionOperationState,omitempty"`
	AzureSubscriptionIds          *[]string                            `json:"azureSubscriptionIds,omitempty"`
	CloudAccountId                *string                              `json:"cloudAccountId,omitempty"`
	CloudAccountState             *CloudAccountProvisioningState       `json:"cloudAccountState,omitempty"`
	Intent                        *Intent                              `json:"intent,omitempty"`
	LastOperationStatusDetail     *string                              `json:"lastOperationStatusDetail,omitempty"`
	ProductCode                   *string                              `json:"productCode,omitempty"`
	ProvisioningState             *OracleSubscriptionProvisioningState `json:"provisioningState,omitempty"`
	SaasSubscriptionId            *string                              `json:"saasSubscriptionId,omitempty"`
	TermUnit                      *string                              `json:"termUnit,omitempty"`
}

type OracleSubscriptionProvisioningState

type OracleSubscriptionProvisioningState string
const (
	OracleSubscriptionProvisioningStateCanceled  OracleSubscriptionProvisioningState = "Canceled"
	OracleSubscriptionProvisioningStateFailed    OracleSubscriptionProvisioningState = "Failed"
	OracleSubscriptionProvisioningStateSucceeded OracleSubscriptionProvisioningState = "Succeeded"
)

func (*OracleSubscriptionProvisioningState) UnmarshalJSON

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

type OracleSubscriptionUpdate

type OracleSubscriptionUpdate struct {
	Plan       *PlanUpdate                         `json:"plan,omitempty"`
	Properties *OracleSubscriptionUpdateProperties `json:"properties,omitempty"`
}

type OracleSubscriptionUpdateProperties

type OracleSubscriptionUpdateProperties struct {
	Intent      *Intent `json:"intent,omitempty"`
	ProductCode *string `json:"productCode,omitempty"`
}

type OracleSubscriptionsClient

type OracleSubscriptionsClient struct {
	Client *resourcemanager.Client
}

func NewOracleSubscriptionsClientWithBaseURI

func NewOracleSubscriptionsClientWithBaseURI(sdkApi sdkEnv.Api) (*OracleSubscriptionsClient, error)

func (OracleSubscriptionsClient) AddAzureSubscriptions

AddAzureSubscriptions ...

func (OracleSubscriptionsClient) AddAzureSubscriptionsThenPoll

func (c OracleSubscriptionsClient) AddAzureSubscriptionsThenPoll(ctx context.Context, id commonids.SubscriptionId, input AzureSubscriptions) error

AddAzureSubscriptionsThenPoll performs AddAzureSubscriptions then polls until it's completed

func (OracleSubscriptionsClient) CreateOrUpdate

CreateOrUpdate ...

func (OracleSubscriptionsClient) CreateOrUpdateThenPoll

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (OracleSubscriptionsClient) Delete

Delete ...

func (OracleSubscriptionsClient) DeleteThenPoll

DeleteThenPoll performs Delete then polls until it's completed

func (OracleSubscriptionsClient) Get

Get ...

ListActivationLinks ...

func (OracleSubscriptionsClient) ListActivationLinksThenPoll

func (c OracleSubscriptionsClient) ListActivationLinksThenPoll(ctx context.Context, id commonids.SubscriptionId) error

ListActivationLinksThenPoll performs ListActivationLinks then polls until it's completed

func (OracleSubscriptionsClient) ListBySubscription

ListBySubscription ...

func (OracleSubscriptionsClient) ListBySubscriptionComplete

ListBySubscriptionComplete retrieves all the results into a single object

func (OracleSubscriptionsClient) ListBySubscriptionCompleteMatchingPredicate

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

ListBySubscriptionCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (OracleSubscriptionsClient) ListCloudAccountDetails

ListCloudAccountDetails ...

func (OracleSubscriptionsClient) ListCloudAccountDetailsThenPoll

func (c OracleSubscriptionsClient) ListCloudAccountDetailsThenPoll(ctx context.Context, id commonids.SubscriptionId) error

ListCloudAccountDetailsThenPoll performs ListCloudAccountDetails then polls until it's completed

func (OracleSubscriptionsClient) ListSaasSubscriptionDetails

ListSaasSubscriptionDetails ...

func (OracleSubscriptionsClient) ListSaasSubscriptionDetailsThenPoll

func (c OracleSubscriptionsClient) ListSaasSubscriptionDetailsThenPoll(ctx context.Context, id commonids.SubscriptionId) error

ListSaasSubscriptionDetailsThenPoll performs ListSaasSubscriptionDetails then polls until it's completed

func (OracleSubscriptionsClient) Update

Update ...

func (OracleSubscriptionsClient) UpdateThenPoll

UpdateThenPoll performs Update then polls until it's completed

type Plan

type Plan struct {
	Name          string  `json:"name"`
	Product       string  `json:"product"`
	PromotionCode *string `json:"promotionCode,omitempty"`
	Publisher     string  `json:"publisher"`
	Version       *string `json:"version,omitempty"`
}

type PlanUpdate

type PlanUpdate struct {
	Name          *string `json:"name,omitempty"`
	Product       *string `json:"product,omitempty"`
	PromotionCode *string `json:"promotionCode,omitempty"`
	Publisher     *string `json:"publisher,omitempty"`
	Version       *string `json:"version,omitempty"`
}

type SaasSubscriptionDetails

type SaasSubscriptionDetails struct {
	Id                     *string `json:"id,omitempty"`
	IsAutoRenew            *bool   `json:"isAutoRenew,omitempty"`
	IsFreeTrial            *bool   `json:"isFreeTrial,omitempty"`
	OfferId                *string `json:"offerId,omitempty"`
	PlanId                 *string `json:"planId,omitempty"`
	PublisherId            *string `json:"publisherId,omitempty"`
	PurchaserEmailId       *string `json:"purchaserEmailId,omitempty"`
	PurchaserTenantId      *string `json:"purchaserTenantId,omitempty"`
	SaasSubscriptionStatus *string `json:"saasSubscriptionStatus,omitempty"`
	SubscriptionName       *string `json:"subscriptionName,omitempty"`
	TermUnit               *string `json:"termUnit,omitempty"`
	TimeCreated            *string `json:"timeCreated,omitempty"`
}

func (*SaasSubscriptionDetails) GetTimeCreatedAsTime

func (o *SaasSubscriptionDetails) GetTimeCreatedAsTime() (*time.Time, error)

func (*SaasSubscriptionDetails) SetTimeCreatedAsTime

func (o *SaasSubscriptionDetails) SetTimeCreatedAsTime(input time.Time)

type UpdateOperationResponse

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

Jump to

Keyboard shortcuts

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