Class TweetAttachments


  • @Generated("org.openapitools.codegen.languages.JavaClientCodegen")
    public class TweetAttachments
    extends Object
    Specifies the type of attachments (if any) present in this Tweet.
    • Constructor Detail

      • TweetAttachments

        public TweetAttachments()
    • Method Detail

      • getMediaKeys

        @Nullable
        public List<String> getMediaKeys()
        A list of Media Keys for each one of the media attachments (if media are attached).
        Returns:
        mediaKeys
      • setMediaKeys

        public void setMediaKeys​(List<String> mediaKeys)
      • getPollIds

        @Nullable
        public List<String> getPollIds()
        A list of poll IDs (if polls are attached).
        Returns:
        pollIds
      • setPollIds

        public void setPollIds​(List<String> pollIds)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • validateJsonObject

        public static void validateJsonObject​(com.google.gson.JsonObject jsonObj)
                                       throws IOException
        Validates the JSON Object and throws an exception if issues found
        Parameters:
        jsonObj - JSON Object
        Throws:
        IOException - if the JSON Object is invalid with respect to TweetAttachments
      • fromJson

        public static TweetAttachments fromJson​(String jsonString)
                                         throws IOException
        Create an instance of TweetAttachments given an JSON string
        Parameters:
        jsonString - JSON string
        Returns:
        An instance of TweetAttachments
        Throws:
        IOException - if the JSON string is invalid with respect to TweetAttachments
      • toJson

        public String toJson()
        Convert an instance of TweetAttachments to an JSON string
        Returns:
        JSON string