erlang自定义二进制协议
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 line
405 B

  1. %% 测试协议 注释可以用 % 也可以用 //
  2. test {
  3. string aa;
  4. }
  5. // phoneNumber info
  6. phoneNumber{
  7. test number; //电话号码
  8. int32 type; //类型
  9. }
  10. %% person info
  11. person{
  12. string name; %% 名字
  13. int32 id; %% id
  14. string email; //邮箱
  15. list[phoneNumber] phone; // list of phoneNumber
  16. }
  17. %% addressBook info
  18. addressBook {
  19. list[person] person;
  20. list[person] other;
  21. }