Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterAssetsServer(s grpc.ServiceRegistrar, srv AssetsServer)
- type AssetsClient
- type AssetsServer
- type AssetsService
- type FileUploadRequest
- func (*FileUploadRequest) Descriptor() ([]byte, []int)deprecated
- func (x *FileUploadRequest) GetFile() []byte
- func (x *FileUploadRequest) GetName() string
- func (*FileUploadRequest) ProtoMessage()
- func (x *FileUploadRequest) ProtoReflect() protoreflect.Message
- func (x *FileUploadRequest) Reset()
- func (x *FileUploadRequest) String() string
- type FileUploadResponse
- func (*FileUploadResponse) Descriptor() ([]byte, []int)deprecated
- func (x *FileUploadResponse) GetMessage() string
- func (x *FileUploadResponse) GetName() string
- func (x *FileUploadResponse) GetSize() uint32
- func (*FileUploadResponse) ProtoMessage()
- func (x *FileUploadResponse) ProtoReflect() protoreflect.Message
- func (x *FileUploadResponse) Reset()
- func (x *FileUploadResponse) String() string
- type UnimplementedAssetsServer
- type UnsafeAssetsServer
Constants ¶
const (
Assets_FileUpload_FullMethodName = "/content.v1.Assets/FileUpload"
)
Variables ¶
var Assets_ServiceDesc = grpc.ServiceDesc{ ServiceName: "content.v1.Assets", HandlerType: (*AssetsServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "FileUpload", Handler: _Assets_FileUpload_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "content/v1/assets.proto", }
Assets_ServiceDesc is the grpc.ServiceDesc for Assets service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_content_v1_assets_proto protoreflect.FileDescriptor
Functions ¶
func RegisterAssetsServer ¶
func RegisterAssetsServer(s grpc.ServiceRegistrar, srv AssetsServer)
Types ¶
type AssetsClient ¶
type AssetsClient interface {
FileUpload(ctx context.Context, in *FileUploadRequest, opts ...grpc.CallOption) (*FileUploadResponse, error)
}
AssetsClient is the client API for Assets service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewAssetsClient ¶
func NewAssetsClient(cc grpc.ClientConnInterface) AssetsClient
type AssetsServer ¶
type AssetsServer interface { FileUpload(context.Context, *FileUploadRequest) (*FileUploadResponse, error) // contains filtered or unexported methods }
AssetsServer is the server API for Assets service. All implementations must embed UnimplementedAssetsServer for forward compatibility
type AssetsService ¶
type AssetsService struct { UnimplementedAssetsServer // contains filtered or unexported fields }
func NewAssetsService ¶
func NewAssetsService(assetsDir string) *AssetsService
func (*AssetsService) FileUpload ¶
func (s *AssetsService) FileUpload(ctx context.Context, req *FileUploadRequest) (*FileUploadResponse, error)
type FileUploadRequest ¶
type FileUploadRequest struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` File []byte `protobuf:"bytes,2,opt,name=file,proto3" json:"file,omitempty"` // contains filtered or unexported fields }
func (*FileUploadRequest) Descriptor
deprecated
func (*FileUploadRequest) Descriptor() ([]byte, []int)
Deprecated: Use FileUploadRequest.ProtoReflect.Descriptor instead.
func (*FileUploadRequest) GetFile ¶
func (x *FileUploadRequest) GetFile() []byte
func (*FileUploadRequest) GetName ¶
func (x *FileUploadRequest) GetName() string
func (*FileUploadRequest) ProtoMessage ¶
func (*FileUploadRequest) ProtoMessage()
func (*FileUploadRequest) ProtoReflect ¶
func (x *FileUploadRequest) ProtoReflect() protoreflect.Message
func (*FileUploadRequest) Reset ¶
func (x *FileUploadRequest) Reset()
func (*FileUploadRequest) String ¶
func (x *FileUploadRequest) String() string
type FileUploadResponse ¶
type FileUploadResponse struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Size uint32 `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"` Message string `protobuf:"bytes,3,opt,name=message,proto3" json:"message,omitempty"` // contains filtered or unexported fields }
func (*FileUploadResponse) Descriptor
deprecated
func (*FileUploadResponse) Descriptor() ([]byte, []int)
Deprecated: Use FileUploadResponse.ProtoReflect.Descriptor instead.
func (*FileUploadResponse) GetMessage ¶
func (x *FileUploadResponse) GetMessage() string
func (*FileUploadResponse) GetName ¶
func (x *FileUploadResponse) GetName() string
func (*FileUploadResponse) GetSize ¶
func (x *FileUploadResponse) GetSize() uint32
func (*FileUploadResponse) ProtoMessage ¶
func (*FileUploadResponse) ProtoMessage()
func (*FileUploadResponse) ProtoReflect ¶
func (x *FileUploadResponse) ProtoReflect() protoreflect.Message
func (*FileUploadResponse) Reset ¶
func (x *FileUploadResponse) Reset()
func (*FileUploadResponse) String ¶
func (x *FileUploadResponse) String() string
type UnimplementedAssetsServer ¶
type UnimplementedAssetsServer struct { }
UnimplementedAssetsServer must be embedded to have forward compatible implementations.
func (UnimplementedAssetsServer) FileUpload ¶
func (UnimplementedAssetsServer) FileUpload(context.Context, *FileUploadRequest) (*FileUploadResponse, error)
type UnsafeAssetsServer ¶
type UnsafeAssetsServer interface {
// contains filtered or unexported methods
}
UnsafeAssetsServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AssetsServer will result in compilation errors.