fileText.pb.go 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-go v1.23.0
  4. // protoc v3.12.4
  5. // source: fileText.proto
  6. //附件传输
  7. package proto
  8. import (
  9. context "context"
  10. proto "github.com/golang/protobuf/proto"
  11. grpc "google.golang.org/grpc"
  12. codes "google.golang.org/grpc/codes"
  13. status "google.golang.org/grpc/status"
  14. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  15. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  16. reflect "reflect"
  17. sync "sync"
  18. )
  19. const (
  20. // Verify that this generated code is sufficiently up-to-date.
  21. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  22. // Verify that runtime/protoimpl is sufficiently up-to-date.
  23. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  24. )
  25. // This is a compile-time assertion that a sufficiently up-to-date version
  26. // of the legacy proto package is being used.
  27. const _ = proto.ProtoPackageIsVersion4
  28. type FileRequest struct {
  29. state protoimpl.MessageState
  30. sizeCache protoimpl.SizeCache
  31. unknownFields protoimpl.UnknownFields
  32. Message []*Request `protobuf:"bytes,1,rep,name=message,proto3" json:"message,omitempty"` //文件名称
  33. Other string `protobuf:"bytes,2,opt,name=Other,proto3" json:"Other,omitempty"`
  34. Topic string `protobuf:"bytes,3,opt,name=Topic,proto3" json:"Topic,omitempty"`
  35. }
  36. func (x *FileRequest) Reset() {
  37. *x = FileRequest{}
  38. if protoimpl.UnsafeEnabled {
  39. mi := &file_fileText_proto_msgTypes[0]
  40. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  41. ms.StoreMessageInfo(mi)
  42. }
  43. }
  44. func (x *FileRequest) String() string {
  45. return protoimpl.X.MessageStringOf(x)
  46. }
  47. func (*FileRequest) ProtoMessage() {}
  48. func (x *FileRequest) ProtoReflect() protoreflect.Message {
  49. mi := &file_fileText_proto_msgTypes[0]
  50. if protoimpl.UnsafeEnabled && x != nil {
  51. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  52. if ms.LoadMessageInfo() == nil {
  53. ms.StoreMessageInfo(mi)
  54. }
  55. return ms
  56. }
  57. return mi.MessageOf(x)
  58. }
  59. // Deprecated: Use FileRequest.ProtoReflect.Descriptor instead.
  60. func (*FileRequest) Descriptor() ([]byte, []int) {
  61. return file_fileText_proto_rawDescGZIP(), []int{0}
  62. }
  63. func (x *FileRequest) GetMessage() []*Request {
  64. if x != nil {
  65. return x.Message
  66. }
  67. return nil
  68. }
  69. func (x *FileRequest) GetOther() string {
  70. if x != nil {
  71. return x.Other
  72. }
  73. return ""
  74. }
  75. func (x *FileRequest) GetTopic() string {
  76. if x != nil {
  77. return x.Topic
  78. }
  79. return ""
  80. }
  81. type Request struct {
  82. state protoimpl.MessageState
  83. sizeCache protoimpl.SizeCache
  84. unknownFields protoimpl.UnknownFields
  85. FileName string `protobuf:"bytes,1,opt,name=fileName,proto3" json:"fileName,omitempty"` //文件名称
  86. FileUrl string `protobuf:"bytes,2,opt,name=fileUrl,proto3" json:"fileUrl,omitempty"` //下载的url
  87. FileBytes []byte `protobuf:"bytes,3,opt,name=fileBytes,proto3" json:"fileBytes,omitempty"` //文件字节流
  88. FileType string `protobuf:"bytes,4,opt,name=fileType,proto3" json:"fileType,omitempty"` //文件类型 pdf ,xls ,doc
  89. ReturnType int32 `protobuf:"varint,5,opt,name=returnType,proto3" json:"returnType,omitempty"` //文件类型 {0:url,1:content,2:url+content} 默认0
  90. ExtractType int32 `protobuf:"varint,6,opt,name=extractType,proto3" json:"extractType,omitempty"` //解析文件类型{0:url,1:fileBytes,2:oss} 默认2
  91. }
  92. func (x *Request) Reset() {
  93. *x = Request{}
  94. if protoimpl.UnsafeEnabled {
  95. mi := &file_fileText_proto_msgTypes[1]
  96. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  97. ms.StoreMessageInfo(mi)
  98. }
  99. }
  100. func (x *Request) String() string {
  101. return protoimpl.X.MessageStringOf(x)
  102. }
  103. func (*Request) ProtoMessage() {}
  104. func (x *Request) ProtoReflect() protoreflect.Message {
  105. mi := &file_fileText_proto_msgTypes[1]
  106. if protoimpl.UnsafeEnabled && x != nil {
  107. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  108. if ms.LoadMessageInfo() == nil {
  109. ms.StoreMessageInfo(mi)
  110. }
  111. return ms
  112. }
  113. return mi.MessageOf(x)
  114. }
  115. // Deprecated: Use Request.ProtoReflect.Descriptor instead.
  116. func (*Request) Descriptor() ([]byte, []int) {
  117. return file_fileText_proto_rawDescGZIP(), []int{1}
  118. }
  119. func (x *Request) GetFileName() string {
  120. if x != nil {
  121. return x.FileName
  122. }
  123. return ""
  124. }
  125. func (x *Request) GetFileUrl() string {
  126. if x != nil {
  127. return x.FileUrl
  128. }
  129. return ""
  130. }
  131. func (x *Request) GetFileBytes() []byte {
  132. if x != nil {
  133. return x.FileBytes
  134. }
  135. return nil
  136. }
  137. func (x *Request) GetFileType() string {
  138. if x != nil {
  139. return x.FileType
  140. }
  141. return ""
  142. }
  143. func (x *Request) GetReturnType() int32 {
  144. if x != nil {
  145. return x.ReturnType
  146. }
  147. return 0
  148. }
  149. func (x *Request) GetExtractType() int32 {
  150. if x != nil {
  151. return x.ExtractType
  152. }
  153. return 0
  154. }
  155. type FileResponse struct {
  156. state protoimpl.MessageState
  157. sizeCache protoimpl.SizeCache
  158. unknownFields protoimpl.UnknownFields
  159. Result []*Result `protobuf:"bytes,1,rep,name=result,proto3" json:"result,omitempty"` //返回结果
  160. Other string `protobuf:"bytes,2,opt,name=Other,proto3" json:"Other,omitempty"`
  161. }
  162. func (x *FileResponse) Reset() {
  163. *x = FileResponse{}
  164. if protoimpl.UnsafeEnabled {
  165. mi := &file_fileText_proto_msgTypes[2]
  166. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  167. ms.StoreMessageInfo(mi)
  168. }
  169. }
  170. func (x *FileResponse) String() string {
  171. return protoimpl.X.MessageStringOf(x)
  172. }
  173. func (*FileResponse) ProtoMessage() {}
  174. func (x *FileResponse) ProtoReflect() protoreflect.Message {
  175. mi := &file_fileText_proto_msgTypes[2]
  176. if protoimpl.UnsafeEnabled && x != nil {
  177. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  178. if ms.LoadMessageInfo() == nil {
  179. ms.StoreMessageInfo(mi)
  180. }
  181. return ms
  182. }
  183. return mi.MessageOf(x)
  184. }
  185. // Deprecated: Use FileResponse.ProtoReflect.Descriptor instead.
  186. func (*FileResponse) Descriptor() ([]byte, []int) {
  187. return file_fileText_proto_rawDescGZIP(), []int{2}
  188. }
  189. func (x *FileResponse) GetResult() []*Result {
  190. if x != nil {
  191. return x.Result
  192. }
  193. return nil
  194. }
  195. func (x *FileResponse) GetOther() string {
  196. if x != nil {
  197. return x.Other
  198. }
  199. return ""
  200. }
  201. type Result struct {
  202. state protoimpl.MessageState
  203. sizeCache protoimpl.SizeCache
  204. unknownFields protoimpl.UnknownFields
  205. FileName string `protobuf:"bytes,1,opt,name=fileName,proto3" json:"fileName,omitempty"` //文件名称
  206. TextContent string `protobuf:"bytes,2,opt,name=textContent,proto3" json:"textContent,omitempty"` //文本内容
  207. TextUrl string `protobuf:"bytes,3,opt,name=textUrl,proto3" json:"textUrl,omitempty"` //文本URL
  208. FilePath string `protobuf:"bytes,4,opt,name=filePath,proto3" json:"filePath,omitempty"` //文件路径
  209. ErrorState string `protobuf:"bytes,5,opt,name=errorState,proto3" json:"errorState,omitempty"` //状态{200:解析成功,300:下载失败,400:解析失败}
  210. }
  211. func (x *Result) Reset() {
  212. *x = Result{}
  213. if protoimpl.UnsafeEnabled {
  214. mi := &file_fileText_proto_msgTypes[3]
  215. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  216. ms.StoreMessageInfo(mi)
  217. }
  218. }
  219. func (x *Result) String() string {
  220. return protoimpl.X.MessageStringOf(x)
  221. }
  222. func (*Result) ProtoMessage() {}
  223. func (x *Result) ProtoReflect() protoreflect.Message {
  224. mi := &file_fileText_proto_msgTypes[3]
  225. if protoimpl.UnsafeEnabled && x != nil {
  226. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  227. if ms.LoadMessageInfo() == nil {
  228. ms.StoreMessageInfo(mi)
  229. }
  230. return ms
  231. }
  232. return mi.MessageOf(x)
  233. }
  234. // Deprecated: Use Result.ProtoReflect.Descriptor instead.
  235. func (*Result) Descriptor() ([]byte, []int) {
  236. return file_fileText_proto_rawDescGZIP(), []int{3}
  237. }
  238. func (x *Result) GetFileName() string {
  239. if x != nil {
  240. return x.FileName
  241. }
  242. return ""
  243. }
  244. func (x *Result) GetTextContent() string {
  245. if x != nil {
  246. return x.TextContent
  247. }
  248. return ""
  249. }
  250. func (x *Result) GetTextUrl() string {
  251. if x != nil {
  252. return x.TextUrl
  253. }
  254. return ""
  255. }
  256. func (x *Result) GetFilePath() string {
  257. if x != nil {
  258. return x.FilePath
  259. }
  260. return ""
  261. }
  262. func (x *Result) GetErrorState() string {
  263. if x != nil {
  264. return x.ErrorState
  265. }
  266. return ""
  267. }
  268. var File_fileText_proto protoreflect.FileDescriptor
  269. var file_fileText_proto_rawDesc = []byte{
  270. 0x0a, 0x0e, 0x66, 0x69, 0x6c, 0x65, 0x54, 0x65, 0x78, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
  271. 0x12, 0x05, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x63, 0x0a, 0x0b, 0x46, 0x69, 0x6c, 0x65, 0x52,
  272. 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x28, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67,
  273. 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e,
  274. 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65,
  275. 0x12, 0x14, 0x0a, 0x05, 0x4f, 0x74, 0x68, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
  276. 0x05, 0x4f, 0x74, 0x68, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x6f, 0x70, 0x69, 0x63, 0x18,
  277. 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x6f, 0x70, 0x69, 0x63, 0x22, 0xbb, 0x01, 0x0a,
  278. 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65,
  279. 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65,
  280. 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x66, 0x69, 0x6c, 0x65, 0x55, 0x72, 0x6c, 0x18,
  281. 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x66, 0x69, 0x6c, 0x65, 0x55, 0x72, 0x6c, 0x12, 0x1c,
  282. 0x0a, 0x09, 0x66, 0x69, 0x6c, 0x65, 0x42, 0x79, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28,
  283. 0x0c, 0x52, 0x09, 0x66, 0x69, 0x6c, 0x65, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x1a, 0x0a, 0x08,
  284. 0x66, 0x69, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08,
  285. 0x66, 0x69, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x72, 0x65, 0x74, 0x75,
  286. 0x72, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x65,
  287. 0x74, 0x75, 0x72, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x65, 0x78, 0x74, 0x72,
  288. 0x61, 0x63, 0x74, 0x54, 0x79, 0x70, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x65,
  289. 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x79, 0x70, 0x65, 0x22, 0x4b, 0x0a, 0x0c, 0x46, 0x69,
  290. 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x25, 0x0a, 0x06, 0x72, 0x65,
  291. 0x73, 0x75, 0x6c, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x70, 0x72, 0x6f,
  292. 0x74, 0x6f, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c,
  293. 0x74, 0x12, 0x14, 0x0a, 0x05, 0x4f, 0x74, 0x68, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
  294. 0x52, 0x05, 0x4f, 0x74, 0x68, 0x65, 0x72, 0x22, 0x9c, 0x01, 0x0a, 0x06, 0x52, 0x65, 0x73, 0x75,
  295. 0x6c, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01,
  296. 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x20,
  297. 0x0a, 0x0b, 0x74, 0x65, 0x78, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x02, 0x20,
  298. 0x01, 0x28, 0x09, 0x52, 0x0b, 0x74, 0x65, 0x78, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74,
  299. 0x12, 0x18, 0x0a, 0x07, 0x74, 0x65, 0x78, 0x74, 0x55, 0x72, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28,
  300. 0x09, 0x52, 0x07, 0x74, 0x65, 0x78, 0x74, 0x55, 0x72, 0x6c, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69,
  301. 0x6c, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69,
  302. 0x6c, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x53,
  303. 0x74, 0x61, 0x74, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x65, 0x72, 0x72, 0x6f,
  304. 0x72, 0x53, 0x74, 0x61, 0x74, 0x65, 0x32, 0x45, 0x0a, 0x0b, 0x46, 0x69, 0x6c, 0x65, 0x45, 0x78,
  305. 0x74, 0x72, 0x61, 0x63, 0x74, 0x12, 0x36, 0x0a, 0x0b, 0x46, 0x69, 0x6c, 0x65, 0x45, 0x78, 0x74,
  306. 0x72, 0x61, 0x63, 0x74, 0x12, 0x12, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x46, 0x69, 0x6c,
  307. 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
  308. 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x62, 0x06, 0x70,
  309. 0x72, 0x6f, 0x74, 0x6f, 0x33,
  310. }
  311. var (
  312. file_fileText_proto_rawDescOnce sync.Once
  313. file_fileText_proto_rawDescData = file_fileText_proto_rawDesc
  314. )
  315. func file_fileText_proto_rawDescGZIP() []byte {
  316. file_fileText_proto_rawDescOnce.Do(func() {
  317. file_fileText_proto_rawDescData = protoimpl.X.CompressGZIP(file_fileText_proto_rawDescData)
  318. })
  319. return file_fileText_proto_rawDescData
  320. }
  321. var file_fileText_proto_msgTypes = make([]protoimpl.MessageInfo, 4)
  322. var file_fileText_proto_goTypes = []interface{}{
  323. (*FileRequest)(nil), // 0: proto.FileRequest
  324. (*Request)(nil), // 1: proto.Request
  325. (*FileResponse)(nil), // 2: proto.FileResponse
  326. (*Result)(nil), // 3: proto.Result
  327. }
  328. var file_fileText_proto_depIdxs = []int32{
  329. 1, // 0: proto.FileRequest.message:type_name -> proto.Request
  330. 3, // 1: proto.FileResponse.result:type_name -> proto.Result
  331. 0, // 2: proto.FileExtract.FileExtract:input_type -> proto.FileRequest
  332. 2, // 3: proto.FileExtract.FileExtract:output_type -> proto.FileResponse
  333. 3, // [3:4] is the sub-list for method output_type
  334. 2, // [2:3] is the sub-list for method input_type
  335. 2, // [2:2] is the sub-list for extension type_name
  336. 2, // [2:2] is the sub-list for extension extendee
  337. 0, // [0:2] is the sub-list for field type_name
  338. }
  339. func init() { file_fileText_proto_init() }
  340. func file_fileText_proto_init() {
  341. if File_fileText_proto != nil {
  342. return
  343. }
  344. if !protoimpl.UnsafeEnabled {
  345. file_fileText_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
  346. switch v := v.(*FileRequest); i {
  347. case 0:
  348. return &v.state
  349. case 1:
  350. return &v.sizeCache
  351. case 2:
  352. return &v.unknownFields
  353. default:
  354. return nil
  355. }
  356. }
  357. file_fileText_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
  358. switch v := v.(*Request); i {
  359. case 0:
  360. return &v.state
  361. case 1:
  362. return &v.sizeCache
  363. case 2:
  364. return &v.unknownFields
  365. default:
  366. return nil
  367. }
  368. }
  369. file_fileText_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
  370. switch v := v.(*FileResponse); i {
  371. case 0:
  372. return &v.state
  373. case 1:
  374. return &v.sizeCache
  375. case 2:
  376. return &v.unknownFields
  377. default:
  378. return nil
  379. }
  380. }
  381. file_fileText_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
  382. switch v := v.(*Result); i {
  383. case 0:
  384. return &v.state
  385. case 1:
  386. return &v.sizeCache
  387. case 2:
  388. return &v.unknownFields
  389. default:
  390. return nil
  391. }
  392. }
  393. }
  394. type x struct{}
  395. out := protoimpl.TypeBuilder{
  396. File: protoimpl.DescBuilder{
  397. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  398. RawDescriptor: file_fileText_proto_rawDesc,
  399. NumEnums: 0,
  400. NumMessages: 4,
  401. NumExtensions: 0,
  402. NumServices: 1,
  403. },
  404. GoTypes: file_fileText_proto_goTypes,
  405. DependencyIndexes: file_fileText_proto_depIdxs,
  406. MessageInfos: file_fileText_proto_msgTypes,
  407. }.Build()
  408. File_fileText_proto = out.File
  409. file_fileText_proto_rawDesc = nil
  410. file_fileText_proto_goTypes = nil
  411. file_fileText_proto_depIdxs = nil
  412. }
  413. // Reference imports to suppress errors if they are not otherwise used.
  414. var _ context.Context
  415. var _ grpc.ClientConnInterface
  416. // This is a compile-time assertion to ensure that this generated file
  417. // is compatible with the grpc package it is being compiled against.
  418. const _ = grpc.SupportPackageIsVersion6
  419. // FileExtractClient is the client API for FileExtract service.
  420. //
  421. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
  422. type FileExtractClient interface {
  423. FileExtract(ctx context.Context, in *FileRequest, opts ...grpc.CallOption) (*FileResponse, error)
  424. }
  425. type fileExtractClient struct {
  426. cc grpc.ClientConnInterface
  427. }
  428. func NewFileExtractClient(cc grpc.ClientConnInterface) FileExtractClient {
  429. return &fileExtractClient{cc}
  430. }
  431. func (c *fileExtractClient) FileExtract(ctx context.Context, in *FileRequest, opts ...grpc.CallOption) (*FileResponse, error) {
  432. out := new(FileResponse)
  433. err := c.cc.Invoke(ctx, "/proto.FileExtract/FileExtract", in, out, opts...)
  434. if err != nil {
  435. return nil, err
  436. }
  437. return out, nil
  438. }
  439. // FileExtractServer is the server API for FileExtract service.
  440. type FileExtractServer interface {
  441. FileExtract(context.Context, *FileRequest) (*FileResponse, error)
  442. }
  443. // UnimplementedFileExtractServer can be embedded to have forward compatible implementations.
  444. type UnimplementedFileExtractServer struct {
  445. }
  446. func (*UnimplementedFileExtractServer) FileExtract(context.Context, *FileRequest) (*FileResponse, error) {
  447. return nil, status.Errorf(codes.Unimplemented, "method FileExtract not implemented")
  448. }
  449. func RegisterFileExtractServer(s *grpc.Server, srv FileExtractServer) {
  450. s.RegisterService(&_FileExtract_serviceDesc, srv)
  451. }
  452. func _FileExtract_FileExtract_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  453. in := new(FileRequest)
  454. if err := dec(in); err != nil {
  455. return nil, err
  456. }
  457. if interceptor == nil {
  458. return srv.(FileExtractServer).FileExtract(ctx, in)
  459. }
  460. info := &grpc.UnaryServerInfo{
  461. Server: srv,
  462. FullMethod: "/proto.FileExtract/FileExtract",
  463. }
  464. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  465. return srv.(FileExtractServer).FileExtract(ctx, req.(*FileRequest))
  466. }
  467. return interceptor(ctx, in, info, handler)
  468. }
  469. var _FileExtract_serviceDesc = grpc.ServiceDesc{
  470. ServiceName: "proto.FileExtract",
  471. HandlerType: (*FileExtractServer)(nil),
  472. Methods: []grpc.MethodDesc{
  473. {
  474. MethodName: "FileExtract",
  475. Handler: _FileExtract_FileExtract_Handler,
  476. },
  477. },
  478. Streams: []grpc.StreamDesc{},
  479. Metadata: "fileText.proto",
  480. }