stdlib.pb.go 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-go v1.23.0
  4. // protoc v3.11.4
  5. // source: stdlib.proto
  6. package stdlib
  7. import (
  8. context "context"
  9. proto "github.com/golang/protobuf/proto"
  10. grpc "google.golang.org/grpc"
  11. codes "google.golang.org/grpc/codes"
  12. status "google.golang.org/grpc/status"
  13. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  14. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  15. reflect "reflect"
  16. sync "sync"
  17. )
  18. const (
  19. // Verify that this generated code is sufficiently up-to-date.
  20. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  21. // Verify that runtime/protoimpl is sufficiently up-to-date.
  22. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  23. )
  24. // This is a compile-time assertion that a sufficiently up-to-date version
  25. // of the legacy proto package is being used.
  26. const _ = proto.ProtoPackageIsVersion4
  27. type DocQueryRequest struct {
  28. state protoimpl.MessageState
  29. sizeCache protoimpl.SizeCache
  30. unknownFields protoimpl.UnknownFields
  31. KeyWords string `protobuf:"bytes,1,opt,name=keyWords,proto3" json:"keyWords,omitempty"` //检索词
  32. PageNum int32 `protobuf:"varint,2,opt,name=pageNum,proto3" json:"pageNum,omitempty"` //页码
  33. }
  34. func (x *DocQueryRequest) Reset() {
  35. *x = DocQueryRequest{}
  36. if protoimpl.UnsafeEnabled {
  37. mi := &file_stdlib_proto_msgTypes[0]
  38. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  39. ms.StoreMessageInfo(mi)
  40. }
  41. }
  42. func (x *DocQueryRequest) String() string {
  43. return protoimpl.X.MessageStringOf(x)
  44. }
  45. func (*DocQueryRequest) ProtoMessage() {}
  46. func (x *DocQueryRequest) ProtoReflect() protoreflect.Message {
  47. mi := &file_stdlib_proto_msgTypes[0]
  48. if protoimpl.UnsafeEnabled && x != nil {
  49. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  50. if ms.LoadMessageInfo() == nil {
  51. ms.StoreMessageInfo(mi)
  52. }
  53. return ms
  54. }
  55. return mi.MessageOf(x)
  56. }
  57. // Deprecated: Use DocQueryRequest.ProtoReflect.Descriptor instead.
  58. func (*DocQueryRequest) Descriptor() ([]byte, []int) {
  59. return file_stdlib_proto_rawDescGZIP(), []int{0}
  60. }
  61. func (x *DocQueryRequest) GetKeyWords() string {
  62. if x != nil {
  63. return x.KeyWords
  64. }
  65. return ""
  66. }
  67. func (x *DocQueryRequest) GetPageNum() int32 {
  68. if x != nil {
  69. return x.PageNum
  70. }
  71. return 0
  72. }
  73. type DocQueryResponse struct {
  74. state protoimpl.MessageState
  75. sizeCache protoimpl.SizeCache
  76. unknownFields protoimpl.UnknownFields
  77. Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` //响应代码
  78. Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"` //响应消息
  79. Docs []*Doc `protobuf:"bytes,3,rep,name=docs,proto3" json:"docs,omitempty"` //文档列表集合,没有分页参数
  80. Total int32 `protobuf:"varint,4,opt,name=total,proto3" json:"total,omitempty"` //总数
  81. }
  82. func (x *DocQueryResponse) Reset() {
  83. *x = DocQueryResponse{}
  84. if protoimpl.UnsafeEnabled {
  85. mi := &file_stdlib_proto_msgTypes[1]
  86. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  87. ms.StoreMessageInfo(mi)
  88. }
  89. }
  90. func (x *DocQueryResponse) String() string {
  91. return protoimpl.X.MessageStringOf(x)
  92. }
  93. func (*DocQueryResponse) ProtoMessage() {}
  94. func (x *DocQueryResponse) ProtoReflect() protoreflect.Message {
  95. mi := &file_stdlib_proto_msgTypes[1]
  96. if protoimpl.UnsafeEnabled && x != nil {
  97. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  98. if ms.LoadMessageInfo() == nil {
  99. ms.StoreMessageInfo(mi)
  100. }
  101. return ms
  102. }
  103. return mi.MessageOf(x)
  104. }
  105. // Deprecated: Use DocQueryResponse.ProtoReflect.Descriptor instead.
  106. func (*DocQueryResponse) Descriptor() ([]byte, []int) {
  107. return file_stdlib_proto_rawDescGZIP(), []int{1}
  108. }
  109. func (x *DocQueryResponse) GetCode() int32 {
  110. if x != nil {
  111. return x.Code
  112. }
  113. return 0
  114. }
  115. func (x *DocQueryResponse) GetMessage() string {
  116. if x != nil {
  117. return x.Message
  118. }
  119. return ""
  120. }
  121. func (x *DocQueryResponse) GetDocs() []*Doc {
  122. if x != nil {
  123. return x.Docs
  124. }
  125. return nil
  126. }
  127. func (x *DocQueryResponse) GetTotal() int32 {
  128. if x != nil {
  129. return x.Total
  130. }
  131. return 0
  132. }
  133. type Doc struct {
  134. state protoimpl.MessageState
  135. sizeCache protoimpl.SizeCache
  136. unknownFields protoimpl.UnknownFields
  137. Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` //文档id
  138. Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` //文档名称
  139. Type int32 `protobuf:"varint,3,opt,name=type,proto3" json:"type,omitempty"` //文档类型
  140. FileSize int32 `protobuf:"varint,4,opt,name=fileSize,proto3" json:"fileSize,omitempty"` //文档大小
  141. PageSize int32 `protobuf:"varint,5,opt,name=pageSize,proto3" json:"pageSize,omitempty"` //文档页码数
  142. Tags string `protobuf:"bytes,6,opt,name=tags,proto3" json:"tags,omitempty"` //文档标签
  143. UserId string `protobuf:"bytes,7,opt,name=userId,proto3" json:"userId,omitempty"` //上传人id
  144. }
  145. func (x *Doc) Reset() {
  146. *x = Doc{}
  147. if protoimpl.UnsafeEnabled {
  148. mi := &file_stdlib_proto_msgTypes[2]
  149. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  150. ms.StoreMessageInfo(mi)
  151. }
  152. }
  153. func (x *Doc) String() string {
  154. return protoimpl.X.MessageStringOf(x)
  155. }
  156. func (*Doc) ProtoMessage() {}
  157. func (x *Doc) ProtoReflect() protoreflect.Message {
  158. mi := &file_stdlib_proto_msgTypes[2]
  159. if protoimpl.UnsafeEnabled && x != nil {
  160. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  161. if ms.LoadMessageInfo() == nil {
  162. ms.StoreMessageInfo(mi)
  163. }
  164. return ms
  165. }
  166. return mi.MessageOf(x)
  167. }
  168. // Deprecated: Use Doc.ProtoReflect.Descriptor instead.
  169. func (*Doc) Descriptor() ([]byte, []int) {
  170. return file_stdlib_proto_rawDescGZIP(), []int{2}
  171. }
  172. func (x *Doc) GetId() string {
  173. if x != nil {
  174. return x.Id
  175. }
  176. return ""
  177. }
  178. func (x *Doc) GetName() string {
  179. if x != nil {
  180. return x.Name
  181. }
  182. return ""
  183. }
  184. func (x *Doc) GetType() int32 {
  185. if x != nil {
  186. return x.Type
  187. }
  188. return 0
  189. }
  190. func (x *Doc) GetFileSize() int32 {
  191. if x != nil {
  192. return x.FileSize
  193. }
  194. return 0
  195. }
  196. func (x *Doc) GetPageSize() int32 {
  197. if x != nil {
  198. return x.PageSize
  199. }
  200. return 0
  201. }
  202. func (x *Doc) GetTags() string {
  203. if x != nil {
  204. return x.Tags
  205. }
  206. return ""
  207. }
  208. func (x *Doc) GetUserId() string {
  209. if x != nil {
  210. return x.UserId
  211. }
  212. return ""
  213. }
  214. type DocChangeReq struct {
  215. state protoimpl.MessageState
  216. sizeCache protoimpl.SizeCache
  217. unknownFields protoimpl.UnknownFields
  218. Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` //文档id
  219. }
  220. func (x *DocChangeReq) Reset() {
  221. *x = DocChangeReq{}
  222. if protoimpl.UnsafeEnabled {
  223. mi := &file_stdlib_proto_msgTypes[3]
  224. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  225. ms.StoreMessageInfo(mi)
  226. }
  227. }
  228. func (x *DocChangeReq) String() string {
  229. return protoimpl.X.MessageStringOf(x)
  230. }
  231. func (*DocChangeReq) ProtoMessage() {}
  232. func (x *DocChangeReq) ProtoReflect() protoreflect.Message {
  233. mi := &file_stdlib_proto_msgTypes[3]
  234. if protoimpl.UnsafeEnabled && x != nil {
  235. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  236. if ms.LoadMessageInfo() == nil {
  237. ms.StoreMessageInfo(mi)
  238. }
  239. return ms
  240. }
  241. return mi.MessageOf(x)
  242. }
  243. // Deprecated: Use DocChangeReq.ProtoReflect.Descriptor instead.
  244. func (*DocChangeReq) Descriptor() ([]byte, []int) {
  245. return file_stdlib_proto_rawDescGZIP(), []int{3}
  246. }
  247. func (x *DocChangeReq) GetId() string {
  248. if x != nil {
  249. return x.Id
  250. }
  251. return ""
  252. }
  253. type DocChangeResp struct {
  254. state protoimpl.MessageState
  255. sizeCache protoimpl.SizeCache
  256. unknownFields protoimpl.UnknownFields
  257. State bool `protobuf:"varint,1,opt,name=state,proto3" json:"state,omitempty"` //是否成功
  258. }
  259. func (x *DocChangeResp) Reset() {
  260. *x = DocChangeResp{}
  261. if protoimpl.UnsafeEnabled {
  262. mi := &file_stdlib_proto_msgTypes[4]
  263. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  264. ms.StoreMessageInfo(mi)
  265. }
  266. }
  267. func (x *DocChangeResp) String() string {
  268. return protoimpl.X.MessageStringOf(x)
  269. }
  270. func (*DocChangeResp) ProtoMessage() {}
  271. func (x *DocChangeResp) ProtoReflect() protoreflect.Message {
  272. mi := &file_stdlib_proto_msgTypes[4]
  273. if protoimpl.UnsafeEnabled && x != nil {
  274. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  275. if ms.LoadMessageInfo() == nil {
  276. ms.StoreMessageInfo(mi)
  277. }
  278. return ms
  279. }
  280. return mi.MessageOf(x)
  281. }
  282. // Deprecated: Use DocChangeResp.ProtoReflect.Descriptor instead.
  283. func (*DocChangeResp) Descriptor() ([]byte, []int) {
  284. return file_stdlib_proto_rawDescGZIP(), []int{4}
  285. }
  286. func (x *DocChangeResp) GetState() bool {
  287. if x != nil {
  288. return x.State
  289. }
  290. return false
  291. }
  292. var File_stdlib_proto protoreflect.FileDescriptor
  293. var file_stdlib_proto_rawDesc = []byte{
  294. 0x0a, 0x0c, 0x73, 0x74, 0x64, 0x6c, 0x69, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x06,
  295. 0x73, 0x74, 0x64, 0x6c, 0x69, 0x62, 0x22, 0x47, 0x0a, 0x0f, 0x44, 0x6f, 0x63, 0x51, 0x75, 0x65,
  296. 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x6b, 0x65, 0x79,
  297. 0x57, 0x6f, 0x72, 0x64, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6b, 0x65, 0x79,
  298. 0x57, 0x6f, 0x72, 0x64, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x61, 0x67, 0x65, 0x4e, 0x75, 0x6d,
  299. 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x70, 0x61, 0x67, 0x65, 0x4e, 0x75, 0x6d, 0x22,
  300. 0x77, 0x0a, 0x10, 0x44, 0x6f, 0x63, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f,
  301. 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
  302. 0x05, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61,
  303. 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67,
  304. 0x65, 0x12, 0x1f, 0x0a, 0x04, 0x64, 0x6f, 0x63, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32,
  305. 0x0b, 0x2e, 0x73, 0x74, 0x64, 0x6c, 0x69, 0x62, 0x2e, 0x44, 0x6f, 0x63, 0x52, 0x04, 0x64, 0x6f,
  306. 0x63, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28,
  307. 0x05, 0x52, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x22, 0xa1, 0x01, 0x0a, 0x03, 0x44, 0x6f, 0x63,
  308. 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64,
  309. 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
  310. 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01,
  311. 0x28, 0x05, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65,
  312. 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65,
  313. 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65,
  314. 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65,
  315. 0x12, 0x12, 0x0a, 0x04, 0x74, 0x61, 0x67, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
  316. 0x74, 0x61, 0x67, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x07,
  317. 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x22, 0x1e, 0x0a, 0x0c,
  318. 0x44, 0x6f, 0x63, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x71, 0x12, 0x0e, 0x0a, 0x02,
  319. 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x25, 0x0a, 0x0d,
  320. 0x44, 0x6f, 0x63, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x14, 0x0a,
  321. 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x73, 0x74,
  322. 0x61, 0x74, 0x65, 0x32, 0xb4, 0x01, 0x0a, 0x06, 0x53, 0x74, 0x64, 0x6c, 0x69, 0x62, 0x12, 0x3d,
  323. 0x0a, 0x08, 0x44, 0x6f, 0x63, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x17, 0x2e, 0x73, 0x74, 0x64,
  324. 0x6c, 0x69, 0x62, 0x2e, 0x44, 0x6f, 0x63, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75,
  325. 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x73, 0x74, 0x64, 0x6c, 0x69, 0x62, 0x2e, 0x44, 0x6f, 0x63,
  326. 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x34, 0x0a,
  327. 0x05, 0x44, 0x6f, 0x63, 0x4f, 0x6e, 0x12, 0x14, 0x2e, 0x73, 0x74, 0x64, 0x6c, 0x69, 0x62, 0x2e,
  328. 0x44, 0x6f, 0x63, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x15, 0x2e, 0x73,
  329. 0x74, 0x64, 0x6c, 0x69, 0x62, 0x2e, 0x44, 0x6f, 0x63, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52,
  330. 0x65, 0x73, 0x70, 0x12, 0x35, 0x0a, 0x06, 0x44, 0x6f, 0x63, 0x4f, 0x66, 0x66, 0x12, 0x14, 0x2e,
  331. 0x73, 0x74, 0x64, 0x6c, 0x69, 0x62, 0x2e, 0x44, 0x6f, 0x63, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65,
  332. 0x52, 0x65, 0x71, 0x1a, 0x15, 0x2e, 0x73, 0x74, 0x64, 0x6c, 0x69, 0x62, 0x2e, 0x44, 0x6f, 0x63,
  333. 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
  334. 0x6f, 0x33,
  335. }
  336. var (
  337. file_stdlib_proto_rawDescOnce sync.Once
  338. file_stdlib_proto_rawDescData = file_stdlib_proto_rawDesc
  339. )
  340. func file_stdlib_proto_rawDescGZIP() []byte {
  341. file_stdlib_proto_rawDescOnce.Do(func() {
  342. file_stdlib_proto_rawDescData = protoimpl.X.CompressGZIP(file_stdlib_proto_rawDescData)
  343. })
  344. return file_stdlib_proto_rawDescData
  345. }
  346. var file_stdlib_proto_msgTypes = make([]protoimpl.MessageInfo, 5)
  347. var file_stdlib_proto_goTypes = []interface{}{
  348. (*DocQueryRequest)(nil), // 0: stdlib.DocQueryRequest
  349. (*DocQueryResponse)(nil), // 1: stdlib.DocQueryResponse
  350. (*Doc)(nil), // 2: stdlib.Doc
  351. (*DocChangeReq)(nil), // 3: stdlib.DocChangeReq
  352. (*DocChangeResp)(nil), // 4: stdlib.DocChangeResp
  353. }
  354. var file_stdlib_proto_depIdxs = []int32{
  355. 2, // 0: stdlib.DocQueryResponse.docs:type_name -> stdlib.Doc
  356. 0, // 1: stdlib.Stdlib.DocQuery:input_type -> stdlib.DocQueryRequest
  357. 3, // 2: stdlib.Stdlib.DocOn:input_type -> stdlib.DocChangeReq
  358. 3, // 3: stdlib.Stdlib.DocOff:input_type -> stdlib.DocChangeReq
  359. 1, // 4: stdlib.Stdlib.DocQuery:output_type -> stdlib.DocQueryResponse
  360. 4, // 5: stdlib.Stdlib.DocOn:output_type -> stdlib.DocChangeResp
  361. 4, // 6: stdlib.Stdlib.DocOff:output_type -> stdlib.DocChangeResp
  362. 4, // [4:7] is the sub-list for method output_type
  363. 1, // [1:4] is the sub-list for method input_type
  364. 1, // [1:1] is the sub-list for extension type_name
  365. 1, // [1:1] is the sub-list for extension extendee
  366. 0, // [0:1] is the sub-list for field type_name
  367. }
  368. func init() { file_stdlib_proto_init() }
  369. func file_stdlib_proto_init() {
  370. if File_stdlib_proto != nil {
  371. return
  372. }
  373. if !protoimpl.UnsafeEnabled {
  374. file_stdlib_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
  375. switch v := v.(*DocQueryRequest); i {
  376. case 0:
  377. return &v.state
  378. case 1:
  379. return &v.sizeCache
  380. case 2:
  381. return &v.unknownFields
  382. default:
  383. return nil
  384. }
  385. }
  386. file_stdlib_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
  387. switch v := v.(*DocQueryResponse); i {
  388. case 0:
  389. return &v.state
  390. case 1:
  391. return &v.sizeCache
  392. case 2:
  393. return &v.unknownFields
  394. default:
  395. return nil
  396. }
  397. }
  398. file_stdlib_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
  399. switch v := v.(*Doc); i {
  400. case 0:
  401. return &v.state
  402. case 1:
  403. return &v.sizeCache
  404. case 2:
  405. return &v.unknownFields
  406. default:
  407. return nil
  408. }
  409. }
  410. file_stdlib_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
  411. switch v := v.(*DocChangeReq); i {
  412. case 0:
  413. return &v.state
  414. case 1:
  415. return &v.sizeCache
  416. case 2:
  417. return &v.unknownFields
  418. default:
  419. return nil
  420. }
  421. }
  422. file_stdlib_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
  423. switch v := v.(*DocChangeResp); i {
  424. case 0:
  425. return &v.state
  426. case 1:
  427. return &v.sizeCache
  428. case 2:
  429. return &v.unknownFields
  430. default:
  431. return nil
  432. }
  433. }
  434. }
  435. type x struct{}
  436. out := protoimpl.TypeBuilder{
  437. File: protoimpl.DescBuilder{
  438. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  439. RawDescriptor: file_stdlib_proto_rawDesc,
  440. NumEnums: 0,
  441. NumMessages: 5,
  442. NumExtensions: 0,
  443. NumServices: 1,
  444. },
  445. GoTypes: file_stdlib_proto_goTypes,
  446. DependencyIndexes: file_stdlib_proto_depIdxs,
  447. MessageInfos: file_stdlib_proto_msgTypes,
  448. }.Build()
  449. File_stdlib_proto = out.File
  450. file_stdlib_proto_rawDesc = nil
  451. file_stdlib_proto_goTypes = nil
  452. file_stdlib_proto_depIdxs = nil
  453. }
  454. // Reference imports to suppress errors if they are not otherwise used.
  455. var _ context.Context
  456. var _ grpc.ClientConnInterface
  457. // This is a compile-time assertion to ensure that this generated file
  458. // is compatible with the grpc package it is being compiled against.
  459. const _ = grpc.SupportPackageIsVersion6
  460. // StdlibClient is the client API for Stdlib service.
  461. //
  462. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
  463. type StdlibClient interface {
  464. DocQuery(ctx context.Context, in *DocQueryRequest, opts ...grpc.CallOption) (*DocQueryResponse, error)
  465. DocOn(ctx context.Context, in *DocChangeReq, opts ...grpc.CallOption) (*DocChangeResp, error)
  466. DocOff(ctx context.Context, in *DocChangeReq, opts ...grpc.CallOption) (*DocChangeResp, error)
  467. }
  468. type stdlibClient struct {
  469. cc grpc.ClientConnInterface
  470. }
  471. func NewStdlibClient(cc grpc.ClientConnInterface) StdlibClient {
  472. return &stdlibClient{cc}
  473. }
  474. func (c *stdlibClient) DocQuery(ctx context.Context, in *DocQueryRequest, opts ...grpc.CallOption) (*DocQueryResponse, error) {
  475. out := new(DocQueryResponse)
  476. err := c.cc.Invoke(ctx, "/stdlib.Stdlib/DocQuery", in, out, opts...)
  477. if err != nil {
  478. return nil, err
  479. }
  480. return out, nil
  481. }
  482. func (c *stdlibClient) DocOn(ctx context.Context, in *DocChangeReq, opts ...grpc.CallOption) (*DocChangeResp, error) {
  483. out := new(DocChangeResp)
  484. err := c.cc.Invoke(ctx, "/stdlib.Stdlib/DocOn", in, out, opts...)
  485. if err != nil {
  486. return nil, err
  487. }
  488. return out, nil
  489. }
  490. func (c *stdlibClient) DocOff(ctx context.Context, in *DocChangeReq, opts ...grpc.CallOption) (*DocChangeResp, error) {
  491. out := new(DocChangeResp)
  492. err := c.cc.Invoke(ctx, "/stdlib.Stdlib/DocOff", in, out, opts...)
  493. if err != nil {
  494. return nil, err
  495. }
  496. return out, nil
  497. }
  498. // StdlibServer is the server API for Stdlib service.
  499. type StdlibServer interface {
  500. DocQuery(context.Context, *DocQueryRequest) (*DocQueryResponse, error)
  501. DocOn(context.Context, *DocChangeReq) (*DocChangeResp, error)
  502. DocOff(context.Context, *DocChangeReq) (*DocChangeResp, error)
  503. }
  504. // UnimplementedStdlibServer can be embedded to have forward compatible implementations.
  505. type UnimplementedStdlibServer struct {
  506. }
  507. func (*UnimplementedStdlibServer) DocQuery(context.Context, *DocQueryRequest) (*DocQueryResponse, error) {
  508. return nil, status.Errorf(codes.Unimplemented, "method DocQuery not implemented")
  509. }
  510. func (*UnimplementedStdlibServer) DocOn(context.Context, *DocChangeReq) (*DocChangeResp, error) {
  511. return nil, status.Errorf(codes.Unimplemented, "method DocOn not implemented")
  512. }
  513. func (*UnimplementedStdlibServer) DocOff(context.Context, *DocChangeReq) (*DocChangeResp, error) {
  514. return nil, status.Errorf(codes.Unimplemented, "method DocOff not implemented")
  515. }
  516. func RegisterStdlibServer(s *grpc.Server, srv StdlibServer) {
  517. s.RegisterService(&_Stdlib_serviceDesc, srv)
  518. }
  519. func _Stdlib_DocQuery_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  520. in := new(DocQueryRequest)
  521. if err := dec(in); err != nil {
  522. return nil, err
  523. }
  524. if interceptor == nil {
  525. return srv.(StdlibServer).DocQuery(ctx, in)
  526. }
  527. info := &grpc.UnaryServerInfo{
  528. Server: srv,
  529. FullMethod: "/stdlib.Stdlib/DocQuery",
  530. }
  531. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  532. return srv.(StdlibServer).DocQuery(ctx, req.(*DocQueryRequest))
  533. }
  534. return interceptor(ctx, in, info, handler)
  535. }
  536. func _Stdlib_DocOn_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  537. in := new(DocChangeReq)
  538. if err := dec(in); err != nil {
  539. return nil, err
  540. }
  541. if interceptor == nil {
  542. return srv.(StdlibServer).DocOn(ctx, in)
  543. }
  544. info := &grpc.UnaryServerInfo{
  545. Server: srv,
  546. FullMethod: "/stdlib.Stdlib/DocOn",
  547. }
  548. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  549. return srv.(StdlibServer).DocOn(ctx, req.(*DocChangeReq))
  550. }
  551. return interceptor(ctx, in, info, handler)
  552. }
  553. func _Stdlib_DocOff_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  554. in := new(DocChangeReq)
  555. if err := dec(in); err != nil {
  556. return nil, err
  557. }
  558. if interceptor == nil {
  559. return srv.(StdlibServer).DocOff(ctx, in)
  560. }
  561. info := &grpc.UnaryServerInfo{
  562. Server: srv,
  563. FullMethod: "/stdlib.Stdlib/DocOff",
  564. }
  565. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  566. return srv.(StdlibServer).DocOff(ctx, req.(*DocChangeReq))
  567. }
  568. return interceptor(ctx, in, info, handler)
  569. }
  570. var _Stdlib_serviceDesc = grpc.ServiceDesc{
  571. ServiceName: "stdlib.Stdlib",
  572. HandlerType: (*StdlibServer)(nil),
  573. Methods: []grpc.MethodDesc{
  574. {
  575. MethodName: "DocQuery",
  576. Handler: _Stdlib_DocQuery_Handler,
  577. },
  578. {
  579. MethodName: "DocOn",
  580. Handler: _Stdlib_DocOn_Handler,
  581. },
  582. {
  583. MethodName: "DocOff",
  584. Handler: _Stdlib_DocOff_Handler,
  585. },
  586. },
  587. Streams: []grpc.StreamDesc{},
  588. Metadata: "stdlib.proto",
  589. }