1234567891011121314151617181920212223242526272829303132333435 |
- // Code generated by goctl. DO NOT EDIT!
- // Source: fileCenter.proto
- package server
- import (
- "context"
- "bp.jydev.jianyu360.cn/BaseService/fileCenter/rpc/internal/logic"
- "bp.jydev.jianyu360.cn/BaseService/fileCenter/rpc/internal/svc"
- "bp.jydev.jianyu360.cn/BaseService/fileCenter/rpc/pb"
- )
- type FileCenterServer struct {
- svcCtx *svc.ServiceContext
- pb.UnimplementedFileCenterServer
- }
- func NewFileCenterServer(svcCtx *svc.ServiceContext) *FileCenterServer {
- return &FileCenterServer{
- svcCtx: svcCtx,
- }
- }
- // 文件上传
- func (s *FileCenterServer) Upload(ctx context.Context, in *pb.UploadReq) (*pb.UploadResp, error) {
- l := logic.NewUploadLogic(ctx, s.svcCtx)
- return l.Upload(in)
- }
- // 文件删除
- func (s *FileCenterServer) Delete(ctx context.Context, in *pb.DeleteFileReq) (*pb.FileResp, error) {
- l := logic.NewDeleteLogic(ctx, s.svcCtx)
- return l.Delete(in)
- }
|