共用方式為


AzureEventHubsExtensions.AddEventHub Method

Definition

Overloads

AddEventHub(IResourceBuilder<AzureEventHubsResource>, String)

Adds an Azure Event Hubs hub resource to the application model. This resource requires an AzureEventHubsResource to be added to the application model.

AddEventHub(IResourceBuilder<AzureEventHubsResource>, String, Action<IResourceBuilder<AzureEventHubsResource>,ResourceModuleConstruct,EventHub>)

Adds an Azure Event Hubs hub resource to the application model. This resource requires an AzureEventHubsResource to be added to the application model.

AddEventHub(IResourceBuilder<AzureEventHubsResource>, String)

Source:
AzureEventHubsExtensions.cs
Source:
AzureEventHubsExtensions.cs

Adds an Azure Event Hubs hub resource to the application model. This resource requires an AzureEventHubsResource to be added to the application model.

public static Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource> AddEventHub (this Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource> builder, string name);
static member AddEventHub : Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource> * string -> Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource>
<Extension()>
Public Function AddEventHub (builder As IResourceBuilder(Of AzureEventHubsResource), name As String) As IResourceBuilder(Of AzureEventHubsResource)

Parameters

builder
IResourceBuilder<AzureEventHubsResource>

The Azure Event Hubs resource builder.

name
String

The name of the Event Hub.

Returns

Remarks

This version of the package defaults to the tag of the / container image.

Applies to

AddEventHub(IResourceBuilder<AzureEventHubsResource>, String, Action<IResourceBuilder<AzureEventHubsResource>,ResourceModuleConstruct,EventHub>)

Source:
AzureEventHubsExtensions.cs

Adds an Azure Event Hubs hub resource to the application model. This resource requires an AzureEventHubsResource to be added to the application model.

public static Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource> AddEventHub (this Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource> builder, string name, Action<Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource>,Aspire.Hosting.ResourceModuleConstruct,Azure.Provisioning.EventHubs.EventHub>? configureHub);
static member AddEventHub : Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource> * string * Action<Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource>, Aspire.Hosting.ResourceModuleConstruct, Azure.Provisioning.EventHubs.EventHub> -> Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Azure.AzureEventHubsResource>
<Extension()>
Public Function AddEventHub (builder As IResourceBuilder(Of AzureEventHubsResource), name As String, configureHub As Action(Of IResourceBuilder(Of AzureEventHubsResource), ResourceModuleConstruct, EventHub)) As IResourceBuilder(Of AzureEventHubsResource)

Parameters

builder
IResourceBuilder<AzureEventHubsResource>

The Azure Event Hubs resource builder.

name
String

The name of the Event Hub.

configureHub
Action<IResourceBuilder<AzureEventHubsResource>,ResourceModuleConstruct,EventHub>

Optional callback to customize the Event Hub.

Returns

Applies to