proto_tran 0.1.36

proto_tran
Documentation

proto_tran : protobuf for i18n

syntax = "proto3";

message LangTxt
{
  uint32 lang = 1;
  string txt = 2;
}

enum Filetype {
  Md = 0;
  Yml = 1;
}

message UpdateLi
{
  Filetype filetype = 1;
  /* 源文本的语言 */
  uint32 src_lang = 2;
  bytes hash = 3;
  repeated LangTxt li = 4;
}

// 更新缓存的接口
message UpdateCache
{
  repeated UpdateLi update_li = 1 [ (rust.nullable_field) = false ];
}

// 翻译文件的接口
// message Tran
// {
//   uint32 from_lang = 1;
//   uint32 to_lang = 2;
//   string txt = 3;
//   // 术语替换放到客户端完成,
//   // repeated Term term_li = 4;
// }