Class HQVoiceMessage

  • All Implemented Interfaces:

    
    public class HQVoiceMessage
    
                        

    High-Definition Voice Message Class

    This class represents a high-definition voice message. The message will be stored and counted as an unread message.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
      public final static Creator<HQVoiceMessage> CREATOR
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      static HQVoiceMessage obtain(Uri uri, int duration)
      Array<byte> encode() Serializes the local message object into message data.
      void writeToParcel(Parcel dest, int flags) Writes the class data into the provided Parcel.
      int describeContents()
      int getDuration() Gets the duration of the voice message in seconds.
      void setDuration(int duration) Sets the duration of the voice message in seconds.
      Uri getFileUrl() Get the remote download URL for high-definition voice messages
      void setFileUrl(Uri uri) Sets the remote download URL for high-definition voice messages.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • HQVoiceMessage

        HQVoiceMessage(Array<byte> data)
      • HQVoiceMessage

        HQVoiceMessage(Parcel in)
        Constructor.
        Parameters:
        in - The Parcel passed during initialization.
    • Method Detail

      • encode

         Array<byte> encode()

        Serializes the local message object into message data.

        Returns:

        The message data.

      • writeToParcel

         void writeToParcel(Parcel dest, int flags)

        Writes the class data into the provided Parcel.

        Parameters:
        dest - The Parcel into which the object is written.
        flags - Additional flags about how the object should be written, may be 0 or PARCELABLE_WRITE_RETURN_VALUE.
      • getDuration

         int getDuration()

        Gets the duration of the voice message in seconds.

        Returns:

        The duration of the voice message in seconds.

      • setDuration

         void setDuration(int duration)

        Sets the duration of the voice message in seconds.

        Parameters:
        duration - The duration of the voice message in seconds.
      • getFileUrl

         Uri getFileUrl()

        Get the remote download URL for high-definition voice messages

        Returns:

        The remote download URL for high-definition voice messages

      • setFileUrl

         void setFileUrl(Uri uri)

        Sets the remote download URL for high-definition voice messages.

        Parameters:
        uri - The remote download URL for high-definition voice messages.