CreateChatThreadResult Class

  • java.lang.Object
    • com.azure.communication.chat.models.CreateChatThreadResult

Implements

public final class CreateChatThreadResult
implements JsonSerializable<CreateChatThreadResult>

The CreateChatThreadResult model.

Constructor Summary

Constructor Description
CreateChatThreadResult(ChatThreadProperties chatThreadProperties, List<ChatError> invalidParticipants)

Constructs a new instance of CreateChatThreadResult

Method Summary

Modifier and Type Method and Description
static CreateChatThreadResult fromJson(JsonReader jsonReader)

Reads an instance of AddChatParticipantsResult from the JsonReader.

ChatThreadProperties getChatThread()

Gets the chatThread property: The chatThread property.

List<ChatError> getInvalidParticipants()

Gets the invalidParticipants property: The participants that failed to be added to the chat thread.

JsonWriter toJson(JsonWriter jsonWriter)

Methods inherited from java.lang.Object

Constructor Details

CreateChatThreadResult

public CreateChatThreadResult(ChatThreadProperties chatThreadProperties, List<ChatError> invalidParticipants)

Constructs a new instance of CreateChatThreadResult

Parameters:

chatThreadProperties - The chat thread that was created.
invalidParticipants - List of errors that occurred when attempting to create the chat thread.

Method Details

fromJson

public static CreateChatThreadResult fromJson(JsonReader jsonReader)

Reads an instance of AddChatParticipantsResult from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of AddChatParticipantsResult if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If an error occurs while reading the AddChatParticipantsResult.

getChatThread

public ChatThreadProperties getChatThread()

Gets the chatThread property: The chatThread property.

Returns:

the chatThread.

getInvalidParticipants

public List<ChatError> getInvalidParticipants()

Gets the invalidParticipants property: The participants that failed to be added to the chat thread. The 'target' property of each ChatError will reference the failed participant.

Returns:

the invalidParticipants.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

Applies to