Sprog

WebPubSubChatServiceClient.CreateOrReplaceTopicAsync Method

Definition

Overloads

Name Description
CreateOrReplaceTopicAsync(String, String, RequestContent, MatchConditions, RequestContext)

[Protocol Method] Create or replace a topic with a client-specified ID.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
CreateOrReplaceTopicAsync(String, String, ChatTopic, MatchConditions, CancellationToken)

Create or replace a topic with a client-specified ID.

CreateOrReplaceTopicAsync(String, String, RequestContent, MatchConditions, RequestContext)

Source:
WebPubSubChatServiceClient.cs

[Protocol Method] Create or replace a topic with a client-specified ID.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
public virtual System.Threading.Tasks.Task<Azure.Response> CreateOrReplaceTopicAsync(string roomId, string topicId, Azure.Core.RequestContent content, Azure.MatchConditions matchConditions = default, Azure.RequestContext context = default);
abstract member CreateOrReplaceTopicAsync : string * string * Azure.Core.RequestContent * Azure.MatchConditions * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
override this.CreateOrReplaceTopicAsync : string * string * Azure.Core.RequestContent * Azure.MatchConditions * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function CreateOrReplaceTopicAsync (roomId As String, topicId As String, content As RequestContent, Optional matchConditions As MatchConditions = Nothing, Optional context As RequestContext = Nothing) As Task(Of Response)

Parameters

roomId
String

Room identifier.

topicId
String

Topic identifier unique within the room.

content
RequestContent

The content to send as the body of the request.

matchConditions
MatchConditions

The content to send as the request conditions of the request.

context
RequestContext

The request options, which can override default behaviors of the client pipeline on a per-call basis.

Returns

The response returned from the service.

Exceptions

roomId, topicId or content is null.

roomId or topicId is an empty string, and was expected to be non-empty.

Service returned a non-success status code.

Applies to

CreateOrReplaceTopicAsync(String, String, ChatTopic, MatchConditions, CancellationToken)

Source:
WebPubSubChatServiceClient.cs

Create or replace a topic with a client-specified ID.

public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Messaging.WebPubSub.Chat.ChatTopic>> CreateOrReplaceTopicAsync(string roomId, string topicId, Azure.Messaging.WebPubSub.Chat.ChatTopic topic, Azure.MatchConditions matchConditions = default, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateOrReplaceTopicAsync : string * string * Azure.Messaging.WebPubSub.Chat.ChatTopic * Azure.MatchConditions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Messaging.WebPubSub.Chat.ChatTopic>>
override this.CreateOrReplaceTopicAsync : string * string * Azure.Messaging.WebPubSub.Chat.ChatTopic * Azure.MatchConditions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Messaging.WebPubSub.Chat.ChatTopic>>
Public Overridable Function CreateOrReplaceTopicAsync (roomId As String, topicId As String, topic As ChatTopic, Optional matchConditions As MatchConditions = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of ChatTopic))

Parameters

roomId
String

Room identifier.

topicId
String

Topic identifier unique within the room.

topic
ChatTopic

The resource instance.

matchConditions
MatchConditions

The content to send as the request conditions of the request.

cancellationToken
CancellationToken

The cancellation token that can be used to cancel the operation.

Returns

Exceptions

roomId, topicId or topic is null.

roomId or topicId is an empty string, and was expected to be non-empty.

Service returned a non-success status code.

Applies to