增加日志输出内容

This commit is contained in:
lbl8603
2024-05-10 23:19:52 +08:00
parent 9df324f402
commit 0e4294415e
7 changed files with 90 additions and 17 deletions
+35 -13
View File
@@ -1,13 +1,16 @@
package top.wherewego.vnt.jni;
import java.io.Serializable;
import java.util.Arrays;
/**
* 启动配置
*
* @author https://github.com/lbl8603/vnt
*/
public class Config {
public class Config implements Serializable {
/**
* 是否是tap模式,仅支持windows和linux
* 是否是tap模式,仅支持windows
*/
private boolean tap;
/**
@@ -38,10 +41,6 @@ public class Config {
* 是否开启服务端加密
*/
private boolean serverEncrypt;
/**
* 仅使用中继转发
*/
private boolean relay;
/**
* 设备id,请使用唯一值
*/
@@ -174,13 +173,6 @@ public class Config {
this.serverEncrypt = serverEncrypt;
}
public boolean isRelay() {
return relay;
}
public void setRelay(boolean relay) {
this.relay = relay;
}
public String getDeviceId() {
return deviceId;
@@ -308,4 +300,34 @@ public class Config {
public void setPacketDelay(Integer packetDelay) {
this.packetDelay = packetDelay;
}
@Override
public String toString() {
return "Config{" +
"tap=" + tap +
", token='" + token + '\'' +
", name='" + name + '\'' +
", password='" + password + '\'' +
", cipherModel='" + cipherModel + '\'' +
", punchModel='" + punchModel + '\'' +
", mtu=" + mtu +
", serverEncrypt=" + serverEncrypt +
", deviceId='" + deviceId + '\'' +
", server='" + server + '\'' +
", dns=" + Arrays.toString(dns) +
", portMapping=" + Arrays.toString(portMapping) +
", stunServer=" + Arrays.toString(stunServer) +
", tcp=" + tcp +
", ip='" + ip + '\'' +
", finger=" + finger +
", firstLatency=" + firstLatency +
", inIps=" + Arrays.toString(inIps) +
", outIps=" + Arrays.toString(outIps) +
", ports=" + Arrays.toString(ports) +
", deviceName='" + deviceName + '\'' +
", useChannel='" + useChannel + '\'' +
", packetLossRate=" + packetLossRate +
", packetDelay=" + packetDelay +
'}';
}
}