367 lines
11 KiB
Java
367 lines
11 KiB
Java
package com.hcaptcha.sdk;
|
|
|
|
import java.io.Serializable;
|
|
import java.util.Locale;
|
|
import java.util.Objects;
|
|
public class HCaptchaConfig implements Serializable {
|
|
public String apiEndpoint;
|
|
public String assethost;
|
|
public String endpoint;
|
|
public String imghost;
|
|
public String locale;
|
|
public String reportapi;
|
|
public String rqdata;
|
|
public Boolean sentry;
|
|
public String siteKey;
|
|
public HCaptchaSize size;
|
|
public HCaptchaTheme theme;
|
|
|
|
public static class a {
|
|
public String a;
|
|
public boolean b;
|
|
|
|
/* renamed from: c reason: collision with root package name */
|
|
public Boolean f2393c;
|
|
public String d;
|
|
public boolean e;
|
|
public String f;
|
|
public String g;
|
|
public String h;
|
|
public String i;
|
|
public String j;
|
|
public boolean k;
|
|
public String l;
|
|
public boolean m;
|
|
public HCaptchaSize n;
|
|
public boolean o;
|
|
public HCaptchaTheme p;
|
|
|
|
public String toString() {
|
|
StringBuilder K = c.d.b.a.a.K("HCaptchaConfig.HCaptchaConfigBuilder(siteKey=");
|
|
K.append(this.a);
|
|
K.append(", sentry$value=");
|
|
K.append(this.f2393c);
|
|
K.append(", rqdata=");
|
|
K.append(this.d);
|
|
K.append(", apiEndpoint$value=");
|
|
K.append(this.f);
|
|
K.append(", endpoint=");
|
|
K.append(this.g);
|
|
K.append(", reportapi=");
|
|
K.append(this.h);
|
|
K.append(", assethost=");
|
|
K.append(this.i);
|
|
K.append(", imghost=");
|
|
K.append(this.j);
|
|
K.append(", locale$value=");
|
|
K.append(this.l);
|
|
K.append(", size$value=");
|
|
K.append(this.n);
|
|
K.append(", theme$value=");
|
|
K.append(this.p);
|
|
K.append(")");
|
|
return K.toString();
|
|
}
|
|
}
|
|
|
|
public static String $default$apiEndpoint() {
|
|
return "https://hcaptcha.com/1/api.js";
|
|
}
|
|
|
|
public static String $default$locale() {
|
|
return Locale.getDefault().getLanguage();
|
|
}
|
|
|
|
public static Boolean $default$sentry() {
|
|
return Boolean.TRUE;
|
|
}
|
|
|
|
public static HCaptchaSize $default$size() {
|
|
return HCaptchaSize.INVISIBLE;
|
|
}
|
|
|
|
public static HCaptchaTheme $default$theme() {
|
|
return HCaptchaTheme.LIGHT;
|
|
}
|
|
|
|
public HCaptchaConfig(String str, Boolean bool, String str2, String str3, String str4, String str5, String str6, String str7, String str8, HCaptchaSize hCaptchaSize, HCaptchaTheme hCaptchaTheme) {
|
|
Objects.requireNonNull(str, "siteKey is marked non-null but is null");
|
|
this.siteKey = str;
|
|
this.sentry = bool;
|
|
this.rqdata = str2;
|
|
this.apiEndpoint = str3;
|
|
this.endpoint = str4;
|
|
this.reportapi = str5;
|
|
this.assethost = str6;
|
|
this.imghost = str7;
|
|
this.locale = str8;
|
|
this.size = hCaptchaSize;
|
|
this.theme = hCaptchaTheme;
|
|
}
|
|
|
|
public static /* synthetic */ Boolean access$000() {
|
|
return $default$sentry();
|
|
}
|
|
|
|
public static /* synthetic */ String access$100() {
|
|
return $default$apiEndpoint();
|
|
}
|
|
|
|
public static /* synthetic */ String access$200() {
|
|
return $default$locale();
|
|
}
|
|
|
|
public static /* synthetic */ HCaptchaSize access$300() {
|
|
return $default$size();
|
|
}
|
|
|
|
public static /* synthetic */ HCaptchaTheme access$400() {
|
|
return $default$theme();
|
|
}
|
|
|
|
public static a builder() {
|
|
return new a();
|
|
}
|
|
|
|
public boolean canEqual(Object obj) {
|
|
return obj instanceof HCaptchaConfig;
|
|
}
|
|
|
|
@Override // java.lang.Object
|
|
public boolean equals(Object obj) {
|
|
if (obj == this) {
|
|
return true;
|
|
}
|
|
if (!(obj instanceof HCaptchaConfig)) {
|
|
return false;
|
|
}
|
|
HCaptchaConfig hCaptchaConfig = (HCaptchaConfig) obj;
|
|
if (!hCaptchaConfig.canEqual(this)) {
|
|
return false;
|
|
}
|
|
Boolean sentry = getSentry();
|
|
Boolean sentry2 = hCaptchaConfig.getSentry();
|
|
if (sentry != null ? !sentry.equals(sentry2) : sentry2 != null) {
|
|
return false;
|
|
}
|
|
String siteKey = getSiteKey();
|
|
String siteKey2 = hCaptchaConfig.getSiteKey();
|
|
if (siteKey != null ? !siteKey.equals(siteKey2) : siteKey2 != null) {
|
|
return false;
|
|
}
|
|
String rqdata = getRqdata();
|
|
String rqdata2 = hCaptchaConfig.getRqdata();
|
|
if (rqdata != null ? !rqdata.equals(rqdata2) : rqdata2 != null) {
|
|
return false;
|
|
}
|
|
String apiEndpoint = getApiEndpoint();
|
|
String apiEndpoint2 = hCaptchaConfig.getApiEndpoint();
|
|
if (apiEndpoint != null ? !apiEndpoint.equals(apiEndpoint2) : apiEndpoint2 != null) {
|
|
return false;
|
|
}
|
|
String endpoint = getEndpoint();
|
|
String endpoint2 = hCaptchaConfig.getEndpoint();
|
|
if (endpoint != null ? !endpoint.equals(endpoint2) : endpoint2 != null) {
|
|
return false;
|
|
}
|
|
String reportapi = getReportapi();
|
|
String reportapi2 = hCaptchaConfig.getReportapi();
|
|
if (reportapi != null ? !reportapi.equals(reportapi2) : reportapi2 != null) {
|
|
return false;
|
|
}
|
|
String assethost = getAssethost();
|
|
String assethost2 = hCaptchaConfig.getAssethost();
|
|
if (assethost != null ? !assethost.equals(assethost2) : assethost2 != null) {
|
|
return false;
|
|
}
|
|
String imghost = getImghost();
|
|
String imghost2 = hCaptchaConfig.getImghost();
|
|
if (imghost != null ? !imghost.equals(imghost2) : imghost2 != null) {
|
|
return false;
|
|
}
|
|
String locale = getLocale();
|
|
String locale2 = hCaptchaConfig.getLocale();
|
|
if (locale != null ? !locale.equals(locale2) : locale2 != null) {
|
|
return false;
|
|
}
|
|
HCaptchaSize size = getSize();
|
|
HCaptchaSize size2 = hCaptchaConfig.getSize();
|
|
if (size != null ? !size.equals(size2) : size2 != null) {
|
|
return false;
|
|
}
|
|
HCaptchaTheme theme = getTheme();
|
|
HCaptchaTheme theme2 = hCaptchaConfig.getTheme();
|
|
return theme != null ? theme.equals(theme2) : theme2 == null;
|
|
}
|
|
|
|
public String getApiEndpoint() {
|
|
return this.apiEndpoint;
|
|
}
|
|
|
|
public String getAssethost() {
|
|
return this.assethost;
|
|
}
|
|
|
|
public String getEndpoint() {
|
|
return this.endpoint;
|
|
}
|
|
|
|
public String getImghost() {
|
|
return this.imghost;
|
|
}
|
|
|
|
public String getLocale() {
|
|
return this.locale;
|
|
}
|
|
|
|
public String getReportapi() {
|
|
return this.reportapi;
|
|
}
|
|
|
|
public String getRqdata() {
|
|
return this.rqdata;
|
|
}
|
|
|
|
public Boolean getSentry() {
|
|
return this.sentry;
|
|
}
|
|
|
|
public String getSiteKey() {
|
|
return this.siteKey;
|
|
}
|
|
|
|
public HCaptchaSize getSize() {
|
|
return this.size;
|
|
}
|
|
|
|
public HCaptchaTheme getTheme() {
|
|
return this.theme;
|
|
}
|
|
|
|
@Override // java.lang.Object
|
|
public int hashCode() {
|
|
Boolean sentry = getSentry();
|
|
int i = 43;
|
|
int hashCode = sentry == null ? 43 : sentry.hashCode();
|
|
String siteKey = getSiteKey();
|
|
int hashCode2 = ((hashCode + 59) * 59) + (siteKey == null ? 43 : siteKey.hashCode());
|
|
String rqdata = getRqdata();
|
|
int hashCode3 = (hashCode2 * 59) + (rqdata == null ? 43 : rqdata.hashCode());
|
|
String apiEndpoint = getApiEndpoint();
|
|
int hashCode4 = (hashCode3 * 59) + (apiEndpoint == null ? 43 : apiEndpoint.hashCode());
|
|
String endpoint = getEndpoint();
|
|
int hashCode5 = (hashCode4 * 59) + (endpoint == null ? 43 : endpoint.hashCode());
|
|
String reportapi = getReportapi();
|
|
int hashCode6 = (hashCode5 * 59) + (reportapi == null ? 43 : reportapi.hashCode());
|
|
String assethost = getAssethost();
|
|
int hashCode7 = (hashCode6 * 59) + (assethost == null ? 43 : assethost.hashCode());
|
|
String imghost = getImghost();
|
|
int hashCode8 = (hashCode7 * 59) + (imghost == null ? 43 : imghost.hashCode());
|
|
String locale = getLocale();
|
|
int hashCode9 = (hashCode8 * 59) + (locale == null ? 43 : locale.hashCode());
|
|
HCaptchaSize size = getSize();
|
|
int hashCode10 = (hashCode9 * 59) + (size == null ? 43 : size.hashCode());
|
|
HCaptchaTheme theme = getTheme();
|
|
int i2 = hashCode10 * 59;
|
|
if (theme != null) {
|
|
i = theme.hashCode();
|
|
}
|
|
return i2 + i;
|
|
}
|
|
|
|
public void setApiEndpoint(String str) {
|
|
this.apiEndpoint = str;
|
|
}
|
|
|
|
public void setAssethost(String str) {
|
|
this.assethost = str;
|
|
}
|
|
|
|
public void setEndpoint(String str) {
|
|
this.endpoint = str;
|
|
}
|
|
|
|
public void setImghost(String str) {
|
|
this.imghost = str;
|
|
}
|
|
|
|
public void setLocale(String str) {
|
|
this.locale = str;
|
|
}
|
|
|
|
public void setReportapi(String str) {
|
|
this.reportapi = str;
|
|
}
|
|
|
|
public void setRqdata(String str) {
|
|
this.rqdata = str;
|
|
}
|
|
|
|
public void setSentry(Boolean bool) {
|
|
this.sentry = bool;
|
|
}
|
|
|
|
public void setSiteKey(String str) {
|
|
Objects.requireNonNull(str, "siteKey is marked non-null but is null");
|
|
this.siteKey = str;
|
|
}
|
|
|
|
public void setSize(HCaptchaSize hCaptchaSize) {
|
|
this.size = hCaptchaSize;
|
|
}
|
|
|
|
public void setTheme(HCaptchaTheme hCaptchaTheme) {
|
|
this.theme = hCaptchaTheme;
|
|
}
|
|
|
|
public a toBuilder() {
|
|
a aVar = new a();
|
|
String str = this.siteKey;
|
|
Objects.requireNonNull(str, "siteKey is marked non-null but is null");
|
|
aVar.a = str;
|
|
aVar.f2393c = this.sentry;
|
|
aVar.b = true;
|
|
aVar.d = this.rqdata;
|
|
aVar.f = this.apiEndpoint;
|
|
aVar.e = true;
|
|
aVar.g = this.endpoint;
|
|
aVar.h = this.reportapi;
|
|
aVar.i = this.assethost;
|
|
aVar.j = this.imghost;
|
|
aVar.l = this.locale;
|
|
aVar.k = true;
|
|
aVar.n = this.size;
|
|
aVar.m = true;
|
|
aVar.p = this.theme;
|
|
aVar.o = true;
|
|
return aVar;
|
|
}
|
|
|
|
@Override // java.lang.Object
|
|
public String toString() {
|
|
StringBuilder K = c.d.b.a.a.K("HCaptchaConfig(siteKey=");
|
|
K.append(getSiteKey());
|
|
K.append(", sentry=");
|
|
K.append(getSentry());
|
|
K.append(", rqdata=");
|
|
K.append(getRqdata());
|
|
K.append(", apiEndpoint=");
|
|
K.append(getApiEndpoint());
|
|
K.append(", endpoint=");
|
|
K.append(getEndpoint());
|
|
K.append(", reportapi=");
|
|
K.append(getReportapi());
|
|
K.append(", assethost=");
|
|
K.append(getAssethost());
|
|
K.append(", imghost=");
|
|
K.append(getImghost());
|
|
K.append(", locale=");
|
|
K.append(getLocale());
|
|
K.append(", size=");
|
|
K.append(getSize());
|
|
K.append(", theme=");
|
|
K.append(getTheme());
|
|
K.append(")");
|
|
return K.toString();
|
|
}
|
|
}
|