com.tencent.ads.model.ExpressCompany Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of marketing-api-java-sdk Show documentation
Show all versions of marketing-api-java-sdk Show documentation
Tencent Ads Mareting-Api Java Sdk
/*
* Marketing API
* Marketing API
*
* OpenAPI spec version: 1.3
*
*
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*/
package com.tencent.ads.model;
import com.google.gson.TypeAdapter;
import com.google.gson.annotations.JsonAdapter;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import java.io.IOException;
/** 快递公司 */
@JsonAdapter(ExpressCompany.Adapter.class)
public enum ExpressCompany {
UNKNOWN("UNKNOWN"),
SF_EXPRESS("SF_EXPRESS"),
STO("STO"),
YTO("YTO"),
ZTO("ZTO"),
BEST_EXPRESS("BEST_EXPRESS"),
YUNDA_EXPRESS("YUNDA_EXPRESS"),
TTK_EXPRESS("TTK_EXPRESS"),
EMS("EMS"),
CHINA_POST_EXPRESS("CHINA_POST_EXPRESS"),
JUST_IN_TIME("JUST_IN_TIME"),
JD_EXPRESS("JD_EXPRESS"),
DEPPON_EXPRESS("DEPPON_EXPRESS");
private String value;
ExpressCompany(String value) {
this.value = value;
}
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
public static ExpressCompany fromValue(String text) {
for (ExpressCompany b : ExpressCompany.values()) {
if (String.valueOf(b.value).equals(text)) {
return b;
}
}
return null;
}
public static class Adapter extends TypeAdapter {
@Override
public void write(final JsonWriter jsonWriter, final ExpressCompany enumeration)
throws IOException {
jsonWriter.value(enumeration.getValue());
}
@Override
public ExpressCompany read(final JsonReader jsonReader) throws IOException {
String value = jsonReader.nextString();
return ExpressCompany.fromValue(String.valueOf(value));
}
}
}