eventsources

package
v0.20240304.1112406 Latest Latest
Warning

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

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

README

github.com/hashicorp/go-azure-sdk/resource-manager/timeseriesinsights/2020-05-15/eventsources Documentation

The eventsources SDK allows for interaction with the Azure Resource Manager Service timeseriesinsights (API Version 2020-05-15).

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/timeseriesinsights/2020-05-15/eventsources"

Client Initialization

client := eventsources.NewEventSourcesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: EventSourcesClient.CreateOrUpdate

ctx := context.TODO()
id := eventsources.NewEventSourceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "environmentValue", "eventSourceValue")

payload := eventsources.EventSourceCreateOrUpdateParameters{
	// ...
}


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

Example Usage: EventSourcesClient.Delete

ctx := context.TODO()
id := eventsources.NewEventSourceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "environmentValue", "eventSourceValue")

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

Example Usage: EventSourcesClient.Get

ctx := context.TODO()
id := eventsources.NewEventSourceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "environmentValue", "eventSourceValue")

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: EventSourcesClient.ListByEnvironment

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

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

Example Usage: EventSourcesClient.Update

ctx := context.TODO()
id := eventsources.NewEventSourceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "environmentValue", "eventSourceValue")

payload := eventsources.EventSourceUpdateParameters{
	// ...
}


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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForEventSourceKind

func PossibleValuesForEventSourceKind() []string

func PossibleValuesForIngressStartAtType

func PossibleValuesForIngressStartAtType() []string

func PossibleValuesForKind

func PossibleValuesForKind() []string

func PossibleValuesForLocalTimestampFormat

func PossibleValuesForLocalTimestampFormat() []string

func PossibleValuesForProvisioningState

func PossibleValuesForProvisioningState() []string

func ValidateEnvironmentID

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

ValidateEnvironmentID checks that 'input' can be parsed as a Environment ID

func ValidateEventSourceID

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

ValidateEventSourceID checks that 'input' can be parsed as a Event Source ID

Types

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *EventSourceResource
}

type DeleteOperationResponse

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

type EnvironmentId

type EnvironmentId struct {
	SubscriptionId    string
	ResourceGroupName string
	EnvironmentName   string
}

EnvironmentId is a struct representing the Resource ID for a Environment

func NewEnvironmentID

func NewEnvironmentID(subscriptionId string, resourceGroupName string, environmentName string) EnvironmentId

NewEnvironmentID returns a new EnvironmentId struct

func ParseEnvironmentID

func ParseEnvironmentID(input string) (*EnvironmentId, error)

ParseEnvironmentID parses 'input' into a EnvironmentId

func ParseEnvironmentIDInsensitively

func ParseEnvironmentIDInsensitively(input string) (*EnvironmentId, error)

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

func (*EnvironmentId) FromParseResult

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

func (EnvironmentId) ID

func (id EnvironmentId) ID() string

ID returns the formatted Environment ID

func (EnvironmentId) Segments

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

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

func (EnvironmentId) String

func (id EnvironmentId) String() string

String returns a human-readable description of this Environment ID

type EventHubEventSourceCommonProperties

type EventHubEventSourceCommonProperties struct {
	ConsumerGroupName     string                    `json:"consumerGroupName"`
	CreationTime          *string                   `json:"creationTime,omitempty"`
	EventHubName          string                    `json:"eventHubName"`
	EventSourceResourceId string                    `json:"eventSourceResourceId"`
	IngressStartAt        *IngressStartAtProperties `json:"ingressStartAt,omitempty"`
	KeyName               string                    `json:"keyName"`
	LocalTimestamp        *LocalTimestamp           `json:"localTimestamp,omitempty"`
	ProvisioningState     *ProvisioningState        `json:"provisioningState,omitempty"`
	ServiceBusNamespace   string                    `json:"serviceBusNamespace"`
	TimestampPropertyName *string                   `json:"timestampPropertyName,omitempty"`
}

func (*EventHubEventSourceCommonProperties) GetCreationTimeAsTime

func (o *EventHubEventSourceCommonProperties) GetCreationTimeAsTime() (*time.Time, error)

func (*EventHubEventSourceCommonProperties) SetCreationTimeAsTime

func (o *EventHubEventSourceCommonProperties) SetCreationTimeAsTime(input time.Time)

type EventHubEventSourceCreateOrUpdateParameters

type EventHubEventSourceCreateOrUpdateParameters struct {
	Properties EventHubEventSourceCreationProperties `json:"properties"`

	// Fields inherited from EventSourceCreateOrUpdateParameters
	LocalTimestamp *LocalTimestamp    `json:"localTimestamp,omitempty"`
	Location       string             `json:"location"`
	Tags           *map[string]string `json:"tags,omitempty"`
}

func (EventHubEventSourceCreateOrUpdateParameters) MarshalJSON

type EventHubEventSourceCreationProperties

type EventHubEventSourceCreationProperties struct {
	ConsumerGroupName     string                    `json:"consumerGroupName"`
	CreationTime          *string                   `json:"creationTime,omitempty"`
	EventHubName          string                    `json:"eventHubName"`
	EventSourceResourceId string                    `json:"eventSourceResourceId"`
	IngressStartAt        *IngressStartAtProperties `json:"ingressStartAt,omitempty"`
	KeyName               string                    `json:"keyName"`
	LocalTimestamp        *LocalTimestamp           `json:"localTimestamp,omitempty"`
	ProvisioningState     *ProvisioningState        `json:"provisioningState,omitempty"`
	ServiceBusNamespace   string                    `json:"serviceBusNamespace"`
	SharedAccessKey       string                    `json:"sharedAccessKey"`
	TimestampPropertyName *string                   `json:"timestampPropertyName,omitempty"`
}

func (*EventHubEventSourceCreationProperties) GetCreationTimeAsTime

func (o *EventHubEventSourceCreationProperties) GetCreationTimeAsTime() (*time.Time, error)

func (*EventHubEventSourceCreationProperties) SetCreationTimeAsTime

func (o *EventHubEventSourceCreationProperties) SetCreationTimeAsTime(input time.Time)

type EventHubEventSourceMutableProperties

type EventHubEventSourceMutableProperties struct {
	SharedAccessKey       *string `json:"sharedAccessKey,omitempty"`
	TimestampPropertyName *string `json:"timestampPropertyName,omitempty"`
}

type EventHubEventSourceResource

type EventHubEventSourceResource struct {
	Properties EventHubEventSourceCommonProperties `json:"properties"`

	// Fields inherited from EventSourceResource
	Id       *string            `json:"id,omitempty"`
	Location string             `json:"location"`
	Name     *string            `json:"name,omitempty"`
	Tags     *map[string]string `json:"tags,omitempty"`
	Type     *string            `json:"type,omitempty"`
}

func (EventHubEventSourceResource) MarshalJSON

func (s EventHubEventSourceResource) MarshalJSON() ([]byte, error)

type EventHubEventSourceUpdateParameters

type EventHubEventSourceUpdateParameters struct {
	Properties *EventHubEventSourceMutableProperties `json:"properties,omitempty"`

	// Fields inherited from EventSourceUpdateParameters
	Tags *map[string]string `json:"tags,omitempty"`
}

func (EventHubEventSourceUpdateParameters) MarshalJSON

func (s EventHubEventSourceUpdateParameters) MarshalJSON() ([]byte, error)

type EventSourceCreateOrUpdateParameters

type EventSourceCreateOrUpdateParameters interface {
}

type EventSourceId

type EventSourceId struct {
	SubscriptionId    string
	ResourceGroupName string
	EnvironmentName   string
	EventSourceName   string
}

EventSourceId is a struct representing the Resource ID for a Event Source

func NewEventSourceID

func NewEventSourceID(subscriptionId string, resourceGroupName string, environmentName string, eventSourceName string) EventSourceId

NewEventSourceID returns a new EventSourceId struct

func ParseEventSourceID

func ParseEventSourceID(input string) (*EventSourceId, error)

ParseEventSourceID parses 'input' into a EventSourceId

func ParseEventSourceIDInsensitively

func ParseEventSourceIDInsensitively(input string) (*EventSourceId, error)

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

func (*EventSourceId) FromParseResult

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

func (EventSourceId) ID

func (id EventSourceId) ID() string

ID returns the formatted Event Source ID

func (EventSourceId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Event Source ID

func (EventSourceId) String

func (id EventSourceId) String() string

String returns a human-readable description of this Event Source ID

type EventSourceKind

type EventSourceKind string
const (
	EventSourceKindMicrosoftPointEventHub EventSourceKind = "Microsoft.EventHub"
	EventSourceKindMicrosoftPointIoTHub   EventSourceKind = "Microsoft.IoTHub"
)

func (*EventSourceKind) UnmarshalJSON added in v0.20240214.1142753

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

type EventSourceListResponse

type EventSourceListResponse struct {
	Value *[]EventSourceResource `json:"value,omitempty"`
}

func (*EventSourceListResponse) UnmarshalJSON

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

type EventSourceResource

type EventSourceResource interface {
}

type EventSourceUpdateParameters

type EventSourceUpdateParameters interface {
}

type EventSourcesClient

type EventSourcesClient struct {
	Client *resourcemanager.Client
}

func NewEventSourcesClientWithBaseURI

func NewEventSourcesClientWithBaseURI(sdkApi sdkEnv.Api) (*EventSourcesClient, error)

func (EventSourcesClient) CreateOrUpdate

CreateOrUpdate ...

func (EventSourcesClient) Delete

Delete ...

func (EventSourcesClient) Get

Get ...

func (EventSourcesClient) ListByEnvironment

func (c EventSourcesClient) ListByEnvironment(ctx context.Context, id EnvironmentId) (result ListByEnvironmentOperationResponse, err error)

ListByEnvironment ...

func (EventSourcesClient) Update

Update ...

type GetOperationResponse

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

type IngressStartAtProperties

type IngressStartAtProperties struct {
	Time *string             `json:"time,omitempty"`
	Type *IngressStartAtType `json:"type,omitempty"`
}

type IngressStartAtType

type IngressStartAtType string
const (
	IngressStartAtTypeCustomEnqueuedTime      IngressStartAtType = "CustomEnqueuedTime"
	IngressStartAtTypeEarliestAvailable       IngressStartAtType = "EarliestAvailable"
	IngressStartAtTypeEventSourceCreationTime IngressStartAtType = "EventSourceCreationTime"
)

func (*IngressStartAtType) UnmarshalJSON added in v0.20240214.1142753

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

type IoTHubEventSourceCommonProperties

type IoTHubEventSourceCommonProperties struct {
	ConsumerGroupName     string                    `json:"consumerGroupName"`
	CreationTime          *string                   `json:"creationTime,omitempty"`
	EventSourceResourceId string                    `json:"eventSourceResourceId"`
	IngressStartAt        *IngressStartAtProperties `json:"ingressStartAt,omitempty"`
	IotHubName            string                    `json:"iotHubName"`
	KeyName               string                    `json:"keyName"`
	LocalTimestamp        *LocalTimestamp           `json:"localTimestamp,omitempty"`
	ProvisioningState     *ProvisioningState        `json:"provisioningState,omitempty"`
	TimestampPropertyName *string                   `json:"timestampPropertyName,omitempty"`
}

func (*IoTHubEventSourceCommonProperties) GetCreationTimeAsTime

func (o *IoTHubEventSourceCommonProperties) GetCreationTimeAsTime() (*time.Time, error)

func (*IoTHubEventSourceCommonProperties) SetCreationTimeAsTime

func (o *IoTHubEventSourceCommonProperties) SetCreationTimeAsTime(input time.Time)

type IoTHubEventSourceCreateOrUpdateParameters

type IoTHubEventSourceCreateOrUpdateParameters struct {
	Properties IoTHubEventSourceCreationProperties `json:"properties"`

	// Fields inherited from EventSourceCreateOrUpdateParameters
	LocalTimestamp *LocalTimestamp    `json:"localTimestamp,omitempty"`
	Location       string             `json:"location"`
	Tags           *map[string]string `json:"tags,omitempty"`
}

func (IoTHubEventSourceCreateOrUpdateParameters) MarshalJSON

type IoTHubEventSourceCreationProperties

type IoTHubEventSourceCreationProperties struct {
	ConsumerGroupName     string                    `json:"consumerGroupName"`
	CreationTime          *string                   `json:"creationTime,omitempty"`
	EventSourceResourceId string                    `json:"eventSourceResourceId"`
	IngressStartAt        *IngressStartAtProperties `json:"ingressStartAt,omitempty"`
	IotHubName            string                    `json:"iotHubName"`
	KeyName               string                    `json:"keyName"`
	LocalTimestamp        *LocalTimestamp           `json:"localTimestamp,omitempty"`
	ProvisioningState     *ProvisioningState        `json:"provisioningState,omitempty"`
	SharedAccessKey       string                    `json:"sharedAccessKey"`
	TimestampPropertyName *string                   `json:"timestampPropertyName,omitempty"`
}

func (*IoTHubEventSourceCreationProperties) GetCreationTimeAsTime

func (o *IoTHubEventSourceCreationProperties) GetCreationTimeAsTime() (*time.Time, error)

func (*IoTHubEventSourceCreationProperties) SetCreationTimeAsTime

func (o *IoTHubEventSourceCreationProperties) SetCreationTimeAsTime(input time.Time)

type IoTHubEventSourceMutableProperties

type IoTHubEventSourceMutableProperties struct {
	SharedAccessKey       *string `json:"sharedAccessKey,omitempty"`
	TimestampPropertyName *string `json:"timestampPropertyName,omitempty"`
}

type IoTHubEventSourceResource

type IoTHubEventSourceResource struct {
	Properties IoTHubEventSourceCommonProperties `json:"properties"`

	// Fields inherited from EventSourceResource
	Id       *string            `json:"id,omitempty"`
	Location string             `json:"location"`
	Name     *string            `json:"name,omitempty"`
	Tags     *map[string]string `json:"tags,omitempty"`
	Type     *string            `json:"type,omitempty"`
}

func (IoTHubEventSourceResource) MarshalJSON

func (s IoTHubEventSourceResource) MarshalJSON() ([]byte, error)

type IoTHubEventSourceUpdateParameters

type IoTHubEventSourceUpdateParameters struct {
	Properties *IoTHubEventSourceMutableProperties `json:"properties,omitempty"`

	// Fields inherited from EventSourceUpdateParameters
	Tags *map[string]string `json:"tags,omitempty"`
}

func (IoTHubEventSourceUpdateParameters) MarshalJSON

func (s IoTHubEventSourceUpdateParameters) MarshalJSON() ([]byte, error)

type Kind

type Kind string
const (
	KindMicrosoftPointEventHub Kind = "Microsoft.EventHub"
	KindMicrosoftPointIoTHub   Kind = "Microsoft.IoTHub"
)

func (*Kind) UnmarshalJSON added in v0.20240214.1142753

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

type ListByEnvironmentOperationResponse

type ListByEnvironmentOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *EventSourceListResponse
}

type LocalTimestamp

type LocalTimestamp struct {
	Format         *LocalTimestampFormat         `json:"format,omitempty"`
	TimeZoneOffset *LocalTimestampTimeZoneOffset `json:"timeZoneOffset,omitempty"`
}

type LocalTimestampFormat

type LocalTimestampFormat string
const (
	LocalTimestampFormatEmbedded LocalTimestampFormat = "Embedded"
)

func (*LocalTimestampFormat) UnmarshalJSON added in v0.20240214.1142753

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

type LocalTimestampTimeZoneOffset

type LocalTimestampTimeZoneOffset struct {
	PropertyName *string `json:"propertyName,omitempty"`
}

type ProvisioningState

type ProvisioningState string
const (
	ProvisioningStateAccepted  ProvisioningState = "Accepted"
	ProvisioningStateCreating  ProvisioningState = "Creating"
	ProvisioningStateDeleting  ProvisioningState = "Deleting"
	ProvisioningStateFailed    ProvisioningState = "Failed"
	ProvisioningStateSucceeded ProvisioningState = "Succeeded"
	ProvisioningStateUpdating  ProvisioningState = "Updating"
)

func (*ProvisioningState) UnmarshalJSON added in v0.20240214.1142753

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

type RawEventSourceCreateOrUpdateParametersImpl

type RawEventSourceCreateOrUpdateParametersImpl struct {
	Type   string
	Values map[string]interface{}
}

RawEventSourceCreateOrUpdateParametersImpl is returned when the Discriminated Value doesn't match any of the defined types NOTE: this should only be used when a type isn't defined for this type of Object (as a workaround) and is used only for Deserialization (e.g. this cannot be used as a Request Payload).

type RawEventSourceResourceImpl

type RawEventSourceResourceImpl struct {
	Type   string
	Values map[string]interface{}
}

RawEventSourceResourceImpl is returned when the Discriminated Value doesn't match any of the defined types NOTE: this should only be used when a type isn't defined for this type of Object (as a workaround) and is used only for Deserialization (e.g. this cannot be used as a Request Payload).

type RawEventSourceUpdateParametersImpl

type RawEventSourceUpdateParametersImpl struct {
	Type   string
	Values map[string]interface{}
}

RawEventSourceUpdateParametersImpl is returned when the Discriminated Value doesn't match any of the defined types NOTE: this should only be used when a type isn't defined for this type of Object (as a workaround) and is used only for Deserialization (e.g. this cannot be used as a Request Payload).

type UpdateOperationResponse

type UpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *EventSourceResource
}

Jump to

Keyboard shortcuts

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