Package com.twitter.clientlib.model
Class Variant
- java.lang.Object
-
- com.twitter.clientlib.model.Variant
-
@Generated("org.openapitools.codegen.languages.JavaClientCodegen") public class Variant extends Object
Variant
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Variant.CustomTypeAdapterFactory
-
Field Summary
Fields Modifier and Type Field Description static HashSet<String>
openapiFields
static HashSet<String>
openapiRequiredFields
static String
SERIALIZED_NAME_BIT_RATE
static String
SERIALIZED_NAME_CONTENT_TYPE
static String
SERIALIZED_NAME_URL
-
Constructor Summary
Constructors Constructor Description Variant()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Variant
bitRate(Integer bitRate)
Variant
contentType(String contentType)
boolean
equals(Object o)
static Variant
fromJson(String jsonString)
Create an instance of Variant given an JSON stringInteger
getBitRate()
The bit rate of the media.String
getContentType()
The content type of the media.URL
getUrl()
The url to the media.int
hashCode()
void
setBitRate(Integer bitRate)
void
setContentType(String contentType)
void
setUrl(URL url)
String
toJson()
Convert an instance of Variant to an JSON stringString
toString()
Variant
url(URL url)
static void
validateJsonObject(com.google.gson.JsonObject jsonObj)
Validates the JSON Object and throws an exception if issues found
-
-
-
Field Detail
-
SERIALIZED_NAME_BIT_RATE
public static final String SERIALIZED_NAME_BIT_RATE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_CONTENT_TYPE
public static final String SERIALIZED_NAME_CONTENT_TYPE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_URL
public static final String SERIALIZED_NAME_URL
- See Also:
- Constant Field Values
-
-
Method Detail
-
setBitRate
public void setBitRate(Integer bitRate)
-
getContentType
@Nullable public String getContentType()
The content type of the media.- Returns:
- contentType
-
setContentType
public void setContentType(String contentType)
-
setUrl
public void setUrl(URL url)
-
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 Variant
-
fromJson
public static Variant fromJson(String jsonString) throws IOException
Create an instance of Variant given an JSON string- Parameters:
jsonString
- JSON string- Returns:
- An instance of Variant
- Throws:
IOException
- if the JSON string is invalid with respect to Variant
-
toJson
public String toJson()
Convert an instance of Variant to an JSON string- Returns:
- JSON string
-
-