增加延迟检测功能
This commit is contained in:
@@ -9,7 +9,7 @@ public class KLALBBlock {
|
||||
volatile long number;
|
||||
|
||||
|
||||
//volatile long time=-1;
|
||||
volatile long time=-1;
|
||||
volatile Thread thread;
|
||||
public KLALBBlock(byte[] b, int size,long number) {
|
||||
data=b;
|
||||
@@ -23,6 +23,10 @@ public class KLALBBlock {
|
||||
public String toString() {
|
||||
if(number>0) {
|
||||
return "DATA"+number+":"+size;
|
||||
}else if(number==0){
|
||||
return "PING";
|
||||
}else if(number==Long.MIN_VALUE){
|
||||
return "PONG";
|
||||
}else {
|
||||
return "ACK"+(-number);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user