Package com.twitter.clientlib.model
Class CreateTweetRequest
- java.lang.Object
-
- com.twitter.clientlib.model.CreateTweetRequest
-
@Generated("org.openapitools.codegen.languages.JavaClientCodegen") public class CreateTweetRequest extends Object
CreateTweetRequest
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCreateTweetRequest.CustomTypeAdapterFactorystatic classCreateTweetRequest.ReplySettingsEnumSettings to indicate who can reply to the Tweet.
-
Field Summary
Fields Modifier and Type Field Description static HashSet<String>openapiFieldsstatic HashSet<String>openapiRequiredFieldsstatic StringSERIALIZED_NAME_DIRECT_MESSAGE_DEEP_LINKstatic StringSERIALIZED_NAME_FOR_SUPER_FOLLOWERS_ONLYstatic StringSERIALIZED_NAME_GEOstatic StringSERIALIZED_NAME_MEDIAstatic StringSERIALIZED_NAME_POLLstatic StringSERIALIZED_NAME_QUOTE_TWEET_IDstatic StringSERIALIZED_NAME_REPLYstatic StringSERIALIZED_NAME_REPLY_SETTINGSstatic StringSERIALIZED_NAME_TEXT
-
Constructor Summary
Constructors Constructor Description CreateTweetRequest()
-
Method Summary
-
-
-
Field Detail
-
SERIALIZED_NAME_TEXT
public static final String SERIALIZED_NAME_TEXT
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_DIRECT_MESSAGE_DEEP_LINK
public static final String SERIALIZED_NAME_DIRECT_MESSAGE_DEEP_LINK
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_QUOTE_TWEET_ID
public static final String SERIALIZED_NAME_QUOTE_TWEET_ID
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_FOR_SUPER_FOLLOWERS_ONLY
public static final String SERIALIZED_NAME_FOR_SUPER_FOLLOWERS_ONLY
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_REPLY
public static final String SERIALIZED_NAME_REPLY
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_MEDIA
public static final String SERIALIZED_NAME_MEDIA
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_POLL
public static final String SERIALIZED_NAME_POLL
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_REPLY_SETTINGS
public static final String SERIALIZED_NAME_REPLY_SETTINGS
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_GEO
public static final String SERIALIZED_NAME_GEO
- See Also:
- Constant Field Values
-
-
Method Detail
-
text
public CreateTweetRequest text(String text)
-
setText
public void setText(String text)
-
directMessageDeepLink
public CreateTweetRequest directMessageDeepLink(String directMessageDeepLink)
-
getDirectMessageDeepLink
@Nullable public String getDirectMessageDeepLink()
Link to take the conversation from the public timeline to a private Direct Message.- Returns:
- directMessageDeepLink
-
setDirectMessageDeepLink
public void setDirectMessageDeepLink(String directMessageDeepLink)
-
quoteTweetId
public CreateTweetRequest quoteTweetId(String quoteTweetId)
-
getQuoteTweetId
@Nullable public String getQuoteTweetId()
Unique identifier of this Tweet. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers.- Returns:
- quoteTweetId
-
setQuoteTweetId
public void setQuoteTweetId(String quoteTweetId)
-
forSuperFollowersOnly
public CreateTweetRequest forSuperFollowersOnly(Boolean forSuperFollowersOnly)
-
getForSuperFollowersOnly
@Nullable public Boolean getForSuperFollowersOnly()
Exclusive Tweet for super followers.- Returns:
- forSuperFollowersOnly
-
setForSuperFollowersOnly
public void setForSuperFollowersOnly(Boolean forSuperFollowersOnly)
-
reply
public CreateTweetRequest reply(CreateTweetRequestReply reply)
-
getReply
@Nullable public CreateTweetRequestReply getReply()
Get reply- Returns:
- reply
-
setReply
public void setReply(CreateTweetRequestReply reply)
-
media
public CreateTweetRequest media(CreateTweetRequestMedia media)
-
getMedia
@Nullable public CreateTweetRequestMedia getMedia()
Get media- Returns:
- media
-
setMedia
public void setMedia(CreateTweetRequestMedia media)
-
poll
public CreateTweetRequest poll(CreateTweetRequestPoll poll)
-
getPoll
@Nullable public CreateTweetRequestPoll getPoll()
Get poll- Returns:
- poll
-
setPoll
public void setPoll(CreateTweetRequestPoll poll)
-
replySettings
public CreateTweetRequest replySettings(CreateTweetRequest.ReplySettingsEnum replySettings)
-
getReplySettings
@Nullable public CreateTweetRequest.ReplySettingsEnum getReplySettings()
Settings to indicate who can reply to the Tweet.- Returns:
- replySettings
-
setReplySettings
public void setReplySettings(CreateTweetRequest.ReplySettingsEnum replySettings)
-
geo
public CreateTweetRequest geo(CreateTweetRequestGeo geo)
-
getGeo
@Nullable public CreateTweetRequestGeo getGeo()
Get geo- Returns:
- geo
-
setGeo
public void setGeo(CreateTweetRequestGeo geo)
-
validateJsonObject
public static void validateJsonObject(com.google.gson.JsonObject jsonObj) throws IOExceptionValidates 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 CreateTweetRequest
-
fromJson
public static CreateTweetRequest fromJson(String jsonString) throws IOException
Create an instance of CreateTweetRequest given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of CreateTweetRequest
- Throws:
IOException- if the JSON string is invalid with respect to CreateTweetRequest
-
toJson
public String toJson()
Convert an instance of CreateTweetRequest to an JSON string- Returns:
- JSON string
-
-