namespacetopics

package
v0.20240320.1144505 Latest Latest
Warning

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

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

README

github.com/hashicorp/go-azure-sdk/resource-manager/eventgrid/2023-12-15-preview/namespacetopics Documentation

The namespacetopics SDK allows for interaction with the Azure Resource Manager Service eventgrid (API Version 2023-12-15-preview).

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

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/eventgrid/2023-12-15-preview/namespacetopics"

Client Initialization

client := namespacetopics.NewNamespaceTopicsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: NamespaceTopicsClient.CreateOrUpdate

ctx := context.TODO()
id := namespacetopics.NewNamespaceTopicID("12345678-1234-9876-4563-123456789012", "example-resource-group", "namespaceValue", "topicValue")

payload := namespacetopics.NamespaceTopic{
	// ...
}


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

Example Usage: NamespaceTopicsClient.Delete

ctx := context.TODO()
id := namespacetopics.NewNamespaceTopicID("12345678-1234-9876-4563-123456789012", "example-resource-group", "namespaceValue", "topicValue")

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

Example Usage: NamespaceTopicsClient.Get

ctx := context.TODO()
id := namespacetopics.NewNamespaceTopicID("12345678-1234-9876-4563-123456789012", "example-resource-group", "namespaceValue", "topicValue")

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

Example Usage: NamespaceTopicsClient.ListByNamespace

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

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

Example Usage: NamespaceTopicsClient.ListSharedAccessKeys

ctx := context.TODO()
id := namespacetopics.NewNamespaceTopicID("12345678-1234-9876-4563-123456789012", "example-resource-group", "namespaceValue", "topicValue")

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

Example Usage: NamespaceTopicsClient.RegenerateKey

ctx := context.TODO()
id := namespacetopics.NewNamespaceTopicID("12345678-1234-9876-4563-123456789012", "example-resource-group", "namespaceValue", "topicValue")

payload := namespacetopics.TopicRegenerateKeyRequest{
	// ...
}


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

Example Usage: NamespaceTopicsClient.Update

ctx := context.TODO()
id := namespacetopics.NewNamespaceTopicID("12345678-1234-9876-4563-123456789012", "example-resource-group", "namespaceValue", "topicValue")

payload := namespacetopics.NamespaceTopicUpdateParameters{
	// ...
}


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 PossibleValuesForEventInputSchema

func PossibleValuesForEventInputSchema() []string

func PossibleValuesForNamespaceTopicProvisioningState

func PossibleValuesForNamespaceTopicProvisioningState() []string

func PossibleValuesForPublisherType

func PossibleValuesForPublisherType() []string

func ValidateNamespaceID

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

ValidateNamespaceID checks that 'input' can be parsed as a Namespace ID

func ValidateNamespaceTopicID

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

ValidateNamespaceTopicID checks that 'input' can be parsed as a Namespace Topic ID

Types

type CreateOrUpdateOperationResponse

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

type DeleteOperationResponse

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

type EventInputSchema

type EventInputSchema string
const (
	EventInputSchemaCloudEventSchemaVOneZero EventInputSchema = "CloudEventSchemaV1_0"
)

func (*EventInputSchema) UnmarshalJSON

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

type GetOperationResponse

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

type ListByNamespaceCompleteResult

type ListByNamespaceCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []NamespaceTopic
}

type ListByNamespaceOperationOptions

type ListByNamespaceOperationOptions struct {
	Filter *string
	Top    *int64
}

func DefaultListByNamespaceOperationOptions

func DefaultListByNamespaceOperationOptions() ListByNamespaceOperationOptions

func (ListByNamespaceOperationOptions) ToHeaders

func (ListByNamespaceOperationOptions) ToOData

func (ListByNamespaceOperationOptions) ToQuery

type ListByNamespaceOperationResponse

type ListByNamespaceOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]NamespaceTopic
}

type ListSharedAccessKeysOperationResponse

type ListSharedAccessKeysOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *TopicSharedAccessKeys
}

type NamespaceId

type NamespaceId struct {
	SubscriptionId    string
	ResourceGroupName string
	NamespaceName     string
}

NamespaceId is a struct representing the Resource ID for a Namespace

func NewNamespaceID

func NewNamespaceID(subscriptionId string, resourceGroupName string, namespaceName string) NamespaceId

NewNamespaceID returns a new NamespaceId struct

func ParseNamespaceID

func ParseNamespaceID(input string) (*NamespaceId, error)

ParseNamespaceID parses 'input' into a NamespaceId

func ParseNamespaceIDInsensitively

func ParseNamespaceIDInsensitively(input string) (*NamespaceId, error)

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

func (*NamespaceId) FromParseResult

func (id *NamespaceId) FromParseResult(input resourceids.ParseResult) error

func (NamespaceId) ID

func (id NamespaceId) ID() string

ID returns the formatted Namespace ID

func (NamespaceId) Segments

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

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

func (NamespaceId) String

func (id NamespaceId) String() string

String returns a human-readable description of this Namespace ID

type NamespaceTopic

type NamespaceTopic struct {
	Id         *string                   `json:"id,omitempty"`
	Name       *string                   `json:"name,omitempty"`
	Properties *NamespaceTopicProperties `json:"properties,omitempty"`
	SystemData *systemdata.SystemData    `json:"systemData,omitempty"`
	Type       *string                   `json:"type,omitempty"`
}

type NamespaceTopicId

type NamespaceTopicId struct {
	SubscriptionId    string
	ResourceGroupName string
	NamespaceName     string
	TopicName         string
}

NamespaceTopicId is a struct representing the Resource ID for a Namespace Topic

func NewNamespaceTopicID

func NewNamespaceTopicID(subscriptionId string, resourceGroupName string, namespaceName string, topicName string) NamespaceTopicId

NewNamespaceTopicID returns a new NamespaceTopicId struct

func ParseNamespaceTopicID

func ParseNamespaceTopicID(input string) (*NamespaceTopicId, error)

ParseNamespaceTopicID parses 'input' into a NamespaceTopicId

func ParseNamespaceTopicIDInsensitively

func ParseNamespaceTopicIDInsensitively(input string) (*NamespaceTopicId, error)

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

func (*NamespaceTopicId) FromParseResult

func (id *NamespaceTopicId) FromParseResult(input resourceids.ParseResult) error

func (NamespaceTopicId) ID

func (id NamespaceTopicId) ID() string

ID returns the formatted Namespace Topic ID

func (NamespaceTopicId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Namespace Topic ID

func (NamespaceTopicId) String

func (id NamespaceTopicId) String() string

String returns a human-readable description of this Namespace Topic ID

type NamespaceTopicOperationPredicate

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

func (NamespaceTopicOperationPredicate) Matches

type NamespaceTopicProperties

type NamespaceTopicProperties struct {
	EventRetentionInDays *int64                           `json:"eventRetentionInDays,omitempty"`
	InputSchema          *EventInputSchema                `json:"inputSchema,omitempty"`
	ProvisioningState    *NamespaceTopicProvisioningState `json:"provisioningState,omitempty"`
	PublisherType        *PublisherType                   `json:"publisherType,omitempty"`
}

type NamespaceTopicProvisioningState

type NamespaceTopicProvisioningState string
const (
	NamespaceTopicProvisioningStateCanceled      NamespaceTopicProvisioningState = "Canceled"
	NamespaceTopicProvisioningStateCreateFailed  NamespaceTopicProvisioningState = "CreateFailed"
	NamespaceTopicProvisioningStateCreating      NamespaceTopicProvisioningState = "Creating"
	NamespaceTopicProvisioningStateDeleteFailed  NamespaceTopicProvisioningState = "DeleteFailed"
	NamespaceTopicProvisioningStateDeleted       NamespaceTopicProvisioningState = "Deleted"
	NamespaceTopicProvisioningStateDeleting      NamespaceTopicProvisioningState = "Deleting"
	NamespaceTopicProvisioningStateFailed        NamespaceTopicProvisioningState = "Failed"
	NamespaceTopicProvisioningStateSucceeded     NamespaceTopicProvisioningState = "Succeeded"
	NamespaceTopicProvisioningStateUpdatedFailed NamespaceTopicProvisioningState = "UpdatedFailed"
	NamespaceTopicProvisioningStateUpdating      NamespaceTopicProvisioningState = "Updating"
)

func (*NamespaceTopicProvisioningState) UnmarshalJSON

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

type NamespaceTopicUpdateParameterProperties

type NamespaceTopicUpdateParameterProperties struct {
	EventRetentionInDays *int64 `json:"eventRetentionInDays,omitempty"`
}

type NamespaceTopicUpdateParameters

type NamespaceTopicUpdateParameters struct {
	Properties *NamespaceTopicUpdateParameterProperties `json:"properties,omitempty"`
}

type NamespaceTopicsClient

type NamespaceTopicsClient struct {
	Client *resourcemanager.Client
}

func NewNamespaceTopicsClientWithBaseURI

func NewNamespaceTopicsClientWithBaseURI(sdkApi sdkEnv.Api) (*NamespaceTopicsClient, error)

func (NamespaceTopicsClient) CreateOrUpdate

CreateOrUpdate ...

func (NamespaceTopicsClient) CreateOrUpdateThenPoll

func (c NamespaceTopicsClient) CreateOrUpdateThenPoll(ctx context.Context, id NamespaceTopicId, input NamespaceTopic) error

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (NamespaceTopicsClient) Delete

Delete ...

func (NamespaceTopicsClient) DeleteThenPoll

func (c NamespaceTopicsClient) DeleteThenPoll(ctx context.Context, id NamespaceTopicId) error

DeleteThenPoll performs Delete then polls until it's completed

func (NamespaceTopicsClient) Get

Get ...

func (NamespaceTopicsClient) ListByNamespace

ListByNamespace ...

func (NamespaceTopicsClient) ListByNamespaceComplete

ListByNamespaceComplete retrieves all the results into a single object

func (NamespaceTopicsClient) ListByNamespaceCompleteMatchingPredicate

func (c NamespaceTopicsClient) ListByNamespaceCompleteMatchingPredicate(ctx context.Context, id NamespaceId, options ListByNamespaceOperationOptions, predicate NamespaceTopicOperationPredicate) (result ListByNamespaceCompleteResult, err error)

ListByNamespaceCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (NamespaceTopicsClient) ListSharedAccessKeys

ListSharedAccessKeys ...

func (NamespaceTopicsClient) RegenerateKey

RegenerateKey ...

func (NamespaceTopicsClient) RegenerateKeyThenPoll

func (c NamespaceTopicsClient) RegenerateKeyThenPoll(ctx context.Context, id NamespaceTopicId, input TopicRegenerateKeyRequest) error

RegenerateKeyThenPoll performs RegenerateKey then polls until it's completed

func (NamespaceTopicsClient) Update

Update ...

func (NamespaceTopicsClient) UpdateThenPoll

UpdateThenPoll performs Update then polls until it's completed

type PublisherType

type PublisherType string
const (
	PublisherTypeCustom PublisherType = "Custom"
)

func (*PublisherType) UnmarshalJSON

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

type RegenerateKeyOperationResponse

type RegenerateKeyOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *TopicSharedAccessKeys
}

type TopicRegenerateKeyRequest

type TopicRegenerateKeyRequest struct {
	KeyName string `json:"keyName"`
}

type TopicSharedAccessKeys

type TopicSharedAccessKeys struct {
	Key1 *string `json:"key1,omitempty"`
	Key2 *string `json:"key2,omitempty"`
}

type UpdateOperationResponse

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

Jump to

Keyboard shortcuts

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