Class AcsMessageEventData

java.lang.Object
com.azure.messaging.eventgrid.systemevents.AcsMessageEventData
All Implemented Interfaces:
com.azure.json.JsonSerializable<AcsMessageEventData>
Direct Known Subclasses:
AcsMessageDeliveryStatusUpdatedEventData, AcsMessageReceivedEventData

public class AcsMessageEventData extends Object implements com.azure.json.JsonSerializable<AcsMessageEventData>
Schema of common properties of all chat thread events.
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    AcsMessageEventData(String from, String to, OffsetDateTime receivedTimestamp)
    Creates an instance of AcsMessageEventData class.
  • Method Summary

    Modifier and Type
    Method
    Description
    fromJson(com.azure.json.JsonReader jsonReader)
    Reads an instance of AcsMessageEventData from the JsonReader.
    com.azure.core.models.ResponseError
    Get the error property: The channel error code and message.
    Get the from property: The message sender.
    Get the receivedTimestamp property: The time message was received.
    Get the to property: The message recipient.
    com.azure.json.JsonWriter
    toJson(com.azure.json.JsonWriter jsonWriter)

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.azure.json.JsonSerializable

    toJson, toJson, toJsonBytes, toJsonString
  • Constructor Details

    • AcsMessageEventData

      protected AcsMessageEventData(String from, String to, OffsetDateTime receivedTimestamp)
      Creates an instance of AcsMessageEventData class.
      Parameters:
      from - the from value to set.
      to - the to value to set.
      receivedTimestamp - the receivedTimestamp value to set.
  • Method Details

    • getFrom

      public String getFrom()
      Get the from property: The message sender.
      Returns:
      the from value.
    • getTo

      public String getTo()
      Get the to property: The message recipient.
      Returns:
      the to value.
    • getReceivedTimestamp

      public OffsetDateTime getReceivedTimestamp()
      Get the receivedTimestamp property: The time message was received.
      Returns:
      the receivedTimestamp value.
    • getError

      public com.azure.core.models.ResponseError getError()
      Get the error property: The channel error code and message.
      Returns:
      the error value.
    • toJson

      public com.azure.json.JsonWriter toJson(com.azure.json.JsonWriter jsonWriter) throws IOException
      Specified by:
      toJson in interface com.azure.json.JsonSerializable<AcsMessageEventData>
      Throws:
      IOException
    • fromJson

      public static AcsMessageEventData fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of AcsMessageEventData from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of AcsMessageEventData if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
      Throws:
      IllegalStateException - If the deserialized JSON object was missing any required properties.
      IOException - If an error occurs while reading the AcsMessageEventData.