Fast Orange v3.5.3版本的 MD5 值为:33b91aba50c566533dfd683a85f79158
以下内容为反编译后的 AbstractBean.java 源代码,内容仅作参考
package com.github.shadowsocks.fmt;
import androidx.annotation.NonNull;
import com.free.vpn.proxy.hotspot.ex0;
import com.free.vpn.proxy.hotspot.wp1;
import com.free.vpn.proxy.hotspot.xp;
import com.free.vpn.proxy.hotspot.yp;
import com.github.shadowsocks.fmt.gson.GsonsKt;
import com.github.shadowsocks.ktx.KryosKt;
import com.github.shadowsocks.ktx.NetsKt;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
public abstract class AbstractBean extends Serializable implements Cloneable {
public static final String LOCALHOST = "127.0.0.1";
public int extraType;
public transient String finalAddress;
public transient int finalPort;
public String group;
public transient boolean isChain;
public String name;
public String owner;
public String profileId;
private transient boolean serializeWithoutName;
public String serverAddress;
public Integer serverPort;
public List<String> tags;
public boolean allowInsecure() {
return false;
}
public void applyFeatureSettings(AbstractBean abstractBean) {
}
public boolean canICMPing() {
return true;
}
public boolean canMapping() {
return true;
}
public boolean canTCPing() {
return true;
}
@Override
public abstract AbstractBean mo4410clone();
public void deserialize(xp xpVar) {
this.serverAddress = xpVar.f();
this.serverPort = Integer.valueOf(xpVar.readInt());
}
@Override
public void deserializeFromBuffer(@NonNull xp xpVar) {
deserialize(xpVar);
int readInt = xpVar.readInt();
this.name = xpVar.f();
int readInt2 = xpVar.readInt();
this.extraType = readInt2;
if (readInt2 == 0) {
return;
}
this.profileId = xpVar.f();
if (this.extraType == 1) {
this.group = xpVar.f();
if (readInt >= 1) {
this.owner = xpVar.f();
}
this.tags = KryosKt.readStringList(xpVar);
}
}
public String displayAddress() {
return NetsKt.wrapOriginUri(this);
}
public String displayName() {
return wp1.z(this.name) ? this.name : displayAddress();
}
public boolean equals(Object obj) {
if (this == obj) {
return true;
}
if (obj == null || getClass() != obj.getClass()) {
return false;
}
try {
this.serializeWithoutName = true;
((AbstractBean) obj).serializeWithoutName = true;
return Arrays.equals(KryoConverters.serialize(this), KryoConverters.serialize((AbstractBean) obj));
} finally {
this.serializeWithoutName = false;
((AbstractBean) obj).serializeWithoutName = false;
}
}
public int hashCode() {
try {
this.serializeWithoutName = true;
return Arrays.hashCode(KryoConverters.serialize(this));
} finally {
this.serializeWithoutName = false;
}
}
@Override
public void initializeDefaultValues() {
String unwrapHost;
if (!wp1.v(this.serverAddress)) {
unwrapHost = (this.serverAddress.startsWith("[") && this.serverAddress.endsWith("]")) ? NetsKt.unwrapHost(this.serverAddress) : "127.0.0.1";
if (this.serverPort == null) {
this.serverPort = 1080;
}
if (this.name == null) {
this.name = "";
}
this.finalAddress = this.serverAddress;
this.finalPort = this.serverPort.intValue();
if (this.profileId == null) {
this.profileId = "";
}
if (this.group == null) {
this.group = "";
}
if (this.tags != null) {
this.tags = new ArrayList();
return;
}
return;
}
this.serverAddress = unwrapHost;
if (this.serverPort == null) {
}
if (this.name == null) {
}
this.finalAddress = this.serverAddress;
this.finalPort = this.serverPort.intValue();
if (this.profileId == null) {
}
if (this.group == null) {
}
if (this.tags != null) {
}
}
public String network() {
return "tcp,udp";
}
public void serialize(yp ypVar) {
ypVar.p(this.serverAddress);
ypVar.f(this.serverPort.intValue());
}
@Override
public void serializeToBuffer(@NonNull yp ypVar) {
serialize(ypVar);
ypVar.f(1);
if (!this.serializeWithoutName) {
ypVar.p(this.name);
}
ypVar.f(this.extraType);
if (this.extraType == 0) {
return;
}
ypVar.p(this.profileId);
if (this.extraType == 1) {
ypVar.p(this.group);
ypVar.p(this.owner);
KryosKt.writeStringList(ypVar, this.tags);
}
}
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(getClass().getSimpleName());
sb.append(" ");
String json = GsonsKt.getGson().toJson(this);
StringBuilder sb2 = new StringBuilder();
int length = json.length();
Character ch = null;
int i = 0;
boolean z = false;
int i2 = 0;
while (i < length) {
char charAt = json.charAt(i);
if ('\"' != charAt && '\'' != charAt) {
if ('\\' == charAt) {
if (ch != null) {
z = !z;
sb2.append(charAt);
i++;
} else {
sb2.append(charAt);
}
}
if (ch == null) {
if (charAt != '[' && charAt != '{') {
if (charAt != ']' && charAt != '}') {
if (charAt == ',') {
sb2.append(charAt);
sb2.append('\n');
} else if (i > 1) {
}
} else {
sb2.append('\n');
i2--;
sb2.append(ex0.y(i2));
}
} else {
if (i > 1 && json.charAt(i - 1) == ':') {
sb2.append('\n');
sb2.append(ex0.y(i2));
}
sb2.append(charAt);
sb2.append('\n');
i2++;
}
sb2.append(ex0.y(i2));
i++;
}
sb2.append(charAt);
i++;
} else {
if (ch == null) {
ch = Character.valueOf(charAt);
} else if (z) {
z = false;
} else if (ch.equals(Character.valueOf(charAt))) {
ch = null;
}
if (i > 1) {
}
sb2.append(charAt);
i++;
}
}
sb.append(sb2.toString());
return sb.toString();
}
}