mirror of
https://github.com/tiennm99/zfoo.git
synced 2026-05-20 10:25:19 +00:00
perf[protocol]: 使用模板生成协议
This commit is contained in:
@@ -13,7 +13,7 @@ namespace csharp
|
||||
|
||||
ProtocolManager.InitProtocol();
|
||||
// 获取复杂对象的字节流
|
||||
var complexObjectBytes = File.ReadAllBytes("C:\\zfoo\\protocol\\src\\test\\resources\\ComplexObject.bytes");
|
||||
var complexObjectBytes = File.ReadAllBytes("../resources/ComplexObject.bytes");
|
||||
var buffer = ByteBuffer.ValueOf();
|
||||
buffer.WriteBytes(complexObjectBytes);
|
||||
var packet = ProtocolManager.Read(buffer);
|
||||
@@ -187,4 +187,4 @@ namespace csharp
|
||||
throw new Exception("a is not equals b");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user